[PATCH] D131910: [Windows] Put init_seg(compiler/lib) in llvm.global_ctors

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 15 12:59:04 PDT 2022


rnk added a comment.

Please update the AttrDocs.td <https://github.com/llvm/llvm-project/blob/main/clang/include/clang/Basic/AttrDocs.td#L109> file to document the relationship between init_seg and init_priority on Windows.

Can we increase the threshold for library so that we can insert initializers between compiler and library in the future? Maybe Microsoft will come out with some new semantic level that goes between C and L.

This is my proposed mapping:

- 101-199: A${N}, for very early things (ASan, I think)
- 200: C, compiler
- 201-399: C${N}, between compiler and library
- 400: L, library
- 401-65534: T${N}, after library, before user
- U: user, 65535


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D131910/new/

https://reviews.llvm.org/D131910



More information about the llvm-commits mailing list