[PATCH] D23101: Align XRay return sleds to 2 byte boundaries

Dean Michael Berris via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 3 20:47:32 PDT 2016


dberris added inline comments.

================
Comment at: lib/Target/X86/X86MCInstLower.cpp:1078
@@ -1077,2 +1077,3 @@
   // .Lxray_sled_N:
+  //   .palign 2, ...
   //   ret  # or equivalent instruction
----------------
rSerge wrote:
> Did you mean .p2align directive instead of .palign ?
Thanks, yes, typo. :)

================
Comment at: lib/Target/X86/X86MCInstLower.cpp:1085
@@ -1083,2 +1084,3 @@
   OutStreamer->EmitLabel(CurSled);
+  OutStreamer->EmitCodeAlignment(4);
   unsigned OpCode = MI.getOperand(0).getImm();
----------------
rSerge wrote:
> Why aligning at 4 bytes? Wouldn't 2 suffice?
That's right, I clearly wasn't thinking this through very well. :)


https://reviews.llvm.org/D23101





More information about the llvm-commits mailing list