More or less directly copied from IR/Verifier.cpp.
Diff Detail
Event Timeline
Should have test in test/MachineVerifier
lib/CodeGen/MachineVerifier.cpp | ||
---|---|---|
1036–1037 | IMO we should remove alignment 0 from all points in the IR and MIR |
lib/CodeGen/MachineVerifier.cpp | ||
---|---|---|
1036–1037 | On second thought, I'm not sure this is necessary. The MIRParser won't ever produce a 0 base alignment MMO. This can probably be replaced with an assert in the MMO constructor |
Pending refresh w/suggested changes.
lib/CodeGen/MachineVerifier.cpp | ||
---|---|---|
1036–1037 | This is a good idea. I will do so. |
lib/CodeGen/MachineVerifier.cpp | ||
---|---|---|
1036–1037 | I'm not sure the MIParser rejects 0, it just doesn't default to 0. It would be a good idea to make sure that happens also |
It turns out the MachineMemOperand constructor already asserts on a zero alignment. The vector check is potentially useful, but given this doesn't cover SelectionDAG anyway (where I'm currently focused), I'm deferring it until a future point.
IMO we should remove alignment 0 from all points in the IR and MIR