Displaying 2 results from an estimated 2 matches for "init_seg".
2012 Sep 10
0
[LLVMdev] Question about ctors, dtors and sections on Windows
Hello
> On Windows, functions from llvm.global_ctors are placed in section .CRT$XCU,
> which is automatically called by the MS C Runtime.
Only if you link with MS runtime. Mingw follows standard .ctors / .dtors scheme.
> My expectation was that the dtors placed in .CRT$XTU which are the C
> terminator functions. Maybe there is a way to customize this?
Yes. Target (or,rather
2012 Sep 10
3
[LLVMdev] Question about ctors, dtors and sections on Windows
Hello all!
I extended the LDC2 with a pragma to register a funcion in the
llvm.global_ctors or llvm.global_dtors list.
On Linux, references to these functions are placed in .ctors and .dtors
sections and everything runs fine.
On Windows, functions from llvm.global_ctors are placed in section
.CRT$XCU, which is automatically called by the MS C Runtime. However,
functions from