[PATCH] D77124: Handle CET for -exception-model sjlj

LuoYuanke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 8 23:57:54 PDT 2020


LuoYuanke added inline comments.


================
Comment at: llvm/lib/Target/X86/X86IndirectBranchTracking.cpp:149
+      if (!IsEHPadBB && I->isEHLabel() && EHPadIBTNeeded) {
+        MCSymbol *Sym = I->getOperand(0).getMCSymbol();
+        if (MF.hasCallSiteLandingPad(Sym))
----------------
After build a local test case, I can see in line 39 it has indirect jump to lpad. Can you explain why checking "MF.hasCallSiteLandingPad(Sym)" is needed? Is there any test case for it?


```
 37 .LBB0_7:                                #   in Loop: Header=BB0_6 Depth=1
 38         leaq    .LJTI0_0(%rip), %rcx
 39         jmpq    *(%rcx,%rax,8)
 40 .LBB0_1:                                # %lpad
 41                                         #   in Loop: Header=BB0_6 Depth=1
 42 .Ltmp2:
 43         movl    -132(%rbp), %edi
 44         movl    -128(%rbp), %eax
```


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

https://reviews.llvm.org/D77124





More information about the llvm-commits mailing list