Commit e312281b authored by Sigurd Schneider's avatar Sigurd Schneider Committed by Commit Bot

[ia32,root] Remove usage of StaticVariable from regexp assembler

Change-Id: Ic2c9f22517153dc5bf41f3d6c78fa06dd7cc4f84
Bug: v8:6666
Reviewed-on: https://chromium-review.googlesource.com/c/1280306
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Reviewed-by: 's avatarJakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56634}
parent ee9ac86a
......@@ -683,7 +683,7 @@ Handle<HeapObject> RegExpMacroAssemblerIA32::GetCode(Handle<String> source) {
ExternalReference stack_limit =
ExternalReference::address_of_stack_limit(isolate());
__ mov(ecx, esp);
__ sub(ecx, masm_->StaticVariable(stack_limit));
__ sub(ecx, StaticVariable(stack_limit));
// Handle it if the stack pointer is already below the stack limit.
__ j(below_equal, &stack_limit_hit);
// Check if there is room for the variable number of registers above
......@@ -1106,6 +1106,9 @@ void RegExpMacroAssemblerIA32::CallCheckStackGuardState(Register scratch) {
__ CallCFunction(check_stack_guard, num_arguments);
}
Operand RegExpMacroAssemblerIA32::StaticVariable(const ExternalReference& ext) {
return Operand(ext.address(), RelocInfo::EXTERNAL_REFERENCE);
}
// Helper function for reading a value out of a stack frame.
template <typename T>
......@@ -1221,7 +1224,7 @@ void RegExpMacroAssemblerIA32::CheckPreemption() {
Label no_preempt;
ExternalReference stack_limit =
ExternalReference::address_of_stack_limit(isolate());
__ cmp(esp, masm_->StaticVariable(stack_limit));
__ cmp(esp, StaticVariable(stack_limit));
__ j(above, &no_preempt);
SafeCall(&check_preempt_label_);
......@@ -1234,7 +1237,7 @@ void RegExpMacroAssemblerIA32::CheckStackLimit() {
Label no_stack_overflow;
ExternalReference stack_limit =
ExternalReference::address_of_regexp_stack_limit(isolate());
__ cmp(backtrack_stackpointer(), masm_->StaticVariable(stack_limit));
__ cmp(backtrack_stackpointer(), StaticVariable(stack_limit));
__ j(above, &no_stack_overflow);
SafeCall(&stack_overflow_label_);
......
......@@ -93,6 +93,7 @@ class RegExpMacroAssemblerIA32: public NativeRegExpMacroAssembler {
Address re_frame);
private:
Operand StaticVariable(const ExternalReference& ext);
// Offsets from ebp of function parameters and stored registers.
static const int kFramePointer = 0;
// Above the frame pointer - function parameters and return address.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment