Commit 879550ce authored by bmeurer's avatar bmeurer Committed by Commit bot

[arm] Don't call branch_offset within CheckConstPool.

This basically means that we must not use the b(Label*) version here,
but the b(int) version instead to jump over the constant pool.

BUG=v8:4292
LOG=y

Review URL: https://codereview.chromium.org/1224243002

Cr-Commit-Position: refs/heads/master@{#29552}
parent 91255190
...@@ -3838,10 +3838,7 @@ void Assembler::CheckConstPool(bool force_emit, bool require_jump) { ...@@ -3838,10 +3838,7 @@ void Assembler::CheckConstPool(bool force_emit, bool require_jump) {
bind(&size_check); bind(&size_check);
// Emit jump over constant pool if necessary. // Emit jump over constant pool if necessary.
Label after_pool; if (require_jump) b(size - kPcLoadDelta);
if (require_jump) {
b(&after_pool);
}
// Put down constant pool marker "Undefined instruction". // Put down constant pool marker "Undefined instruction".
// The data size helps disassembly know what to print. // The data size helps disassembly know what to print.
...@@ -3925,10 +3922,6 @@ void Assembler::CheckConstPool(bool force_emit, bool require_jump) { ...@@ -3925,10 +3922,6 @@ void Assembler::CheckConstPool(bool force_emit, bool require_jump) {
RecordComment("]"); RecordComment("]");
DCHECK_EQ(size, SizeOfCodeGeneratedSince(&size_check)); DCHECK_EQ(size, SizeOfCodeGeneratedSince(&size_check));
if (after_pool.is_linked()) {
bind(&after_pool);
}
} }
// Since a constant pool was just emitted, move the check offset forward by // Since a constant pool was just emitted, move the check offset forward by
......
...@@ -2027,4 +2027,17 @@ TEST(regress4292_blx) { ...@@ -2027,4 +2027,17 @@ TEST(regress4292_blx) {
__ bind(&end); __ bind(&end);
} }
TEST(regress4292_CheckConstPool) {
CcTest::InitializeVM();
Isolate* isolate = CcTest::i_isolate();
HandleScope scope(isolate);
Assembler assm(isolate, NULL, 0);
__ mov(r0, Operand(isolate->factory()->infinity_value()));
__ BlockConstPoolFor(1019);
for (int i = 0; i < 1019; ++i) __ nop();
__ vldr(d0, MemOperand(r0, 0));
}
#undef __ #undef __
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