Version 2.5.8
Removed dependency on Gay's dtoa.
Improved heap profiler precision and speed.
Reduced overhead of callback invocations on ARM.
git-svn-id: http://v8.googlecode.com/svn/trunk@5874 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/arm/codegen-arm.cc b/src/arm/codegen-arm.cc
index dd0520f..3e6743a 100644
--- a/src/arm/codegen-arm.cc
+++ b/src/arm/codegen-arm.cc
@@ -3103,10 +3103,13 @@
void CodeGenerator::InstantiateFunction(
- Handle<SharedFunctionInfo> function_info) {
+ Handle<SharedFunctionInfo> function_info,
+ bool pretenure) {
// Use the fast case closure allocation code that allocates in new
// space for nested functions that don't need literals cloning.
- if (scope()->is_function_scope() && function_info->num_literals() == 0) {
+ if (scope()->is_function_scope() &&
+ function_info->num_literals() == 0 &&
+ !pretenure) {
FastNewClosureStub stub;
frame_->EmitPush(Operand(function_info));
frame_->SpillAll();
@@ -3116,7 +3119,10 @@
// Create a new closure.
frame_->EmitPush(cp);
frame_->EmitPush(Operand(function_info));
- frame_->CallRuntime(Runtime::kNewClosure, 2);
+ frame_->EmitPush(Operand(pretenure
+ ? Factory::true_value()
+ : Factory::false_value()));
+ frame_->CallRuntime(Runtime::kNewClosure, 3);
frame_->EmitPush(r0);
}
}
@@ -3136,7 +3142,7 @@
ASSERT(frame_->height() == original_height);
return;
}
- InstantiateFunction(function_info);
+ InstantiateFunction(function_info, node->pretenure());
ASSERT_EQ(original_height + 1, frame_->height());
}
@@ -3147,7 +3153,7 @@
int original_height = frame_->height();
#endif
Comment cmnt(masm_, "[ SharedFunctionInfoLiteral");
- InstantiateFunction(node->shared_function_info());
+ InstantiateFunction(node->shared_function_info(), false);
ASSERT_EQ(original_height + 1, frame_->height());
}
@@ -5816,6 +5822,15 @@
}
+void CodeGenerator::GenerateFastAsciiArrayJoin(ZoneList<Expression*>* args) {
+ ASSERT(args->length() == 2);
+ Load(args->at(0));
+ Register value = frame_->PopToRegister();
+ __ LoadRoot(value, Heap::kUndefinedValueRootIndex);
+ frame_->EmitPush(value);
+}
+
+
void CodeGenerator::VisitCallRuntime(CallRuntime* node) {
#ifdef DEBUG
int original_height = frame_->height();