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

Side by Side Diff: src/mips/code-stubs-mips.cc

Issue 15806005: fix the compare nil ic (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 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/ic.cc ('k') | src/stub-cache.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 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 121
122 122
123 void CompareNilICStub::InitializeInterfaceDescriptor( 123 void CompareNilICStub::InitializeInterfaceDescriptor(
124 Isolate* isolate, 124 Isolate* isolate,
125 CodeStubInterfaceDescriptor* descriptor) { 125 CodeStubInterfaceDescriptor* descriptor) {
126 static Register registers[] = { a0 }; 126 static Register registers[] = { a0 };
127 descriptor->register_param_count_ = 1; 127 descriptor->register_param_count_ = 1;
128 descriptor->register_params_ = registers; 128 descriptor->register_params_ = registers;
129 descriptor->deoptimization_handler_ = 129 descriptor->deoptimization_handler_ =
130 FUNCTION_ADDR(CompareNilIC_Miss); 130 FUNCTION_ADDR(CompareNilIC_Miss);
131 descriptor->miss_handler_ = 131 descriptor->SetMissHandler(
132 ExternalReference(IC_Utility(IC::kCompareNilIC_Miss), isolate); 132 ExternalReference(IC_Utility(IC::kCompareNilIC_Miss), isolate));
133 } 133 }
134 134
135 135
136 static void InitializeArrayConstructorDescriptor( 136 static void InitializeArrayConstructorDescriptor(
137 Isolate* isolate, 137 Isolate* isolate,
138 CodeStubInterfaceDescriptor* descriptor, 138 CodeStubInterfaceDescriptor* descriptor,
139 int constant_stack_parameter_count) { 139 int constant_stack_parameter_count) {
140 // register state 140 // register state
141 // a0 -- number of arguments 141 // a0 -- number of arguments
142 // a1 -- function 142 // a1 -- function
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 int param_count = descriptor->register_param_count_; 211 int param_count = descriptor->register_param_count_;
212 { 212 {
213 // Call the runtime system in a fresh internal frame. 213 // Call the runtime system in a fresh internal frame.
214 FrameScope scope(masm, StackFrame::INTERNAL); 214 FrameScope scope(masm, StackFrame::INTERNAL);
215 ASSERT(descriptor->register_param_count_ == 0 || 215 ASSERT(descriptor->register_param_count_ == 0 ||
216 a0.is(descriptor->register_params_[param_count - 1])); 216 a0.is(descriptor->register_params_[param_count - 1]));
217 // Push arguments 217 // Push arguments
218 for (int i = 0; i < param_count; ++i) { 218 for (int i = 0; i < param_count; ++i) {
219 __ push(descriptor->register_params_[i]); 219 __ push(descriptor->register_params_[i]);
220 } 220 }
221 ExternalReference miss = descriptor->miss_handler_; 221 ExternalReference miss = descriptor->miss_handler();
222 __ CallExternalReference(miss, descriptor->register_param_count_); 222 __ CallExternalReference(miss, descriptor->register_param_count_);
223 } 223 }
224 224
225 __ Ret(); 225 __ Ret();
226 } 226 }
227 227
228 228
229 void ToNumberStub::Generate(MacroAssembler* masm) { 229 void ToNumberStub::Generate(MacroAssembler* masm) {
230 // The ToNumber stub takes one argument in a0. 230 // The ToNumber stub takes one argument in a0.
231 Label check_heap_number, call_builtin; 231 Label check_heap_number, call_builtin;
(...skipping 7615 matching lines...) Expand 10 before | Expand all | Expand 10 after
7847 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET); 7847 __ Jump(generic_construct_stub, RelocInfo::CODE_TARGET);
7848 } 7848 }
7849 } 7849 }
7850 7850
7851 7851
7852 #undef __ 7852 #undef __
7853 7853
7854 } } // namespace v8::internal 7854 } } // namespace v8::internal
7855 7855
7856 #endif // V8_TARGET_ARCH_MIPS 7856 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/ic.cc ('k') | src/stub-cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698