[PATCH] D92738: [CodeGen] Restore accessing __stack_chk_guard via a .refptr stub on mingw after 2518433f861fcb87

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Dec 6 19:14:40 PST 2020


MaskRay accepted this revision.
MaskRay added a comment.
This revision is now accepted and ready to land.

Sorry, I did not know Windows has ssp...

The `if (getTargetMachine().getRelocationModel() == Reloc::Static)` change was added to keep the current ELF behavior in static relocation model (which may cause a copy relocation if the variable is defined in a shared object (libc.so))... Restricting this to Windows looks find

The long-term plan is:

- Add -fdirect-access-external-data to supersede -mpie-copy-relocations D92633 <https://reviews.llvm.org/D92633>
- Make -fdirect-access-external-data work with -fno-pic D92714 <https://reviews.llvm.org/D92714>
- Make -fdirect-access-external-data set a module flag
- Let Module::getOrInsertGlobal() check the module flag and make variable declarations dso_local


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D92738



More information about the llvm-commits mailing list