I made a simple program in c++ to compare performance between two approaches - pass by value and pass by reference. Actually pass by value performed better than pass by refe
Passing by value is often very quick for small types since most of them are smaller than the pointer on modern systems (64bit). There may also be certain optimizations done when passed by value.