I have gcc 4.1.2 installed. I also installed a new separate gcc (version 4.4.6) using yum on CentOS. Now, to my question, are these two versions of gcc using the same version of glibc, or is glibc different for both of them? How can I find out? Secondly, is it better to have a newer version of glibc in terms of performance?
Both versions of GCC will use the version of glibc installed on your system. GCC packages usually do not ship a separate C library.
, glibc. gcc, ldd a.out . .
ldd a.out
test.c, :
test.c
$ gcc test.c -o out1 # with gcc 4.1.2 $ gcc test.c -o out2 # with gcc 4.4.6 $ ldd out1 $ ldd out2
libc, gcc.
, glibc.