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

Side by Side Diff: src/code-stub-assembler.cc

Issue 2151773002: Avoid jumping to the runtime for ForInFilter (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: use the code stub in turbofan Created 4 years, 5 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
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/code-stub-assembler.h" 5 #include "src/code-stub-assembler.h"
6 #include "src/code-factory.h" 6 #include "src/code-factory.h"
7 #include "src/frames-inl.h" 7 #include "src/frames-inl.h"
8 #include "src/frames.h" 8 #include "src/frames.h"
9 #include "src/ic/stub-cache.h" 9 #include "src/ic/stub-cache.h"
10 10
(...skipping 2400 matching lines...) Expand 10 before | Expand all | Expand 10 after
2411 // Ensure receiver is JSReceiver, otherwise bailout. 2411 // Ensure receiver is JSReceiver, otherwise bailout.
2412 Label if_objectisnotsmi(this); 2412 Label if_objectisnotsmi(this);
2413 Branch(WordIsSmi(receiver), if_bailout, &if_objectisnotsmi); 2413 Branch(WordIsSmi(receiver), if_bailout, &if_objectisnotsmi);
2414 Bind(&if_objectisnotsmi); 2414 Bind(&if_objectisnotsmi);
2415 2415
2416 Node* map = LoadMap(receiver); 2416 Node* map = LoadMap(receiver);
2417 Node* instance_type = LoadMapInstanceType(map); 2417 Node* instance_type = LoadMapInstanceType(map);
2418 { 2418 {
2419 Label if_objectisreceiver(this); 2419 Label if_objectisreceiver(this);
2420 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE); 2420 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE);
2421 Branch(Int32GreaterThanOrEqual(instance_type, 2421 STATIC_ASSERT(FIRST_JS_RECEIVER_TYPE == JS_PROXY_TYPE);
2422 Int32Constant(FIRST_JS_RECEIVER_TYPE)), 2422 Branch(
2423 &if_objectisreceiver, if_bailout); 2423 Int32GreaterThan(instance_type, Int32Constant(FIRST_JS_RECEIVER_TYPE)),
2424 &if_objectisreceiver, if_bailout);
2424 Bind(&if_objectisreceiver); 2425 Bind(&if_objectisreceiver);
2425 } 2426 }
2426 2427
2427 Variable var_index(this, MachineRepresentation::kWord32); 2428 Variable var_index(this, MachineRepresentation::kWord32);
2428 2429
2429 Label if_keyisindex(this), if_iskeyunique(this); 2430 Label if_keyisindex(this), if_iskeyunique(this);
2430 TryToName(key, &if_keyisindex, &var_index, &if_iskeyunique, if_bailout); 2431 TryToName(key, &if_keyisindex, &var_index, &if_iskeyunique, if_bailout);
2431 2432
2432 Bind(&if_iskeyunique); 2433 Bind(&if_iskeyunique);
2433 { 2434 {
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
3059 } 3060 }
3060 Bind(&miss); 3061 Bind(&miss);
3061 { 3062 {
3062 TailCallRuntime(Runtime::kLoadGlobalIC_Miss, p->context, p->slot, 3063 TailCallRuntime(Runtime::kLoadGlobalIC_Miss, p->context, p->slot,
3063 p->vector); 3064 p->vector);
3064 } 3065 }
3065 } 3066 }
3066 3067
3067 } // namespace internal 3068 } // namespace internal
3068 } // namespace v8 3069 } // namespace v8
OLDNEW
« no previous file with comments | « src/code-factory.cc ('k') | src/code-stubs.h » ('j') | src/code-stubs.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698