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

Side by Side Diff: src/heap/heap.cc

Issue 2673383002: [ic] Encode LoadGlobalIC's typeof mode in slot kind instead of code object's flags. (Closed)
Patch Set: Addressed comments and added check to FCG Created 3 years, 10 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
« no previous file with comments | « src/heap/heap.h ('k') | src/ic/arm/handler-compiler-arm.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 // 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/heap/heap.h" 5 #include "src/heap/heap.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api.h" 8 #include "src/api.h"
9 #include "src/ast/context-slot-cache.h" 9 #include "src/ast/context-slot-cache.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 2738 matching lines...) Expand 10 before | Expand all | Expand 10 after
2749 set_experimental_extra_natives_source_cache( 2749 set_experimental_extra_natives_source_cache(
2750 *factory->NewFixedArray(ExperimentalExtraNatives::GetBuiltinsCount())); 2750 *factory->NewFixedArray(ExperimentalExtraNatives::GetBuiltinsCount()));
2751 2751
2752 set_undefined_cell(*factory->NewCell(factory->undefined_value())); 2752 set_undefined_cell(*factory->NewCell(factory->undefined_value()));
2753 2753
2754 // Microtask queue uses the empty fixed array as a sentinel for "empty". 2754 // Microtask queue uses the empty fixed array as a sentinel for "empty".
2755 // Number of queued microtasks stored in Isolate::pending_microtask_count(). 2755 // Number of queued microtasks stored in Isolate::pending_microtask_count().
2756 set_microtask_queue(empty_fixed_array()); 2756 set_microtask_queue(empty_fixed_array());
2757 2757
2758 { 2758 {
2759 StaticFeedbackVectorSpec spec;
2760 FeedbackVectorSlot slot = spec.AddLoadICSlot();
2761 DCHECK_EQ(slot, FeedbackVectorSlot(TypeFeedbackVector::kDummyLoadICSlot));
2762 USE(slot);
2763
2764 Handle<TypeFeedbackMetadata> dummy_metadata =
2765 TypeFeedbackMetadata::New(isolate(), &spec);
2766 Handle<TypeFeedbackVector> dummy_vector =
2767 TypeFeedbackVector::New(isolate(), dummy_metadata);
2768
2769 set_dummy_vector(*dummy_vector);
2770
2771 // Now initialize dummy vector's entries.
2772 LoadICNexus(isolate()).ConfigureMegamorphic();
2773 }
2774
2775 {
2776 // Create a canonical empty TypeFeedbackVector, which is shared by all 2759 // Create a canonical empty TypeFeedbackVector, which is shared by all
2777 // functions that don't need actual type feedback slots. Note however 2760 // functions that don't need actual type feedback slots. Note however
2778 // that all these functions will share the same invocation count, but 2761 // that all these functions will share the same invocation count, but
2779 // that shouldn't matter since we only use the invocation count to 2762 // that shouldn't matter since we only use the invocation count to
2780 // relativize the absolute call counts, but we can only have call counts 2763 // relativize the absolute call counts, but we can only have call counts
2781 // if we have actual feedback slots. 2764 // if we have actual feedback slots.
2782 Handle<FixedArray> empty_type_feedback_vector = factory->NewFixedArray( 2765 Handle<FixedArray> empty_type_feedback_vector = factory->NewFixedArray(
2783 TypeFeedbackVector::kReservedIndexCount, TENURED); 2766 TypeFeedbackVector::kReservedIndexCount, TENURED);
2784 empty_type_feedback_vector->set(TypeFeedbackVector::kMetadataIndex, 2767 empty_type_feedback_vector->set(TypeFeedbackVector::kMetadataIndex,
2785 empty_fixed_array()); 2768 empty_fixed_array());
(...skipping 3802 matching lines...) Expand 10 before | Expand all | Expand 10 after
6588 } 6571 }
6589 6572
6590 6573
6591 // static 6574 // static
6592 int Heap::GetStaticVisitorIdForMap(Map* map) { 6575 int Heap::GetStaticVisitorIdForMap(Map* map) {
6593 return StaticVisitorBase::GetVisitorId(map); 6576 return StaticVisitorBase::GetVisitorId(map);
6594 } 6577 }
6595 6578
6596 } // namespace internal 6579 } // namespace internal
6597 } // namespace v8 6580 } // namespace v8
OLDNEW
« no previous file with comments | « src/heap/heap.h ('k') | src/ic/arm/handler-compiler-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698