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

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

Issue 189143006: MIPS: Symbols for type cells. (Closed) Base URL: https://github.com/v8/v8.git@gbl
Patch Set: Created 6 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
« no previous file with comments | « no previous file | src/mips/code-stubs-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 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 __ SmiTst(a2, t0); 156 __ SmiTst(a2, t0);
157 __ Assert(ne, kUnexpectedInitialMapForArrayFunction1, 157 __ Assert(ne, kUnexpectedInitialMapForArrayFunction1,
158 t0, Operand(zero_reg)); 158 t0, Operand(zero_reg));
159 __ GetObjectType(a2, a3, t0); 159 __ GetObjectType(a2, a3, t0);
160 __ Assert(eq, kUnexpectedInitialMapForArrayFunction2, 160 __ Assert(eq, kUnexpectedInitialMapForArrayFunction2,
161 t0, Operand(MAP_TYPE)); 161 t0, Operand(MAP_TYPE));
162 } 162 }
163 163
164 // Run the native code for the Array function called as a normal function. 164 // Run the native code for the Array function called as a normal function.
165 // Tail call a stub. 165 // Tail call a stub.
166 Handle<Object> undefined_sentinel( 166 Handle<Object> megamorphic_sentinel =
167 masm->isolate()->heap()->undefined_value(), 167 TypeFeedbackInfo::MegamorphicSentinel(masm->isolate());
168 masm->isolate()); 168 __ li(a2, Operand(megamorphic_sentinel));
169 __ li(a2, Operand(undefined_sentinel));
170 ArrayConstructorStub stub(masm->isolate()); 169 ArrayConstructorStub stub(masm->isolate());
171 __ TailCallStub(&stub); 170 __ TailCallStub(&stub);
172 } 171 }
173 172
174 173
175 void Builtins::Generate_StringConstructCode(MacroAssembler* masm) { 174 void Builtins::Generate_StringConstructCode(MacroAssembler* masm) {
176 // ----------- S t a t e ------------- 175 // ----------- S t a t e -------------
177 // -- a0 : number of arguments 176 // -- a0 : number of arguments
178 // -- a1 : constructor function 177 // -- a1 : constructor function
179 // -- ra : return address 178 // -- ra : return address
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 __ mov(s3, t0); 749 __ mov(s3, t0);
751 __ mov(s4, t0); 750 __ mov(s4, t0);
752 __ mov(s5, t0); 751 __ mov(s5, t0);
753 // s6 holds the root address. Do not clobber. 752 // s6 holds the root address. Do not clobber.
754 // s7 is cp. Do not init. 753 // s7 is cp. Do not init.
755 754
756 // Invoke the code and pass argc as a0. 755 // Invoke the code and pass argc as a0.
757 __ mov(a0, a3); 756 __ mov(a0, a3);
758 if (is_construct) { 757 if (is_construct) {
759 // No type feedback cell is available 758 // No type feedback cell is available
760 Handle<Object> undefined_sentinel( 759 Handle<Object> megamorphic_sentinel =
761 masm->isolate()->heap()->undefined_value(), masm->isolate()); 760 TypeFeedbackInfo::MegamorphicSentinel(masm->isolate());
762 __ li(a2, Operand(undefined_sentinel)); 761 __ li(a2, Operand(megamorphic_sentinel));
763 CallConstructStub stub(NO_CALL_FUNCTION_FLAGS); 762 CallConstructStub stub(NO_CALL_FUNCTION_FLAGS);
764 __ CallStub(&stub); 763 __ CallStub(&stub);
765 } else { 764 } else {
766 ParameterCount actual(a0); 765 ParameterCount actual(a0);
767 __ InvokeFunction(a1, actual, CALL_FUNCTION, NullCallWrapper()); 766 __ InvokeFunction(a1, actual, CALL_FUNCTION, NullCallWrapper());
768 } 767 }
769 768
770 // Leave internal frame. 769 // Leave internal frame.
771 } 770 }
772 771
(...skipping 727 matching lines...) Expand 10 before | Expand all | Expand 10 after
1500 __ bind(&dont_adapt_arguments); 1499 __ bind(&dont_adapt_arguments);
1501 __ Jump(a3); 1500 __ Jump(a3);
1502 } 1501 }
1503 1502
1504 1503
1505 #undef __ 1504 #undef __
1506 1505
1507 } } // namespace v8::internal 1506 } } // namespace v8::internal
1508 1507
1509 #endif // V8_TARGET_ARCH_MIPS 1508 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « no previous file | src/mips/code-stubs-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698