[PATCH] D64759: [CodeGen] Don't resolve the stack protector frame accesses until PEI

John Brawn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 16 04:45:29 PDT 2019


john.brawn added inline comments.


================
Comment at: llvm/test/CodeGen/Thumb/stack_guard_remat.ll:6
 ;PIC:   foo2
+;PIC:   ldr {{r[0-9]+}}, {{LCPI[0-9_]+}}
 ;PIC:   ldr [[R0:r[0-9]+]], [[LABEL0:LCPI[0-9_]+]]
----------------
It would be better here to check that this value is being used to construct a stack offset that's being loaded from (i.e. check that we have ldr ra, LCP; add ra, SP; ldr rb, [ra]). Also it would be good to have an explicit check that the stack canary address isn't being spilled at the start of the function.


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

https://reviews.llvm.org/D64759





More information about the llvm-commits mailing list