efriedma added inline comments.

================
Comment at: clang/lib/CodeGen/CGException.cpp:650
+        llvm::FunctionCallee SehCppScope = getSehTryBeginFn(CGM);
+        EmitSehScope(SehCppScope);
+      }
----------------
jyu2 wrote:
> efriedma wrote:
> > Do we need to make the same change in EmitSEHTryStmt/ExitSEHTryStmt?
> > 
> > Is there some reason not to just call EmitSehTryScopeBegin here?
> EmitSehTryScopeBegin:  it is emit seh.scope.begin
> 
> In here we want to emit seh.try.begin.  call EmitSehSCope with different 
> function.
> 
> For EmitSEHTryStmt/ExitSEHTryStmt if is for __try /__except/__finally and it 
> is for C code.  I thought about that.  And tried some test(BTW, try and __try 
> can not be in same construct), I don't see the problem.  So I did not add 
> that. 
Not sure I understand what you're saying about EmitSehTryScopeBegin.  
CGException.cpp:45 refers to "llvm.seh.try.begin".  CGCleanup.cpp:1370 also 
refers to "llvm.seh.try.begin"

For EmitSEHTryStmt/ExitSEHTryStmt, I guess __try codegen can't generate a 
construct quite like the given testcase, so thta's fine.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D150340

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to