Index: src/assembler_ia32.cpp |
diff --git a/src/assembler_ia32.cpp b/src/assembler_ia32.cpp |
index a57d7915e15949d409cd6e6f6aec2161e78405fc..216cea6ecf112018313f3ddd736fb6000df2d258 100644 |
--- a/src/assembler_ia32.cpp |
+++ b/src/assembler_ia32.cpp |
@@ -112,6 +112,17 @@ void AssemblerX86::call(const ConstantRelocatable *label) { |
(void)call_start; |
} |
+void AssemblerX86::call(const Immediate &abs_address) { |
+ AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
+ intptr_t call_start = buffer_.GetPosition(); |
+ EmitUint8(0xE8); |
+ EmitFixup( |
+ this->createFixup(llvm::ELF::R_386_PC32, AssemblerFixup::NullSymbol)); |
+ EmitInt32(abs_address.value() - 4); |
+ assert((buffer_.GetPosition() - call_start) == kCallExternalLabelSize); |
+ (void)call_start; |
+} |
+ |
void AssemblerX86::pushl(GPRRegister reg) { |
AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
EmitUint8(0x50 + reg); |