This week's experiment build gdc with tls disabled.

Jacob Carlborg doob at me.com
Fri Dec 20 12:54:03 PST 2013


On 2013-12-20 10:13, Johannes Pfau wrote:

> Likely yes, that's why I said 'longterm' solution. You need to edit the
> default linker script. Then there are 2 options: We can force certain
> object files to be at the start or the end of the section. So we could
> introduce dso_start.o and dso_end.o files containing the start/end
> sections and those would always be placed as the first/last objects in
> a section. (This is how the C++/C runtime calls the constructors in the
> .ctors section: crtbegin.o contains a __CTOR_LIST__ symbol)
>
> It's also possible to directly instruct the linker to insert a symbol
> at the start of the section and at the end of the section. This way you
> don't need special object files but the symbols will appear always,
> even for C/C++ programs.
>
> In theory it's always possible to use your own linker script without
> updating the compiler, but that's not a practical solution. Implicit
> linker-script which only extend the default script can be used for
> custom sections, but AFAIK this doesn't work for standard sections.

Ok, I see.

-- 
/Jacob Carlborg


More information about the D.gnu mailing list