As title states I wish to know does Fortran intent(inout) pass a copy of the value, or a pointer/reference to RAM address? The reason I need to know this is I need to pass a
Fortran does not specify details of how function and subroutine arguments are passed, but it does require that if a procedure modifies an intent(out)
or intent(inout)
argument then the changes will be visible to the caller after the procedure returns. It is common for compilers to implement this requirement by passing arguments by reference, but that is not the only possibility -- copy in / copy out is the main alternative.
You can normally rely on the compiler to implement the fastest behavior it can be certain is correct, which is usually pass by reference. There are cases where that cannot work, however, such as passing a non-contiguous array section to an assumed-size dummy argument, and there are sometimes cases where copy-in / copy-out is faster (maybe on certain large multiprocessor systems with segmented memory architectures).
The bottom line is that although you pose a good question, there is no general answer. As is often the case, you are best off to make it work first, and then make it faster if needed. Keep the array-copying question in the back of your head, but don't worry too much about it until you are in a position to test.