This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: TOC problems

>>>>> Adam Courchesne writes:

Adam> I've been having problems linking with gcc.
Adam> It gives me a TOC error saying  that I exceded th 64k limit.
Adam> I try to pass the -mno-fop-in-toc and -mno-sum-in-toc flags but it says
Adam> that they are invalid flags. (Even though they are displayed in the man
Adam> pages)
Adam> Are these options architecture dependant? I'm Runing AIX on an
Adam> IBM 44P Model 170 RISC box.

	-mno-fp-in-toc, -mno-sum-in-toc, and -mminimal-toc are
compile-time options, not link-time options.  I would highly recommend
just using -mminimal-toc.

	You need to (re-)compile all of your object files with the option.
Those options will not fix anything at the link stage once you have
encountered the linker error.

	The AIX linker provides the -bbigtoc option which you can invoke
from the GCC commandline using -Wl,-bbigtoc to pass an option to the
linker.  -bbigtoc will fix up the linker error at link time, but has a
higher performance penalty than -mminimal-toc.  -mminimal-toc has a
negligible performance impact.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]