Building libgcc for mcmodel=kernel: Difference between revisions

[unchecked revision][unchecked revision]
Content deleted Content added
No edit summary
m x86-64 link
Line 1:
{{Rating|2}}
In [[X86-64|x86_64]], if you link (e.g. through a linker script) your kernel directly to the higher half of the virtual memory, you might want to build the kernel with <tt>-mcmodel=kernel</tt> or <tt>-mcmodel=large</tt>.
 
Also, if you link with <tt>libgcc</tt> and use <tt>crtbegin.o</tt> and <tt>crtend.o</tt> (see [[Calling_Global_Constructors|Calling Global Constructors]]), you might wand to build <tt>libgcc</tt> with <tt>-mcmodel=kernel</tt> or <tt>-mcmodel-large</tt>.