Signup/Sign In
Ask Question
Not satisfied by the Answer? Still looking for a better solution?

Will gcc on onlinegdb always agree with gcc on CentOS 7?

Is there anything OS-dependent about gcc that would cause a meaningful change between the two versions? Are the two versions even different? Just want to make sure, because I test my code on onlinegdb but paranoidly compile and check it on my school's CentOS server before I submit. I'm wondering if this necessary.
by

1 Answer

Kajalsi45d
Agree with @fox, but additionally there are platform dependent behaviour, and undefined behaviour (GCC tried to define these where it can). These may differ by platform OS and hardware. However Gcc will try to keep things consistent (where it can).

An example of differences, will be the size of the long int and size_t data types may be 32 bit or 64 bit. (on other compilers them may also be 8 bit or 16 bit).

Login / Signup to Answer the Question.