Is there a way to fill the free RAM on a linux machine with random data?
The reason I'm asking this: I'm working in a group where we do numerical programming in Fortran. Sometimes, people mess up working with double precision reals, so that programs that should give double precision results only give single precision.
If my understanding is correct, one would see random fluctuations of the result after the single precision limit in such a program. That is, if you run the same program with the same input several times, you get randomly different result each time. What you see (the random part) depends on the random values in the free RAM of the machine. But in practice, if you run the program repeatedly on the same machine, the same parts of memory tend to be used repeatedly, which have the same random data in them, leading the same output every time.
My idea is that if you could overwrite the memory with random data, you would actually see the random fluctuations in your program output. That would make it a lot easier to find these bugs.
Is this idea whack, or if not, how do I fill the memory? Can I pipe /dev/random into the RAM, or something?