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

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

Issue 1320006: Updates and fixes for MIPS support. (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
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 29 matching lines...) Expand all
40 40
41 // ---------------------------------------------------------------------------- 41 // ----------------------------------------------------------------------------
42 // Static IC stub generators. 42 // Static IC stub generators.
43 // 43 //
44 44
45 #define __ ACCESS_MASM(masm) 45 #define __ ACCESS_MASM(masm)
46 46
47 47
48 void LoadIC::GenerateArrayLength(MacroAssembler* masm) { 48 void LoadIC::GenerateArrayLength(MacroAssembler* masm) {
49 UNIMPLEMENTED_MIPS(); 49 UNIMPLEMENTED_MIPS();
50 __ break_(__LINE__);
50 } 51 }
51 52
52 53
53 void LoadIC::GenerateStringLength(MacroAssembler* masm) { 54 void LoadIC::GenerateStringLength(MacroAssembler* masm) {
54 UNIMPLEMENTED_MIPS(); 55 UNIMPLEMENTED_MIPS();
56 __ break_(__LINE__);
55 } 57 }
56 58
57 59
58 void LoadIC::GenerateFunctionPrototype(MacroAssembler* masm) { 60 void LoadIC::GenerateFunctionPrototype(MacroAssembler* masm) {
59 UNIMPLEMENTED_MIPS(); 61 UNIMPLEMENTED_MIPS();
62 __ break_(__LINE__);
60 } 63 }
61 64
62 65
63 // Defined in ic.cc. 66 // Defined in ic.cc.
64 Object* CallIC_Miss(Arguments args); 67 Object* CallIC_Miss(Arguments args);
65 68
66 void CallIC::GenerateMegamorphic(MacroAssembler* masm, int argc) { 69 void CallIC::GenerateMegamorphic(MacroAssembler* masm, int argc) {
67 UNIMPLEMENTED_MIPS(); 70 UNIMPLEMENTED_MIPS();
71 __ break_(__LINE__);
68 } 72 }
69 73
70 74
71 void CallIC::GenerateNormal(MacroAssembler* masm, int argc) { 75 void CallIC::GenerateNormal(MacroAssembler* masm, int argc) {
72 UNIMPLEMENTED_MIPS(); 76 UNIMPLEMENTED_MIPS();
77 __ break_(__LINE__);
73 } 78 }
74 79
75 void CallIC::GenerateMiss(MacroAssembler* masm, int argc) { 80 void CallIC::GenerateMiss(MacroAssembler* masm, int argc) {
76 UNIMPLEMENTED_MIPS();
77 // Registers: 81 // Registers:
78 // a2: name 82 // a2: name
79 // ra: return address 83 // ra: return address
80 84
81 // Get the receiver of the function from the stack. 85 // Get the receiver of the function from the stack.
82 __ lw(a3, MemOperand(sp, argc*kPointerSize)); 86 __ lw(a3, MemOperand(sp, argc*kPointerSize));
83 87
84 __ EnterInternalFrame(); 88 __ EnterInternalFrame();
85 89
86 // Push the receiver and the name of the function. 90 // Push the receiver and the name of the function.
87 __ MultiPush(a2.bit() | a3.bit()); 91 __ MultiPush(a2.bit() | a3.bit());
88 92
89 // Call the entry. 93 // Call the entry.
90 __ li(a0, Operand(2)); 94 __ li(a0, Operand(2));
91 __ li(a1, Operand(ExternalReference(IC_Utility(kCallIC_Miss)))); 95 __ li(a1, Operand(ExternalReference(IC_Utility(kCallIC_Miss))));
92 96
93 CEntryStub stub(1); 97 CEntryStub stub(1);
94 __ CallStub(&stub); 98 __ CallStub(&stub);
95 99
96 // Move result to r1 and leave the internal frame. 100 // Move result to a1 and leave the internal frame.
97 __ mov(a1, v0); 101 __ mov(a1, v0);
98 __ LeaveInternalFrame(); 102 __ LeaveInternalFrame();
99 103
100 // Check if the receiver is a global object of some sort. 104 // Check if the receiver is a global object of some sort.
101 Label invoke, global; 105 Label invoke, global;
102 __ lw(a2, MemOperand(sp, argc * kPointerSize)); 106 __ lw(a2, MemOperand(sp, argc * kPointerSize));
103 __ andi(t0, a2, kSmiTagMask); 107 __ andi(t0, a2, kSmiTagMask);
104 __ Branch(eq, &invoke, t0, Operand(zero_reg)); 108 __ Branch(&invoke, eq, t0, Operand(zero_reg));
105 __ GetObjectType(a2, a3, a3); 109 __ GetObjectType(a2, a3, a3);
106 __ Branch(eq, &global, a3, Operand(JS_GLOBAL_OBJECT_TYPE)); 110 __ Branch(&global, eq, a3, Operand(JS_GLOBAL_OBJECT_TYPE));
107 __ Branch(ne, &invoke, a3, Operand(JS_BUILTINS_OBJECT_TYPE)); 111 __ Branch(&invoke, ne, a3, Operand(JS_BUILTINS_OBJECT_TYPE));
108 112
109 // Patch the receiver on the stack. 113 // Patch the receiver on the stack.
110 __ bind(&global); 114 __ bind(&global);
111 __ lw(a2, FieldMemOperand(a2, GlobalObject::kGlobalReceiverOffset)); 115 __ lw(a2, FieldMemOperand(a2, GlobalObject::kGlobalReceiverOffset));
112 __ sw(a2, MemOperand(sp, argc * kPointerSize)); 116 __ sw(a2, MemOperand(sp, argc * kPointerSize));
113 117
114 // Invoke the function. 118 // Invoke the function.
115 ParameterCount actual(argc); 119 ParameterCount actual(argc);
116 __ bind(&invoke); 120 __ bind(&invoke);
117 __ InvokeFunction(a1, actual, JUMP_FUNCTION); 121 __ InvokeFunction(a1, actual, JUMP_FUNCTION);
118 } 122 }
119 123
120 // Defined in ic.cc. 124 // Defined in ic.cc.
121 Object* LoadIC_Miss(Arguments args); 125 Object* LoadIC_Miss(Arguments args);
122 126
123 void LoadIC::GenerateMegamorphic(MacroAssembler* masm) { 127 void LoadIC::GenerateMegamorphic(MacroAssembler* masm) {
124 UNIMPLEMENTED_MIPS(); 128 UNIMPLEMENTED_MIPS();
129 __ break_(__LINE__);
125 } 130 }
126 131
127 132
128 void LoadIC::GenerateNormal(MacroAssembler* masm) { 133 void LoadIC::GenerateNormal(MacroAssembler* masm) {
129 UNIMPLEMENTED_MIPS(); 134 UNIMPLEMENTED_MIPS();
135 __ break_(__LINE__);
130 } 136 }
131 137
132 138
133 void LoadIC::GenerateMiss(MacroAssembler* masm) { 139 void LoadIC::GenerateMiss(MacroAssembler* masm) {
134 UNIMPLEMENTED_MIPS(); 140 UNIMPLEMENTED_MIPS();
141 __ break_(__LINE__);
135 } 142 }
136 143
137 144
138 void LoadIC::ClearInlinedVersion(Address address) {} 145 void LoadIC::ClearInlinedVersion(Address address) {}
139 bool LoadIC::PatchInlinedLoad(Address address, Object* map, int offset) { 146 bool LoadIC::PatchInlinedLoad(Address address, Object* map, int offset) {
140 return false; 147 return false;
141 } 148 }
142 149
143 void KeyedLoadIC::ClearInlinedVersion(Address address) {} 150 void KeyedLoadIC::ClearInlinedVersion(Address address) {}
144 bool KeyedLoadIC::PatchInlinedLoad(Address address, Object* map) { 151 bool KeyedLoadIC::PatchInlinedLoad(Address address, Object* map) {
145 return false; 152 return false;
146 } 153 }
147 154
148 void KeyedStoreIC::ClearInlinedVersion(Address address) {} 155 void KeyedStoreIC::ClearInlinedVersion(Address address) {}
149 void KeyedStoreIC::RestoreInlinedVersion(Address address) {} 156 void KeyedStoreIC::RestoreInlinedVersion(Address address) {}
150 bool KeyedStoreIC::PatchInlinedStore(Address address, Object* map) { 157 bool KeyedStoreIC::PatchInlinedStore(Address address, Object* map) {
151 return false; 158 return false;
152 } 159 }
153 160
154 161
155 Object* KeyedLoadIC_Miss(Arguments args); 162 Object* KeyedLoadIC_Miss(Arguments args);
156 163
157 164
158 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm) { 165 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm) {
159 UNIMPLEMENTED_MIPS(); 166 UNIMPLEMENTED_MIPS();
167 __ break_(__LINE__);
160 } 168 }
161 169
162 170
163 void KeyedLoadIC::GenerateGeneric(MacroAssembler* masm) { 171 void KeyedLoadIC::GenerateGeneric(MacroAssembler* masm) {
164 UNIMPLEMENTED_MIPS(); 172 UNIMPLEMENTED_MIPS();
173 __ break_(__LINE__);
165 } 174 }
166 175
167 176
168 void KeyedLoadIC::GenerateString(MacroAssembler* masm) { 177 void KeyedLoadIC::GenerateString(MacroAssembler* masm) {
169 UNIMPLEMENTED_MIPS(); 178 UNIMPLEMENTED_MIPS();
179 __ break_(__LINE__);
170 } 180 }
171 181
172 182
173 void KeyedLoadIC::GenerateExternalArray(MacroAssembler* masm, 183 void KeyedLoadIC::GenerateExternalArray(MacroAssembler* masm,
174 ExternalArrayType array_type) { 184 ExternalArrayType array_type) {
175 UNIMPLEMENTED_MIPS(); 185 UNIMPLEMENTED_MIPS();
186 __ break_(__LINE__);
176 } 187 }
177 188
178 189
179 void KeyedStoreIC::GenerateGeneric(MacroAssembler* masm) { 190 void KeyedStoreIC::GenerateGeneric(MacroAssembler* masm) {
180 UNIMPLEMENTED_MIPS(); 191 UNIMPLEMENTED_MIPS();
192 __ break_(__LINE__);
181 } 193 }
182 194
183 195
184 void KeyedStoreIC::GenerateExternalArray(MacroAssembler* masm, 196 void KeyedStoreIC::GenerateExternalArray(MacroAssembler* masm,
185 ExternalArrayType array_type) { 197 ExternalArrayType array_type) {
186 UNIMPLEMENTED_MIPS(); 198 UNIMPLEMENTED_MIPS();
199 __ break_(__LINE__);
187 } 200 }
188 201
189 202
190 void KeyedLoadIC::GenerateIndexedInterceptor(MacroAssembler* masm) { 203 void KeyedLoadIC::GenerateIndexedInterceptor(MacroAssembler* masm) {
191 UNIMPLEMENTED_MIPS(); 204 UNIMPLEMENTED_MIPS();
205 __ break_(__LINE__);
192 } 206 }
193 207
194 208
195 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) { 209 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) {
196 UNIMPLEMENTED_MIPS(); 210 UNIMPLEMENTED_MIPS();
211 __ break_(__LINE__);
197 } 212 }
198 213
199 214
200 void StoreIC::GenerateMegamorphic(MacroAssembler* masm) { 215 void StoreIC::GenerateMegamorphic(MacroAssembler* masm) {
201 UNIMPLEMENTED_MIPS(); 216 UNIMPLEMENTED_MIPS();
217 __ break_(__LINE__);
202 } 218 }
203 219
204 220
205 void StoreIC::GenerateMiss(MacroAssembler* masm) { 221 void StoreIC::GenerateMiss(MacroAssembler* masm) {
206 UNIMPLEMENTED_MIPS(); 222 UNIMPLEMENTED_MIPS();
223 __ break_(__LINE__);
207 } 224 }
208 225
209 226
210 void StoreIC::GenerateArrayLength(MacroAssembler* masm) { 227 void StoreIC::GenerateArrayLength(MacroAssembler* masm) {
211 UNIMPLEMENTED_MIPS(); 228 UNIMPLEMENTED_MIPS();
229 __ break_(__LINE__);
212 } 230 }
213 231
214 #undef __ 232 #undef __
215 233
216 } } // namespace v8::internal 234 } } // namespace v8::internal
217 235
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698