Fixed exception reporting bug where certain exceptions were incorrectly reported as uncaught.
Improved the memory allocation strategy used during compilation to make running out of memory when compiling huge scripts less likely.
Optimized String.replace by avoiding the construction of certain sub strings.
Fixed bug in code generation for large switch statements on ARM.
Fixed bug that caused V8 to change the global object template passed in by the user.
Changed the API for creating object groups used during garbage collection. Entire object groups are now passed to V8 instead of individual members of the groups.
git-svn-id: http://v8.googlecode.com/svn/trunk@968 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/macro-assembler-arm.cc b/src/macro-assembler-arm.cc
index 7016145..5cbeae9 100644
--- a/src/macro-assembler-arm.cc
+++ b/src/macro-assembler-arm.cc
@@ -176,6 +176,20 @@
}
+void MacroAssembler::SmiJumpTable(Register index, Vector<Label*> targets) {
+ // Empty the const pool.
+ CheckConstPool(true, true);
+ add(pc, pc, Operand(index,
+ LSL,
+ assembler::arm::Instr::kInstrSizeLog2 - kSmiTagSize));
+ BlockConstPoolBefore(pc_offset() + (targets.length() + 1) * sizeof(Instr));
+ nop(); // Jump table alignment.
+ for (int i = 0; i < targets.length(); i++) {
+ b(targets[i]);
+ }
+}
+
+
// Will clobber 4 registers: object, offset, scratch, ip. The
// register 'object' contains a heap object pointer. The heap object
// tag is shifted away.