[PATCH] D87448: [CodeGen] [WinException] Only produce handler data at the end of the function if needed

Hans Wennborg via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 23 06:35:32 PST 2020


hans accepted this revision.
hans added a comment.

lgtm

(I added a naming comment, but feel free to resolve that as you feel is best.)

Relatedly, if one wants to learn about Windows EH, are there any good resources besides studying the code?



================
Comment at: llvm/lib/MC/MCStreamer.cpp:695
 
+  CurrentProcWinFrameInfoStart = WinFrameInfos.size();
   WinFrameInfos.emplace_back(
----------------
When I first saw this variable name I thought it was some kind of offset. But now I see it's really an index into WinFrameInfos.

Maybe CurrentProcWinFrameInfoIndex would be a better name? And should it be initialized to -1 or some other invalid value rather than 0, since I assume it should always be set here before it's used?


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

https://reviews.llvm.org/D87448



More information about the llvm-commits mailing list