| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_ASSEMBLER_IA32_H_ | 5 #ifndef VM_ASSEMBLER_IA32_H_ |
| 6 #define VM_ASSEMBLER_IA32_H_ | 6 #define VM_ASSEMBLER_IA32_H_ |
| 7 | 7 |
| 8 #ifndef VM_ASSEMBLER_H_ | 8 #ifndef VM_ASSEMBLER_H_ |
| 9 #error Do not include assembler_ia32.h directly; use assembler.h instead. | 9 #error Do not include assembler_ia32.h directly; use assembler.h instead. |
| 10 #endif | 10 #endif |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 Operand(const Operand& other) : ValueObject(), length_(other.length_) { | 74 Operand(const Operand& other) : ValueObject(), length_(other.length_) { |
| 75 memmove(&encoding_[0], &other.encoding_[0], other.length_); | 75 memmove(&encoding_[0], &other.encoding_[0], other.length_); |
| 76 } | 76 } |
| 77 | 77 |
| 78 Operand& operator=(const Operand& other) { | 78 Operand& operator=(const Operand& other) { |
| 79 length_ = other.length_; | 79 length_ = other.length_; |
| 80 memmove(&encoding_[0], &other.encoding_[0], other.length_); | 80 memmove(&encoding_[0], &other.encoding_[0], other.length_); |
| 81 return *this; | 81 return *this; |
| 82 } | 82 } |
| 83 | 83 |
| 84 bool Equals(const Operand& other) { | 84 bool Equals(const Operand& other) const { |
| 85 if (length_ != other.length_) return false; | 85 if (length_ != other.length_) return false; |
| 86 for (uint8_t i = 0; i < length_; i++) { | 86 for (uint8_t i = 0; i < length_; i++) { |
| 87 if (encoding_[i] != other.encoding_[i]) return false; | 87 if (encoding_[i] != other.encoding_[i]) return false; |
| 88 } | 88 } |
| 89 return true; | 89 return true; |
| 90 } | 90 } |
| 91 | 91 |
| 92 protected: | 92 protected: |
| 93 Operand() : length_(0) { } // Needed by subclass Address. | 93 Operand() : length_(0) { } // Needed by subclass Address. |
| 94 | 94 |
| (...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 844 } | 844 } |
| 845 | 845 |
| 846 | 846 |
| 847 inline void Assembler::EmitOperandSizeOverride() { | 847 inline void Assembler::EmitOperandSizeOverride() { |
| 848 EmitUint8(0x66); | 848 EmitUint8(0x66); |
| 849 } | 849 } |
| 850 | 850 |
| 851 } // namespace dart | 851 } // namespace dart |
| 852 | 852 |
| 853 #endif // VM_ASSEMBLER_IA32_H_ | 853 #endif // VM_ASSEMBLER_IA32_H_ |
| OLD | NEW |