[PATCH] D16426: [NFC] LoadInst: add two helper methods: getLoadedSize and getActualAlignment.

Manuel Jacob via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 21 17:53:38 PST 2016


mjacob added a comment.

I think we should reverse the dependency and commit this before http://reviews.llvm.org/D16425.


================
Comment at: include/llvm/IR/Instructions.h:296
@@ +295,3 @@
+  /// \brief Returns the explicit aligment, if present, or the ABI one.
+  unsigned getActualAlignment() const;
+
----------------
I'm not sure I like this name. Unfortunately, I don't have a better idea. ;) Let me think about this over night, I won't accept this revision before tomorrow anyway.

================
Comment at: include/llvm/IR/Instructions.h:298
@@ +297,3 @@
+
+  /// \brief Returns the size in bytes of the loaded value.
+  uint64_t getLoadedSize() const;
----------------
I think it's more correct to say that this is the amount of bytes this instruction loads from memory. The loaded value doesn't really have a size.


http://reviews.llvm.org/D16426





More information about the llvm-commits mailing list