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

Side by Side Diff: src/arm64/builtins-arm64.cc

Issue 371033002: Reland r22247 "ARM64: Use UntagSmi helpers and clean up assertions." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix more failures. Created 6 years, 5 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm64/assembler-arm64-inl.h ('k') | src/arm64/code-stubs-arm64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM64 7 #if V8_TARGET_ARCH_ARM64
8 8
9 #include "src/codegen.h" 9 #include "src/codegen.h"
10 #include "src/debug.h" 10 #include "src/debug.h"
(...skipping 1228 matching lines...) Expand 10 before | Expand all | Expand 10 after
1239 // We are not trying to catch interruptions (e.g. debug break and 1239 // We are not trying to catch interruptions (e.g. debug break and
1240 // preemption) here, so the "real stack limit" is checked. 1240 // preemption) here, so the "real stack limit" is checked.
1241 Label enough_stack_space; 1241 Label enough_stack_space;
1242 __ LoadRoot(x10, Heap::kRealStackLimitRootIndex); 1242 __ LoadRoot(x10, Heap::kRealStackLimitRootIndex);
1243 __ Ldr(function, MemOperand(fp, kFunctionOffset)); 1243 __ Ldr(function, MemOperand(fp, kFunctionOffset));
1244 // Make x10 the space we have left. The stack might already be overflowed 1244 // Make x10 the space we have left. The stack might already be overflowed
1245 // here which will cause x10 to become negative. 1245 // here which will cause x10 to become negative.
1246 // TODO(jbramley): Check that the stack usage here is safe. 1246 // TODO(jbramley): Check that the stack usage here is safe.
1247 __ Sub(x10, jssp, x10); 1247 __ Sub(x10, jssp, x10);
1248 // Check if the arguments will overflow the stack. 1248 // Check if the arguments will overflow the stack.
1249 __ Cmp(x10, Operand(argc, LSR, kSmiShift - kPointerSizeLog2)); 1249 __ Cmp(x10, Operand::UntagSmiAndScale(argc, kPointerSizeLog2));
1250 __ B(gt, &enough_stack_space); 1250 __ B(gt, &enough_stack_space);
1251 // There is not enough stack space, so use a builtin to throw an appropriate 1251 // There is not enough stack space, so use a builtin to throw an appropriate
1252 // error. 1252 // error.
1253 __ Push(function, argc); 1253 __ Push(function, argc);
1254 __ InvokeBuiltin(Builtins::STACK_OVERFLOW, CALL_FUNCTION); 1254 __ InvokeBuiltin(Builtins::STACK_OVERFLOW, CALL_FUNCTION);
1255 // We should never return from the APPLY_OVERFLOW builtin. 1255 // We should never return from the APPLY_OVERFLOW builtin.
1256 if (__ emit_debug_code()) { 1256 if (__ emit_debug_code()) {
1257 __ Unreachable(); 1257 __ Unreachable();
1258 } 1258 }
1259 1259
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
1556 __ Unreachable(); 1556 __ Unreachable();
1557 } 1557 }
1558 } 1558 }
1559 1559
1560 1560
1561 #undef __ 1561 #undef __
1562 1562
1563 } } // namespace v8::internal 1563 } } // namespace v8::internal
1564 1564
1565 #endif // V8_TARGET_ARCH_ARM 1565 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm64/assembler-arm64-inl.h ('k') | src/arm64/code-stubs-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698