When to pass parameters by variable VS. constant reference

I just read about passing arguments by reference. At the end of that page it is mentioned, that you should not pass fundamental types (bool, char, int, float) by constant reference and pass by value instead. So which Unreal types (int32, FVector, FTransform) should I pass by const reference and which by value (variable), to achieve the best performance?

Similarly I am not really sure, when I should use references and when to use pointers.

Don’t worry about it. Generally, value vs. reference is not going to impact performance noticeably, especially with a small struct like FVector or FTransform. If you think your code has a performance problem, profile to prove where the problem is before choosing a fix. In practice the compiler may do these micro-optimizations for you anyway.

That said, the only time I found a performance issue with value vs. reference is when passing around FRawMeshs which contain TArrays of 10k elements.

Cool, thanks for the answer.