| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 3968 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3979 if (restore_context) { | 3979 if (restore_context) { |
| 3980 lw(cp, *context_restore_operand); | 3980 lw(cp, *context_restore_operand); |
| 3981 } | 3981 } |
| 3982 li(s0, Operand(stack_space)); | 3982 li(s0, Operand(stack_space)); |
| 3983 LeaveExitFrame(false, s0, !restore_context, EMIT_RETURN); | 3983 LeaveExitFrame(false, s0, !restore_context, EMIT_RETURN); |
| 3984 | 3984 |
| 3985 bind(&promote_scheduled_exception); | 3985 bind(&promote_scheduled_exception); |
| 3986 { | 3986 { |
| 3987 FrameScope frame(this, StackFrame::INTERNAL); | 3987 FrameScope frame(this, StackFrame::INTERNAL); |
| 3988 CallExternalReference( | 3988 CallExternalReference( |
| 3989 ExternalReference(Runtime::kPromoteScheduledException, isolate()), | 3989 ExternalReference(Runtime::kHiddenPromoteScheduledException, isolate()), |
| 3990 0); | 3990 0); |
| 3991 } | 3991 } |
| 3992 jmp(&exception_handled); | 3992 jmp(&exception_handled); |
| 3993 | 3993 |
| 3994 // HandleScope limit has changed. Delete allocated extensions. | 3994 // HandleScope limit has changed. Delete allocated extensions. |
| 3995 bind(&delete_allocated_handles); | 3995 bind(&delete_allocated_handles); |
| 3996 sw(s1, MemOperand(s3, kLimitOffset)); | 3996 sw(s1, MemOperand(s3, kLimitOffset)); |
| 3997 mov(s0, v0); | 3997 mov(s0, v0); |
| 3998 mov(a0, v0); | 3998 mov(a0, v0); |
| 3999 PrepareCallCFunction(1, s1); | 3999 PrepareCallCFunction(1, s1); |
| (...skipping 1444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5444 } | 5444 } |
| 5445 #endif | 5445 #endif |
| 5446 | 5446 |
| 5447 li(a0, Operand(Smi::FromInt(reason))); | 5447 li(a0, Operand(Smi::FromInt(reason))); |
| 5448 push(a0); | 5448 push(a0); |
| 5449 // Disable stub call restrictions to always allow calls to throw. | 5449 // Disable stub call restrictions to always allow calls to throw. |
| 5450 if (!has_frame_) { | 5450 if (!has_frame_) { |
| 5451 // We don't actually want to generate a pile of code for this, so just | 5451 // We don't actually want to generate a pile of code for this, so just |
| 5452 // claim there is a stack frame, without generating one. | 5452 // claim there is a stack frame, without generating one. |
| 5453 FrameScope scope(this, StackFrame::NONE); | 5453 FrameScope scope(this, StackFrame::NONE); |
| 5454 CallRuntime(Runtime::kThrowMessage, 1); | 5454 CallRuntime(Runtime::kHiddenThrowMessage, 1); |
| 5455 } else { | 5455 } else { |
| 5456 CallRuntime(Runtime::kThrowMessage, 1); | 5456 CallRuntime(Runtime::kHiddenThrowMessage, 1); |
| 5457 } | 5457 } |
| 5458 // will not return here | 5458 // will not return here |
| 5459 if (is_trampoline_pool_blocked()) { | 5459 if (is_trampoline_pool_blocked()) { |
| 5460 // If the calling code cares throw the exact number of | 5460 // If the calling code cares throw the exact number of |
| 5461 // instructions generated, we insert padding here to keep the size | 5461 // instructions generated, we insert padding here to keep the size |
| 5462 // of the ThrowMessage macro constant. | 5462 // of the ThrowMessage macro constant. |
| 5463 // Currently in debug mode with debug_code enabled the number of | 5463 // Currently in debug mode with debug_code enabled the number of |
| 5464 // generated instructions is 14, so we use this as a maximum value. | 5464 // generated instructions is 14, so we use this as a maximum value. |
| 5465 static const int kExpectedThrowMessageInstructions = 14; | 5465 static const int kExpectedThrowMessageInstructions = 14; |
| 5466 int throw_instructions = InstructionsGeneratedSince(&throw_start); | 5466 int throw_instructions = InstructionsGeneratedSince(&throw_start); |
| (...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5741 } | 5741 } |
| 5742 if (ms.shift() > 0) sra(result, result, ms.shift()); | 5742 if (ms.shift() > 0) sra(result, result, ms.shift()); |
| 5743 srl(at, dividend, 31); | 5743 srl(at, dividend, 31); |
| 5744 Addu(result, result, Operand(at)); | 5744 Addu(result, result, Operand(at)); |
| 5745 } | 5745 } |
| 5746 | 5746 |
| 5747 | 5747 |
| 5748 } } // namespace v8::internal | 5748 } } // namespace v8::internal |
| 5749 | 5749 |
| 5750 #endif // V8_TARGET_ARCH_MIPS | 5750 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |