If you are passing a large object to a function, say a class containing a large array, is it always better to pass by reference? The idea would be to construct the function so:
template<class T> double foo(T& t){...}
ADDITION AFTER FIRST POST: If I wanted the function to be non-modifying, I would use a const reference.
I could then call the function simply by passing the objects to it:
T large_data = T(1000000);
f(large_data);