Apologies for the light necro, but I am finding myself looking into this too. I’ve found this post and this other post that all point to the same conclusion; adding a class soft reference variable seems to load the class into memory.
I’m writing this partially to express surprise as it seems counter to the whole purpose of soft references, but also a realisation that so long your soft reference type is of a lighter base class, this is perhaps not so much of an issue. For instance, you could make the variable of type ‘actor soft-ref’, which casts a very wide net but also doesn’t load anything new.
E.g. I had a blueprint class ‘Banana’ I filled with some static meshes and skeletal meshes. In a new BP I had a ‘Banana’ class soft ref, and using the console command memreport -full
I confirmed it was indeed loaded into memory (even after restarting)
Then, I changed the variable type to an Actor soft ref, but set its value to ‘banana’, and restarted the editor. I opened the BP with the variable in it, to ensure that BP was loaded, then the same console command created a memory report with no mention of the ‘banana’ class in it.
NB. I got that memreport
console command from this Epic dev blog post on memory debugging: Debugging and Optimizing Memory (unrealengine.com)