Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(239)

Unified Diff: src/x64/fast-codegen-x64.cc

Issue 435020: Fast-compiler: Add stack limit checks to back edges of while, do-while and for. (Closed)
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/x64/fast-codegen-x64.cc
diff --git a/src/x64/fast-codegen-x64.cc b/src/x64/fast-codegen-x64.cc
index bb85ef5d695768585fd43edab373dfc0eb3f2844..968d93be54a7955bf1df8f20c63ec6d4bf3d6740 100644
--- a/src/x64/fast-codegen-x64.cc
+++ b/src/x64/fast-codegen-x64.cc
@@ -382,26 +382,26 @@ void FastCodeGenerator::VisitDeclaration(Declaration* decl) {
__ Move(rax, Factory::the_hole_value());
if (FLAG_debug_code) {
// Check if we have the correct context pointer.
- __ movq(rbx, CodeGenerator::ContextOperand(
- rsi, Context::FCONTEXT_INDEX));
+ __ movq(rbx, CodeGenerator::ContextOperand(rsi,
+ Context::FCONTEXT_INDEX));
__ cmpq(rbx, rsi);
__ Check(equal, "Unexpected declaration in current context.");
}
__ movq(CodeGenerator::ContextOperand(rsi, slot->index()), rax);
// No write barrier since the_hole_value is in old space.
- ASSERT(Heap::InNewSpace(*Factory::the_hole_value()));
+ ASSERT(!Heap::InNewSpace(*Factory::the_hole_value()));
Lasse Reichstein 2009/11/24 14:21:36 I can't see how we could have been hitting this at
fschneider 2009/11/25 01:02:59 Thanks for fixing this along the way. I'm not sure
Lasse Reichstein 2009/11/25 08:56:26 Since the code isn't hit at all now, it's an easy
} else if (decl->fun() != NULL) {
Visit(decl->fun());
__ pop(rax);
if (FLAG_debug_code) {
// Check if we have the correct context pointer.
- __ movq(rbx, CodeGenerator::ContextOperand(
- rsi, Context::FCONTEXT_INDEX));
+ __ movq(rbx, CodeGenerator::ContextOperand(rsi,
+ Context::FCONTEXT_INDEX));
__ cmpq(rbx, rsi);
__ Check(equal, "Unexpected declaration in current context.");
}
__ movq(CodeGenerator::ContextOperand(rsi, slot->index()), rax);
- int offset = FixedArray::kHeaderSize + slot->index() * kPointerSize;
+ int offset = Context::SlotOffset(slot->index());
__ RecordWrite(rsi, offset, rax, rcx);
}
break;

Powered by Google App Engine
This is Rietveld 408576698