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

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

Issue 1990012: ia32: Helper function for getting an element of a fixed array from object poi... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 7 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
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 850 matching lines...) Expand 10 before | Expand all | Expand 10 after
861 // address to store into and fall through to fast case. 861 // address to store into and fall through to fast case.
862 __ cmp(ecx, FieldOperand(edx, JSArray::kLengthOffset)); // Compare smis. 862 __ cmp(ecx, FieldOperand(edx, JSArray::kLengthOffset)); // Compare smis.
863 __ j(above_equal, &extra, not_taken); 863 __ j(above_equal, &extra, not_taken);
864 864
865 // Fast case: Do the store. 865 // Fast case: Do the store.
866 __ bind(&fast); 866 __ bind(&fast);
867 // eax: value 867 // eax: value
868 // ecx: key (a smi) 868 // ecx: key (a smi)
869 // edx: receiver 869 // edx: receiver
870 // edi: FixedArray receiver->elements 870 // edi: FixedArray receiver->elements
871 __ mov(FieldOperand(edi, ecx, times_2, FixedArray::kHeaderSize), eax); 871 __ mov(CodeGenerator::FixedArrayElementOperand(edi, ecx), eax);
872 // Update write barrier for the elements array address. 872 // Update write barrier for the elements array address.
873 __ mov(edx, Operand(eax)); 873 __ mov(edx, Operand(eax));
874 __ RecordWrite(edi, 0, edx, ecx); 874 __ RecordWrite(edi, 0, edx, ecx);
875 __ ret(0); 875 __ ret(0);
876 } 876 }
877 877
878 878
879 void KeyedStoreIC::GenerateExternalArray(MacroAssembler* masm, 879 void KeyedStoreIC::GenerateExternalArray(MacroAssembler* masm,
880 ExternalArrayType array_type) { 880 ExternalArrayType array_type) {
881 // ----------- S t a t e ------------- 881 // ----------- S t a t e -------------
(...skipping 754 matching lines...) Expand 10 before | Expand all | Expand 10 after
1636 1636
1637 // Do tail-call to runtime routine. 1637 // Do tail-call to runtime routine.
1638 ExternalReference ref = ExternalReference(IC_Utility(kKeyedStoreIC_Miss)); 1638 ExternalReference ref = ExternalReference(IC_Utility(kKeyedStoreIC_Miss));
1639 __ TailCallExternalReference(ref, 3, 1); 1639 __ TailCallExternalReference(ref, 3, 1);
1640 } 1640 }
1641 1641
1642 #undef __ 1642 #undef __
1643 1643
1644 1644
1645 } } // namespace v8::internal 1645 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698