C++ Variable reference slow

Hi,

I don’t know if this is a bug or working as intended. The scenario is this. I have an array in blueprint, that I pass to c++ as a reference. It is an array of structs (a lot), and in 4.7.5 there are no spikes in the unit graph. But if I update to 4.8 or 4.9, there are big spikes in the graph, event though the function doesn’t do anything.

I have created a test project to illustrate what I am saying. You can generate and build the solution, test, then update to 4.9 and see the difference. Note: The funciton runs on “T”.

The test function can be found in the level blueprint and in a c++ function library.

I have previously posted this as a question, but no one could supply and answer:

Hey -

I was able to test the sample project you included and have submitted a report (UE-20865) for investigation.

Cheers