OLD | NEW |
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 3210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3221 __ b(ne, &miss); | 3221 __ b(ne, &miss); |
3222 | 3222 |
3223 GenerateLoadArrayLength(masm(), r1, r2, &miss); | 3223 GenerateLoadArrayLength(masm(), r1, r2, &miss); |
3224 __ bind(&miss); | 3224 __ bind(&miss); |
3225 GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); | 3225 GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); |
3226 | 3226 |
3227 return GetCode(Code::CALLBACKS, name); | 3227 return GetCode(Code::CALLBACKS, name); |
3228 } | 3228 } |
3229 | 3229 |
3230 | 3230 |
3231 Handle<Code> KeyedLoadStubCompiler::CompileLoadStringLength( | |
3232 Handle<String> name) { | |
3233 // ----------- S t a t e ------------- | |
3234 // -- lr : return address | |
3235 // -- r0 : key | |
3236 // -- r1 : receiver | |
3237 // ----------------------------------- | |
3238 Label miss; | |
3239 | |
3240 Counters* counters = masm()->isolate()->counters(); | |
3241 __ IncrementCounter(counters->keyed_load_string_length(), 1, r2, r3); | |
3242 | |
3243 // Check the key is the cached one. | |
3244 __ cmp(r0, Operand(name)); | |
3245 __ b(ne, &miss); | |
3246 | |
3247 GenerateLoadStringLength(masm(), r1, r2, r3, &miss, true); | |
3248 __ bind(&miss); | |
3249 __ DecrementCounter(counters->keyed_load_string_length(), 1, r2, r3); | |
3250 | |
3251 GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); | |
3252 | |
3253 return GetCode(Code::CALLBACKS, name); | |
3254 } | |
3255 | |
3256 | |
3257 Handle<Code> KeyedLoadStubCompiler::CompileLoadFunctionPrototype( | 3231 Handle<Code> KeyedLoadStubCompiler::CompileLoadFunctionPrototype( |
3258 Handle<String> name) { | 3232 Handle<String> name) { |
3259 // ----------- S t a t e ------------- | 3233 // ----------- S t a t e ------------- |
3260 // -- lr : return address | 3234 // -- lr : return address |
3261 // -- r0 : key | 3235 // -- r0 : key |
3262 // -- r1 : receiver | 3236 // -- r1 : receiver |
3263 // ----------------------------------- | 3237 // ----------------------------------- |
3264 Label miss; | 3238 Label miss; |
3265 | 3239 |
3266 Counters* counters = masm()->isolate()->counters(); | 3240 Counters* counters = masm()->isolate()->counters(); |
(...skipping 1109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4376 __ Jump(ic_slow, RelocInfo::CODE_TARGET); | 4350 __ Jump(ic_slow, RelocInfo::CODE_TARGET); |
4377 } | 4351 } |
4378 } | 4352 } |
4379 | 4353 |
4380 | 4354 |
4381 #undef __ | 4355 #undef __ |
4382 | 4356 |
4383 } } // namespace v8::internal | 4357 } } // namespace v8::internal |
4384 | 4358 |
4385 #endif // V8_TARGET_ARCH_ARM | 4359 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |