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

Side by Side Diff: src/arm/stub-cache-arm.cc

Issue 12567004: ARM: Optimsisation of ECMA ToInt32. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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 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 3494 matching lines...) Expand 10 before | Expand all | Expand 10 after
3505 } else if (elements_kind == EXTERNAL_DOUBLE_ELEMENTS) { 3505 } else if (elements_kind == EXTERNAL_DOUBLE_ELEMENTS) {
3506 __ sub(r5, r0, Operand(kHeapObjectTag)); 3506 __ sub(r5, r0, Operand(kHeapObjectTag));
3507 __ vldr(d0, r5, HeapNumber::kValueOffset); 3507 __ vldr(d0, r5, HeapNumber::kValueOffset);
3508 __ add(r5, r3, Operand(key, LSL, 2)); 3508 __ add(r5, r3, Operand(key, LSL, 2));
3509 __ vstr(d0, r5, 0); 3509 __ vstr(d0, r5, 0);
3510 } else { 3510 } else {
3511 // Hoisted load. vldr requires offset to be a multiple of 4 so we can 3511 // Hoisted load. vldr requires offset to be a multiple of 4 so we can
3512 // not include -kHeapObjectTag into it. 3512 // not include -kHeapObjectTag into it.
3513 __ sub(r5, value, Operand(kHeapObjectTag)); 3513 __ sub(r5, value, Operand(kHeapObjectTag));
3514 __ vldr(d0, r5, HeapNumber::kValueOffset); 3514 __ vldr(d0, r5, HeapNumber::kValueOffset);
3515 __ EmitECMATruncate(r5, d0, d1, r6, r7, r9); 3515 __ ECMAToInt32VFP(r5, d0, d1, r6, r7, r9);
3516 3516
3517 switch (elements_kind) { 3517 switch (elements_kind) {
3518 case EXTERNAL_BYTE_ELEMENTS: 3518 case EXTERNAL_BYTE_ELEMENTS:
3519 case EXTERNAL_UNSIGNED_BYTE_ELEMENTS: 3519 case EXTERNAL_UNSIGNED_BYTE_ELEMENTS:
3520 __ strb(r5, MemOperand(r3, key, LSR, 1)); 3520 __ strb(r5, MemOperand(r3, key, LSR, 1));
3521 break; 3521 break;
3522 case EXTERNAL_SHORT_ELEMENTS: 3522 case EXTERNAL_SHORT_ELEMENTS:
3523 case EXTERNAL_UNSIGNED_SHORT_ELEMENTS: 3523 case EXTERNAL_UNSIGNED_SHORT_ELEMENTS:
3524 __ strh(r5, MemOperand(r3, key, LSL, 0)); 3524 __ strh(r5, MemOperand(r3, key, LSL, 0));
3525 break; 3525 break;
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
4048 __ Jump(ic_slow, RelocInfo::CODE_TARGET); 4048 __ Jump(ic_slow, RelocInfo::CODE_TARGET);
4049 } 4049 }
4050 } 4050 }
4051 4051
4052 4052
4053 #undef __ 4053 #undef __
4054 4054
4055 } } // namespace v8::internal 4055 } } // namespace v8::internal
4056 4056
4057 #endif // V8_TARGET_ARCH_ARM 4057 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« src/arm/macro-assembler-arm.cc ('K') | « src/arm/macro-assembler-arm.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698