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

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

Issue 199044: Allign Intel macro assemblers with changes to ARM macro assembler (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 3 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 | « no previous file | src/ia32/macro-assembler-ia32.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 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 // edi: constructor 122 // edi: constructor
123 // eax: initial map 123 // eax: initial map
124 __ CmpInstanceType(eax, JS_FUNCTION_TYPE); 124 __ CmpInstanceType(eax, JS_FUNCTION_TYPE);
125 __ j(equal, &rt_call); 125 __ j(equal, &rt_call);
126 126
127 // Now allocate the JSObject on the heap. 127 // Now allocate the JSObject on the heap.
128 // edi: constructor 128 // edi: constructor
129 // eax: initial map 129 // eax: initial map
130 __ movzx_b(edi, FieldOperand(eax, Map::kInstanceSizeOffset)); 130 __ movzx_b(edi, FieldOperand(eax, Map::kInstanceSizeOffset));
131 __ shl(edi, kPointerSizeLog2); 131 __ shl(edi, kPointerSizeLog2);
132 // Make sure that the maximum heap object size will never cause us
133 // problem here, because it is always greater than the maximum
134 // instance size that can be represented in a byte.
135 ASSERT(Heap::MaxObjectSizeInPagedSpace() >= JSObject::kMaxInstanceSize);
136 __ AllocateObjectInNewSpace(edi, 132 __ AllocateObjectInNewSpace(edi,
137 ebx, 133 ebx,
138 edi, 134 edi,
139 no_reg, 135 no_reg,
140 &rt_call, 136 &rt_call,
141 NO_ALLOCATION_FLAGS); 137 NO_ALLOCATION_FLAGS);
142 // Allocated the JSObject, now initialize the fields. 138 // Allocated the JSObject, now initialize the fields.
143 // eax: initial map 139 // eax: initial map
144 // ebx: JSObject 140 // ebx: JSObject
145 // edi: start of next object 141 // edi: start of next object
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 __ sub(edx, Operand(ecx)); 182 __ sub(edx, Operand(ecx));
187 // Done if no extra properties are to be allocated. 183 // Done if no extra properties are to be allocated.
188 __ j(zero, &allocated); 184 __ j(zero, &allocated);
189 __ Assert(positive, "Property allocation count failed."); 185 __ Assert(positive, "Property allocation count failed.");
190 186
191 // Scale the number of elements by pointer size and add the header for 187 // Scale the number of elements by pointer size and add the header for
192 // FixedArrays to the start of the next object calculation from above. 188 // FixedArrays to the start of the next object calculation from above.
193 // ebx: JSObject 189 // ebx: JSObject
194 // edi: start of next object (will be start of FixedArray) 190 // edi: start of next object (will be start of FixedArray)
195 // edx: number of elements in properties array 191 // edx: number of elements in properties array
196 ASSERT(Heap::MaxObjectSizeInPagedSpace() >
197 (FixedArray::kHeaderSize + 255*kPointerSize));
198 __ AllocateObjectInNewSpace(FixedArray::kHeaderSize, 192 __ AllocateObjectInNewSpace(FixedArray::kHeaderSize,
199 times_pointer_size, 193 times_pointer_size,
200 edx, 194 edx,
201 edi, 195 edi,
202 ecx, 196 ecx,
203 no_reg, 197 no_reg,
204 &undo_allocation, 198 &undo_allocation,
205 RESULT_CONTAINS_TOP); 199 RESULT_CONTAINS_TOP);
206 200
207 // Initialize the FixedArray. 201 // Initialize the FixedArray.
(...skipping 566 matching lines...) Expand 10 before | Expand all | Expand 10 after
774 // Dont adapt arguments. 768 // Dont adapt arguments.
775 // ------------------------------------------- 769 // -------------------------------------------
776 __ bind(&dont_adapt_arguments); 770 __ bind(&dont_adapt_arguments);
777 __ jmp(Operand(edx)); 771 __ jmp(Operand(edx));
778 } 772 }
779 773
780 774
781 #undef __ 775 #undef __
782 776
783 } } // namespace v8::internal 777 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/ia32/macro-assembler-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698