[PATCH] D22281: [CodeGen] Refactor MachineMemOperand's Flags enum.

Chandler Carruth via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 12 20:22:58 PDT 2016


chandlerc added inline comments.

================
Comment at: include/llvm/CodeGen/MachineMemOperand.h:102
@@ +101,3 @@
+  /// via ENABLE_FLAGS_ENUM.
+  enum Flags {
+    // No flags set.
----------------
MatzeB wrote:
> You could change this to `enum Flags : uint16_t {...}` so that spltting the alignment won't make the MemOperands larger than before.
> I assume the MOMaxFlag can is unnecessary as well now?
a fixed underlying type can't *shrink* an enum... if it only requires <= 16 bits to represent the largest enumerator, that's how many bits you'll get?


http://reviews.llvm.org/D22281





More information about the llvm-commits mailing list