[PATCH] D103202: [AIX] Add traceback ssp canary bit support

Jinsong Ji via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 9 19:17:06 PDT 2021


jsji added inline comments.


================
Comment at: llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp:2181
+  // There are cases that the stack protectors are not really inserted even if
+  // the attributes are on.
+  return true;
----------------
hubert.reinterpretcast wrote:
> shchenz wrote:
> > Will it cause some issue in unwinder if we set the ssp canary bit in the traceback table but there is no canary word in the stack?
> > 
> > Could you please comment @xingxue @DiggerLin @hubert.reinterpretcast 
> The `FIXME` indicates a problem (as is appropriate for a `FIXME`). Even if it is possible to recover from this by more complicated logic in the unwinder, the preference should be for it to be resolved by the compiler (pay for it at compile time). The patch does not have to be blocked by the pending `FIXME`, because the bit is only set when an internal/experimental flag is set.
As I mentioned, there is NO unwinder support yet, so this is chicken and egg issue. We can fix this in a following patch if the unwinder will not able to handle it and complain. 

Also this is a very corner case -- with legacy XL, we set this bit on whenever the options is on, no checking, and we never hit problem -- so legacy unwinder can tolerate this.




Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D103202



More information about the llvm-commits mailing list