Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/runtime/runtime-utils.h" | 5 #include "src/runtime/runtime-utils.h" |
| 6 | 6 |
| 7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
| 8 #include "src/arguments.h" | 8 #include "src/arguments.h" |
| 9 #include "src/compiler.h" | 9 #include "src/compiler.h" |
| 10 #include "src/deoptimizer.h" | 10 #include "src/deoptimizer.h" |
| (...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 521 argv[i] = args.at<Object>(2 + i); | 521 argv[i] = args.at<Object>(2 + i); |
| 522 } | 522 } |
| 523 Handle<Object> result; | 523 Handle<Object> result; |
| 524 ASSIGN_RETURN_FAILURE_ON_EXCEPTION( | 524 ASSIGN_RETURN_FAILURE_ON_EXCEPTION( |
| 525 isolate, result, | 525 isolate, result, |
| 526 Execution::Call(isolate, target, receiver, argc, argv.start())); | 526 Execution::Call(isolate, target, receiver, argc, argv.start())); |
| 527 return *result; | 527 return *result; |
| 528 } | 528 } |
| 529 | 529 |
| 530 | 530 |
| 531 RUNTIME_FUNCTION(Runtime_TailCall) { | |
| 532 UNREACHABLE(); | |
|
Jarin
2015/11/12 13:45:12
Why do not we just do the same thing as Runtime_Ca
danno
2015/11/13 10:04:17
Done.
| |
| 533 return 0; | |
| 534 } | |
| 535 | |
| 536 | |
| 531 RUNTIME_FUNCTION(Runtime_Apply) { | 537 RUNTIME_FUNCTION(Runtime_Apply) { |
| 532 HandleScope scope(isolate); | 538 HandleScope scope(isolate); |
| 533 DCHECK(args.length() == 5); | 539 DCHECK(args.length() == 5); |
| 534 CONVERT_ARG_HANDLE_CHECKED(JSReceiver, fun, 0); | 540 CONVERT_ARG_HANDLE_CHECKED(JSReceiver, fun, 0); |
| 535 CONVERT_ARG_HANDLE_CHECKED(Object, receiver, 1); | 541 CONVERT_ARG_HANDLE_CHECKED(Object, receiver, 1); |
| 536 CONVERT_ARG_HANDLE_CHECKED(JSObject, arguments, 2); | 542 CONVERT_ARG_HANDLE_CHECKED(JSObject, arguments, 2); |
| 537 CONVERT_INT32_ARG_CHECKED(offset, 3); | 543 CONVERT_INT32_ARG_CHECKED(offset, 3); |
| 538 CONVERT_INT32_ARG_CHECKED(argc, 4); | 544 CONVERT_INT32_ARG_CHECKED(argc, 4); |
| 539 RUNTIME_ASSERT(offset >= 0); | 545 RUNTIME_ASSERT(offset >= 0); |
| 540 // Loose upper bound to allow fuzzing. We'll most likely run out of | 546 // Loose upper bound to allow fuzzing. We'll most likely run out of |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 608 | 614 |
| 609 RUNTIME_FUNCTION(Runtime_ThrowStrongModeTooFewArguments) { | 615 RUNTIME_FUNCTION(Runtime_ThrowStrongModeTooFewArguments) { |
| 610 HandleScope scope(isolate); | 616 HandleScope scope(isolate); |
| 611 DCHECK(args.length() == 0); | 617 DCHECK(args.length() == 0); |
| 612 THROW_NEW_ERROR_RETURN_FAILURE(isolate, | 618 THROW_NEW_ERROR_RETURN_FAILURE(isolate, |
| 613 NewTypeError(MessageTemplate::kStrongArity)); | 619 NewTypeError(MessageTemplate::kStrongArity)); |
| 614 } | 620 } |
| 615 | 621 |
| 616 } // namespace internal | 622 } // namespace internal |
| 617 } // namespace v8 | 623 } // namespace v8 |
| OLD | NEW |