Index: src/x64/assembler-x64.h |
diff --git a/src/x64/assembler-x64.h b/src/x64/assembler-x64.h |
index f6cd5709366fd04336ae55dba118cc7fa9eeed62..ab26d745bfc4528cbc64ed3d6dbee528332114e8 100644 |
--- a/src/x64/assembler-x64.h |
+++ b/src/x64/assembler-x64.h |
@@ -395,6 +395,13 @@ class Operand BASE_EMBEDDED { |
// Does not check the "reg" part of the Operand. |
bool AddressUsesRegister(Register reg) const; |
+ // Queries related to the size of the generated instruction. |
+ // Whether the generated instruction will have a REX prefix. |
+ bool requires_rex() const { return rex_ != 0; } |
+ // Size of the ModR/M, SIB and displacement parts of the generated |
+ // instruction. |
+ int operand_size() const { return len_; } |
+ |
private: |
byte rex_; |
byte buf_[6]; |