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 1241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1252 GenerateMakeCodeYoungAgainCommon(masm); \ | 1252 GenerateMakeCodeYoungAgainCommon(masm); \ |
1253 } \ | 1253 } \ |
1254 void Builtins::Generate_Make##C##CodeYoungAgainOddMarking( \ | 1254 void Builtins::Generate_Make##C##CodeYoungAgainOddMarking( \ |
1255 MacroAssembler* masm) { \ | 1255 MacroAssembler* masm) { \ |
1256 GenerateMakeCodeYoungAgainCommon(masm); \ | 1256 GenerateMakeCodeYoungAgainCommon(masm); \ |
1257 } | 1257 } |
1258 CODE_AGE_LIST(DEFINE_CODE_AGE_BUILTIN_GENERATOR) | 1258 CODE_AGE_LIST(DEFINE_CODE_AGE_BUILTIN_GENERATOR) |
1259 #undef DEFINE_CODE_AGE_BUILTIN_GENERATOR | 1259 #undef DEFINE_CODE_AGE_BUILTIN_GENERATOR |
1260 | 1260 |
1261 | 1261 |
| 1262 void Builtins::Generate_NotifyICMiss(MacroAssembler* masm) { |
| 1263 { |
| 1264 FrameScope scope(masm, StackFrame::INTERNAL); |
| 1265 |
| 1266 // Preserve registers across notification, this is important for compiled |
| 1267 // stubs that tail call the runtime on deopts passing their parameters in |
| 1268 // registers. |
| 1269 __ stm(db_w, sp, kJSCallerSaved | kCalleeSaved); |
| 1270 // Pass the function and deoptimization type to the runtime system. |
| 1271 __ CallRuntime(Runtime::kNotifyICMiss, 0); |
| 1272 __ ldm(ia_w, sp, kJSCallerSaved | kCalleeSaved); |
| 1273 } |
| 1274 |
| 1275 __ mov(ip, lr); // Stash the miss continuation |
| 1276 __ add(sp, sp, Operand(kPointerSize)); // Ignore state |
| 1277 __ pop(lr); // Restore LR to continuation in JSFunction |
| 1278 __ mov(pc, ip); // Jump to miss handler |
| 1279 } |
| 1280 |
| 1281 |
1262 static void Generate_NotifyDeoptimizedHelper(MacroAssembler* masm, | 1282 static void Generate_NotifyDeoptimizedHelper(MacroAssembler* masm, |
1263 Deoptimizer::BailoutType type) { | 1283 Deoptimizer::BailoutType type) { |
1264 { | 1284 { |
1265 FrameScope scope(masm, StackFrame::INTERNAL); | 1285 FrameScope scope(masm, StackFrame::INTERNAL); |
1266 // Pass the function and deoptimization type to the runtime system. | 1286 // Pass the function and deoptimization type to the runtime system. |
1267 __ mov(r0, Operand(Smi::FromInt(static_cast<int>(type)))); | 1287 __ mov(r0, Operand(Smi::FromInt(static_cast<int>(type)))); |
1268 __ push(r0); | 1288 __ push(r0); |
1269 __ CallRuntime(Runtime::kNotifyDeoptimized, 1); | 1289 __ CallRuntime(Runtime::kNotifyDeoptimized, 1); |
1270 } | 1290 } |
1271 | 1291 |
(...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1832 __ bind(&dont_adapt_arguments); | 1852 __ bind(&dont_adapt_arguments); |
1833 __ Jump(r3); | 1853 __ Jump(r3); |
1834 } | 1854 } |
1835 | 1855 |
1836 | 1856 |
1837 #undef __ | 1857 #undef __ |
1838 | 1858 |
1839 } } // namespace v8::internal | 1859 } } // namespace v8::internal |
1840 | 1860 |
1841 #endif // V8_TARGET_ARCH_ARM | 1861 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |