What different between PIC code and non-PIC code?

pschen@mmpp5.iie.ncku.edu.tw pschen@mmpp5.iie.ncku.edu.tw
Mon Aug 23 19:42:00 GMT 1999


   Hi:
      PIC is position independent code.
    If the program is PIC, then that program can be relocated
    at run-time. I dont compile a program using -fPIC option normally.
    The program also can be relocated at run-time. That is no  
    different between using -fPIC and no-using. But I see the compiler
    output asemble-files between them, it is different.
    That is confused me. How to explain it?

      There is SYMBLE "_GLOBAL_OFFSET_TABLE" in the assemble-file from gcc by
    using -fPIC option. What is _GLOBAL_OFFSET_TABLE?
    
    Thanks your help, Thanks very much!


						Ps. Chen



More information about the Gcc mailing list