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

Side by Side Diff: src/arm/ic-arm.cc

Issue 8355035: Refactor elements kind conversion. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased to bleeding edge. Created 9 years, 2 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
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 1232 matching lines...) Expand 10 before | Expand all | Expand 10 after
1243 __ TailCallExternalReference(ref, 3, 1); 1243 __ TailCallExternalReference(ref, 3, 1);
1244 } 1244 }
1245 1245
1246 1246
1247 void KeyedStoreIC::GenerateTransitionElementsSmiToDouble(MacroAssembler* masm) { 1247 void KeyedStoreIC::GenerateTransitionElementsSmiToDouble(MacroAssembler* masm) {
1248 // ---------- S t a t e -------------- 1248 // ---------- S t a t e --------------
1249 // -- r2 : receiver 1249 // -- r2 : receiver
1250 // -- lr : return address 1250 // -- lr : return address
1251 // ----------------------------------- 1251 // -----------------------------------
1252 // Must return the modified receiver in r0. 1252 // Must return the modified receiver in r0.
1253 if (!FLAG_trace_elements_transitions) {
1254 Label fail;
1255 ElementsTransitionGenerator::GenerateSmiOnlyToDouble(masm, &fail);
1256 __ mov(r0, r2);
1257 __ Ret();
1258 __ bind(&fail);
1259 }
1253 1260
1254 __ push(r2); 1261 __ push(r2);
1255 __ TailCallRuntime(Runtime::kTransitionElementsSmiToDouble, 1, 1); 1262 __ TailCallRuntime(Runtime::kTransitionElementsSmiToDouble, 1, 1);
1256 } 1263 }
1257 1264
1258 1265
1259 void KeyedStoreIC::GenerateTransitionElementsDoubleToObject( 1266 void KeyedStoreIC::GenerateTransitionElementsDoubleToObject(
1260 MacroAssembler* masm) { 1267 MacroAssembler* masm) {
1261 // ---------- S t a t e -------------- 1268 // ---------- S t a t e --------------
1262 // -- r2 : receiver 1269 // -- r2 : receiver
1263 // -- lr : return address 1270 // -- lr : return address
1264 // ----------------------------------- 1271 // -----------------------------------
1265 // Must return the modified receiver in r0. 1272 // Must return the modified receiver in r0.
1273 if (!FLAG_trace_elements_transitions) {
1274 Label fail;
1275 ElementsTransitionGenerator::GenerateDoubleToObject(masm, &fail);
1276 __ mov(r0, r2);
1277 __ Ret();
1278 __ bind(&fail);
1279 }
1266 1280
1267 __ push(r2); 1281 __ push(r2);
1268 __ TailCallRuntime(Runtime::kTransitionElementsDoubleToObject, 1, 1); 1282 __ TailCallRuntime(Runtime::kTransitionElementsDoubleToObject, 1, 1);
1269 } 1283 }
1270 1284
1271 1285
1272 void KeyedStoreIC::GenerateRuntimeSetProperty(MacroAssembler* masm, 1286 void KeyedStoreIC::GenerateRuntimeSetProperty(MacroAssembler* masm,
1273 StrictModeFlag strict_mode) { 1287 StrictModeFlag strict_mode) {
1274 // ---------- S t a t e -------------- 1288 // ---------- S t a t e --------------
1275 // -- r0 : value 1289 // -- r0 : value
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
1689 Register reg = Assembler::GetRn(instr_at_patch); 1703 Register reg = Assembler::GetRn(instr_at_patch);
1690 patcher.masm()->tst(reg, Operand(kSmiTagMask)); 1704 patcher.masm()->tst(reg, Operand(kSmiTagMask));
1691 patcher.EmitCondition(eq); 1705 patcher.EmitCondition(eq);
1692 } 1706 }
1693 } 1707 }
1694 1708
1695 1709
1696 } } // namespace v8::internal 1710 } } // namespace v8::internal
1697 1711
1698 #endif // V8_TARGET_ARCH_ARM 1712 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« src/arm/codegen-arm.h ('K') | « src/arm/codegen-arm.cc ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698