| 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 841 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 852 __ add(r0, r0, Operand(kNoCodeAgeSequenceLength * Assembler::kInstrSize)); | 852 __ add(r0, r0, Operand(kNoCodeAgeSequenceLength * Assembler::kInstrSize)); |
| 853 __ mov(pc, r0); | 853 __ mov(pc, r0); |
| 854 } | 854 } |
| 855 | 855 |
| 856 | 856 |
| 857 void Builtins::Generate_MarkCodeAsExecutedTwice(MacroAssembler* masm) { | 857 void Builtins::Generate_MarkCodeAsExecutedTwice(MacroAssembler* masm) { |
| 858 GenerateMakeCodeYoungAgainCommon(masm); | 858 GenerateMakeCodeYoungAgainCommon(masm); |
| 859 } | 859 } |
| 860 | 860 |
| 861 | 861 |
| 862 void Builtins::Generate_NotifyStubFailure(MacroAssembler* masm) { | 862 static void Generate_NotifyStubFailureHelper(MacroAssembler* masm, |
| 863 SaveFPRegsMode save_doubles) { |
| 863 { | 864 { |
| 864 FrameScope scope(masm, StackFrame::INTERNAL); | 865 FrameScope scope(masm, StackFrame::INTERNAL); |
| 865 | 866 |
| 866 // Preserve registers across notification, this is important for compiled | 867 // Preserve registers across notification, this is important for compiled |
| 867 // stubs that tail call the runtime on deopts passing their parameters in | 868 // stubs that tail call the runtime on deopts passing their parameters in |
| 868 // registers. | 869 // registers. |
| 869 __ stm(db_w, sp, kJSCallerSaved | kCalleeSaved); | 870 __ stm(db_w, sp, kJSCallerSaved | kCalleeSaved); |
| 870 // Pass the function and deoptimization type to the runtime system. | 871 // Pass the function and deoptimization type to the runtime system. |
| 871 __ CallRuntime(Runtime::kNotifyStubFailure, 0); | 872 __ CallRuntime(Runtime::kNotifyStubFailure, 0, save_doubles); |
| 872 __ ldm(ia_w, sp, kJSCallerSaved | kCalleeSaved); | 873 __ ldm(ia_w, sp, kJSCallerSaved | kCalleeSaved); |
| 873 } | 874 } |
| 874 | 875 |
| 875 __ add(sp, sp, Operand(kPointerSize)); // Ignore state | 876 __ add(sp, sp, Operand(kPointerSize)); // Ignore state |
| 876 __ mov(pc, lr); // Jump to miss handler | 877 __ mov(pc, lr); // Jump to miss handler |
| 877 } | 878 } |
| 878 | 879 |
| 879 | 880 |
| 881 void Builtins::Generate_NotifyStubFailure(MacroAssembler* masm) { |
| 882 Generate_NotifyStubFailureHelper(masm, kDontSaveFPRegs); |
| 883 } |
| 884 |
| 885 |
| 886 void Builtins::Generate_NotifyStubFailureSaveDoubles(MacroAssembler* masm) { |
| 887 Generate_NotifyStubFailureHelper(masm, kSaveFPRegs); |
| 888 } |
| 889 |
| 890 |
| 880 static void Generate_NotifyDeoptimizedHelper(MacroAssembler* masm, | 891 static void Generate_NotifyDeoptimizedHelper(MacroAssembler* masm, |
| 881 Deoptimizer::BailoutType type) { | 892 Deoptimizer::BailoutType type) { |
| 882 { | 893 { |
| 883 FrameScope scope(masm, StackFrame::INTERNAL); | 894 FrameScope scope(masm, StackFrame::INTERNAL); |
| 884 // Pass the function and deoptimization type to the runtime system. | 895 // Pass the function and deoptimization type to the runtime system. |
| 885 __ mov(r0, Operand(Smi::FromInt(static_cast<int>(type)))); | 896 __ mov(r0, Operand(Smi::FromInt(static_cast<int>(type)))); |
| 886 __ push(r0); | 897 __ push(r0); |
| 887 __ CallRuntime(Runtime::kNotifyDeoptimized, 1); | 898 __ CallRuntime(Runtime::kNotifyDeoptimized, 1); |
| 888 } | 899 } |
| 889 | 900 |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1469 __ bind(&dont_adapt_arguments); | 1480 __ bind(&dont_adapt_arguments); |
| 1470 __ Jump(r3); | 1481 __ Jump(r3); |
| 1471 } | 1482 } |
| 1472 | 1483 |
| 1473 | 1484 |
| 1474 #undef __ | 1485 #undef __ |
| 1475 | 1486 |
| 1476 } } // namespace v8::internal | 1487 } } // namespace v8::internal |
| 1477 | 1488 |
| 1478 #endif // V8_TARGET_ARCH_ARM | 1489 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |