Index: src/x87/assembler-x87.h |
diff --git a/src/x87/assembler-x87.h b/src/x87/assembler-x87.h |
index 6648391cd48eb6d57e640ad8a3c0bf23906d35b6..05359648ad27737382ddabf731234051555317d7 100644 |
--- a/src/x87/assembler-x87.h |
+++ b/src/x87/assembler-x87.h |
@@ -37,6 +37,8 @@ |
#ifndef V8_X87_ASSEMBLER_X87_H_ |
#define V8_X87_ASSEMBLER_X87_H_ |
+#include <deque> |
+ |
#include "src/assembler.h" |
#include "src/isolate.h" |
#include "src/serialize.h" |
@@ -349,6 +351,11 @@ class Operand BASE_EMBEDDED { |
int32_t disp, |
RelocInfo::Mode rmode = RelocInfo::NONE32); |
+ static Operand JumpTable(Register index, ScaleFactor scale, Label* table) { |
+ return Operand(index, scale, reinterpret_cast<int32_t>(table), |
+ RelocInfo::INTERNAL_REFERENCE); |
+ } |
+ |
static Operand StaticVariable(const ExternalReference& ext) { |
return Operand(reinterpret_cast<int32_t>(ext.address()), |
RelocInfo::EXTERNAL_REFERENCE); |
@@ -422,11 +429,7 @@ class Operand BASE_EMBEDDED { |
class Displacement BASE_EMBEDDED { |
public: |
- enum Type { |
- UNCONDITIONAL_JUMP, |
- CODE_RELATIVE, |
- OTHER |
- }; |
+ enum Type { UNCONDITIONAL_JUMP, CODE_RELATIVE, OTHER, CODE_ABSOLUTE }; |
int data() const { return data_; } |
Type type() const { return TypeField::decode(data_); } |
@@ -788,6 +791,7 @@ class Assembler : public AssemblerBase { |
void int3(); |
void nop(); |
void ret(int imm16); |
+ void ud2(); |
// Label operations & relative jumps (PPUM Appendix D) |
// |
@@ -943,6 +947,7 @@ class Assembler : public AssemblerBase { |
// inline tables, e.g., jump-tables. |
void db(uint8_t data); |
void dd(uint32_t data); |
+ void dd(Label* label); |
// Check if there is less than kGap bytes available in the buffer. |
// If this is the case, we need to grow the buffer before emitting |
@@ -1013,6 +1018,8 @@ class Assembler : public AssemblerBase { |
void emit_operand(Register reg, const Operand& adr); |
+ void emit_label(Label* label); |
+ |
void emit_farith(int b1, int b2, int i); |
// labels |
@@ -1031,6 +1038,11 @@ class Assembler : public AssemblerBase { |
friend class CodePatcher; |
friend class EnsureSpace; |
+ // Internal reference positions, required for (potential) patching in |
+ // GrowBuffer(); contains only those internal references whose labels |
+ // are already bound. |
+ std::deque<int> internal_reference_positions_; |
+ |
// code generation |
RelocInfoWriter reloc_info_writer; |