Thank you a lot Dr. Regehr! As I was thinking of accomplishing my task slightly differently, is there any way to learn which global variables are still safe to read (for example, safely dereferencing a pointer) after main function has executed? I noted that some of the global variables may be unsafe to use (read) after main function execution (a pointer becoming null, e.g.).
If there's a way to instruct Csmith to print these variable names (inside comments) at the end of pretty-printing the code, I could parse it. Should I look into the checksum-calculation code as I think this function knows which variables can be read safely after execution of the main function?