[PATCH] D50166: [ARM64] [Windows] MCLayer support for exception handling

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 10 17:02:02 PDT 2018


rnk added a comment.

I like the code, but I think this needs more tests, and better testing infrastructure before we can commit it. I would recommend beefing up COFFDumper::printUnwindInfo in llvm-readobj to print the ARM64 unwind opcodes in a human readable format, and then you won't need to write tests with hexadecimal CHECKs like you have now.



================
Comment at: lib/MC/MCWin64EH.cpp:30
+    default:
+      assert(false && "Unsupported unwind code");
     case Win64EH::UOP_PushNonVol:
----------------
llvm_unreachable() is preferred for this


================
Comment at: lib/MC/MCWin64EH.cpp:69
+  default:
+    assert(false && "Unsupported unwind code");
+    break;
----------------
ditto


================
Comment at: lib/MC/MCWin64EH.cpp:271
+    default:
+      assert(false && "Unsupported ARM64 unwind code");
+      break;
----------------
llvm_unreachable


================
Comment at: lib/Target/AArch64/MCTargetDesc/AArch64ELFStreamer.cpp:225
 MCTargetStreamer *
 createAArch64ObjectTargetStreamer(MCStreamer &S, const MCSubtargetInfo &STI) {
   const Triple &TT = STI.getTargetTriple();
----------------
This should probably live in AArch64TargetStreamer.cpp of AArch64MCTargetDesc.cpp, and call through a similar factory free function for ELF.


Repository:
  rL LLVM

https://reviews.llvm.org/D50166





More information about the llvm-commits mailing list