[PATCH] D81711: [SDAG] Add new AssertAlign ISD node.

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 15 05:24:33 PDT 2020


arsenm added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:5191-5194
+  // There's no need to assert on a byte-aligned pointer. All pointers are at
+  // least byte aligned.
+  if (A < 2)
+    return Val;
----------------
This check is unnecessary, a lower alignment isn't even representable in Align because it stores the log2 of the alignment


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:138
 
+static cl::opt<bool>
+    InsertAssertAlign("insert-assert-align", cl::init(true),
----------------
Not sure we really need this?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D81711





More information about the llvm-commits mailing list