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

Side by Side Diff: src/mips/codegen-mips.cc

Issue 12212080: MIPS: Generate the TransitionElementsStub using Crankshaft (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Removed unused flag Created 7 years, 10 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/mips/code-stubs-mips.cc ('k') | src/mips/deoptimizer-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 // ----------- S t a t e ------------- 148 // ----------- S t a t e -------------
149 // -- a0 : value 149 // -- a0 : value
150 // -- a1 : key 150 // -- a1 : key
151 // -- a2 : receiver 151 // -- a2 : receiver
152 // -- ra : return address 152 // -- ra : return address
153 // -- a3 : target map, scratch for subsequent call 153 // -- a3 : target map, scratch for subsequent call
154 // -- t0 : scratch (elements) 154 // -- t0 : scratch (elements)
155 // ----------------------------------- 155 // -----------------------------------
156 if (mode == TRACK_ALLOCATION_SITE) { 156 if (mode == TRACK_ALLOCATION_SITE) {
157 ASSERT(allocation_site_info_found != NULL); 157 ASSERT(allocation_site_info_found != NULL);
158 masm->TestJSArrayForAllocationSiteInfo(a2, t0, 158 masm->TestJSArrayForAllocationSiteInfo(a2, t0, eq,
159 allocation_site_info_found); 159 allocation_site_info_found);
160 } 160 }
161 161
162 // Set transitioned map. 162 // Set transitioned map.
163 __ sw(a3, FieldMemOperand(a2, HeapObject::kMapOffset)); 163 __ sw(a3, FieldMemOperand(a2, HeapObject::kMapOffset));
164 __ RecordWriteField(a2, 164 __ RecordWriteField(a2,
165 HeapObject::kMapOffset, 165 HeapObject::kMapOffset,
166 a3, 166 a3,
167 t5, 167 t5,
168 kRAHasNotBeenSaved, 168 kRAHasNotBeenSaved,
(...skipping 12 matching lines...) Expand all
181 // -- ra : return address 181 // -- ra : return address
182 // -- a3 : target map, scratch for subsequent call 182 // -- a3 : target map, scratch for subsequent call
183 // -- t0 : scratch (elements) 183 // -- t0 : scratch (elements)
184 // ----------------------------------- 184 // -----------------------------------
185 Label loop, entry, convert_hole, gc_required, only_change_map, done; 185 Label loop, entry, convert_hole, gc_required, only_change_map, done;
186 bool fpu_supported = CpuFeatures::IsSupported(FPU); 186 bool fpu_supported = CpuFeatures::IsSupported(FPU);
187 187
188 Register scratch = t6; 188 Register scratch = t6;
189 189
190 if (mode == TRACK_ALLOCATION_SITE) { 190 if (mode == TRACK_ALLOCATION_SITE) {
191 masm->TestJSArrayForAllocationSiteInfo(a2, t0, fail); 191 masm->TestJSArrayForAllocationSiteInfo(a2, t0, eq, fail);
192 } 192 }
193 193
194 // Check for empty arrays, which only require a map transition and no changes 194 // Check for empty arrays, which only require a map transition and no changes
195 // to the backing store. 195 // to the backing store.
196 __ lw(t0, FieldMemOperand(a2, JSObject::kElementsOffset)); 196 __ lw(t0, FieldMemOperand(a2, JSObject::kElementsOffset));
197 __ LoadRoot(at, Heap::kEmptyFixedArrayRootIndex); 197 __ LoadRoot(at, Heap::kEmptyFixedArrayRootIndex);
198 __ Branch(&only_change_map, eq, at, Operand(t0)); 198 __ Branch(&only_change_map, eq, at, Operand(t0));
199 199
200 __ push(ra); 200 __ push(ra);
201 __ lw(t1, FieldMemOperand(t0, FixedArray::kLengthOffset)); 201 __ lw(t1, FieldMemOperand(t0, FixedArray::kLengthOffset));
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 // -- a0 : value 325 // -- a0 : value
326 // -- a1 : key 326 // -- a1 : key
327 // -- a2 : receiver 327 // -- a2 : receiver
328 // -- ra : return address 328 // -- ra : return address
329 // -- a3 : target map, scratch for subsequent call 329 // -- a3 : target map, scratch for subsequent call
330 // -- t0 : scratch (elements) 330 // -- t0 : scratch (elements)
331 // ----------------------------------- 331 // -----------------------------------
332 Label entry, loop, convert_hole, gc_required, only_change_map; 332 Label entry, loop, convert_hole, gc_required, only_change_map;
333 333
334 if (mode == TRACK_ALLOCATION_SITE) { 334 if (mode == TRACK_ALLOCATION_SITE) {
335 masm->TestJSArrayForAllocationSiteInfo(a2, t0, fail); 335 masm->TestJSArrayForAllocationSiteInfo(a2, t0, eq, fail);
336 } 336 }
337 337
338 // Check for empty arrays, which only require a map transition and no changes 338 // Check for empty arrays, which only require a map transition and no changes
339 // to the backing store. 339 // to the backing store.
340 __ lw(t0, FieldMemOperand(a2, JSObject::kElementsOffset)); 340 __ lw(t0, FieldMemOperand(a2, JSObject::kElementsOffset));
341 __ LoadRoot(at, Heap::kEmptyFixedArrayRootIndex); 341 __ LoadRoot(at, Heap::kEmptyFixedArrayRootIndex);
342 __ Branch(&only_change_map, eq, at, Operand(t0)); 342 __ Branch(&only_change_map, eq, at, Operand(t0));
343 343
344 __ MultiPush(a0.bit() | a1.bit() | a2.bit() | a3.bit() | ra.bit()); 344 __ MultiPush(a0.bit() | a1.bit() | a2.bit() | a3.bit() | ra.bit());
345 345
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 patcher.masm()->dd(reinterpret_cast<uint32_t>(stub->instruction_start())); 719 patcher.masm()->dd(reinterpret_cast<uint32_t>(stub->instruction_start()));
720 } 720 }
721 } 721 }
722 722
723 723
724 #undef __ 724 #undef __
725 725
726 } } // namespace v8::internal 726 } } // namespace v8::internal
727 727
728 #endif // V8_TARGET_ARCH_MIPS 728 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/code-stubs-mips.cc ('k') | src/mips/deoptimizer-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698