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

Unified Diff: src/ast/ast.h

Issue 2707873002: Collect type profile for DevTools. (Closed)
Patch Set: Add documentation and sprinkle consts around. Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/ast/ast.cc » ('j') | src/compiler.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast/ast.h
diff --git a/src/ast/ast.h b/src/ast/ast.h
index c3790b34b377fe448289a171d066207cdb8e998e..118a6113269d063b807b2ed1a768cec92ebc59d7 100644
--- a/src/ast/ast.h
+++ b/src/ast/ast.h
@@ -2414,9 +2414,19 @@ class Assignment final : public Expression {
}
void AssignFeedbackSlots(FeedbackVectorSpec* spec, LanguageMode language_mode,
- FeedbackSlotCache* cache);
+ FeedbackSlotCache* cache,
+ bool collect_type_profile = false);
FeedbackSlot AssignmentSlot() const { return slot_; }
+ FeedbackSlot CollectTypeProfileSlot() const {
Yang 2017/03/09 10:28:27 CollectTypeProfileSlot sounds like an action. Can
Franzi 2017/03/10 12:14:28 Done.
+ DCHECK(HasCollectTypeProfileSlot());
+ return collect_type_profile_slot_;
+ }
+
+ bool HasCollectTypeProfileSlot() const {
+ return CollectTypeProfileSlotField::decode(bit_field_);
Yang 2017/03/09 10:28:27 Do we really need this bit in the bit field? Can w
Franzi 2017/03/10 12:14:28 Done.
+ }
+
private:
friend class AstNodeFactory;
@@ -2432,12 +2442,16 @@ class Assignment final : public Expression {
class StoreModeField
: public BitField<KeyedAccessStoreMode, KeyTypeField::kNext, 3> {};
class TokenField : public BitField<Token::Value, StoreModeField::kNext, 7> {};
+ class CollectTypeProfileSlotField
+ : public BitField<bool, TokenField::kNext, 1> {};
FeedbackSlot slot_;
Expression* target_;
Expression* value_;
BinaryOperation* binary_operation_;
SmallMapList receiver_types_;
+
+ FeedbackSlot collect_type_profile_slot_;
};
« no previous file with comments | « no previous file | src/ast/ast.cc » ('j') | src/compiler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698