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

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

Issue 817873003: Use weak cell in monomorphic KeyedStore IC. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix mips Created 6 years 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 | « src/ia32/macro-assembler-ia32.cc ('k') | src/mips/macro-assembler-mips.h » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/ic/handler-compiler.h" 7 #include "src/ic/handler-compiler.h"
8 #include "src/ic/ic-inl.h" 8 #include "src/ic/ic-inl.h"
9 #include "src/ic/ic-compiler.h" 9 #include "src/ic/ic-compiler.h"
10 10
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 Handle<Code> stub; 444 Handle<Code> stub;
445 if (receiver_map->has_fast_elements() || 445 if (receiver_map->has_fast_elements() ||
446 receiver_map->has_external_array_elements() || 446 receiver_map->has_external_array_elements() ||
447 receiver_map->has_fixed_typed_array_elements()) { 447 receiver_map->has_fixed_typed_array_elements()) {
448 stub = StoreFastElementStub(isolate(), is_jsarray, elements_kind, 448 stub = StoreFastElementStub(isolate(), is_jsarray, elements_kind,
449 store_mode).GetCode(); 449 store_mode).GetCode();
450 } else { 450 } else {
451 stub = StoreElementStub(isolate(), elements_kind).GetCode(); 451 stub = StoreElementStub(isolate(), elements_kind).GetCode();
452 } 452 }
453 453
454 __ DispatchMap(receiver(), scratch1(), receiver_map, stub, DO_SMI_CHECK); 454 Handle<WeakCell> cell = Map::WeakCellForMap(receiver_map);
455
456 __ DispatchWeakMap(receiver(), scratch1(), scratch2(), cell, stub,
457 DO_SMI_CHECK);
455 458
456 TailCallBuiltin(masm(), Builtins::kKeyedStoreIC_Miss); 459 TailCallBuiltin(masm(), Builtins::kKeyedStoreIC_Miss);
457 460
458 return GetCode(kind(), Code::NORMAL, factory()->empty_string()); 461 return GetCode(kind(), Code::NORMAL, factory()->empty_string());
459 } 462 }
460 463
461 464
462 #undef __ 465 #undef __
463 } 466 }
464 } // namespace v8::internal 467 } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/macro-assembler-ia32.cc ('k') | src/mips/macro-assembler-mips.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698