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

Unified Diff: src/hydrogen-instructions.h

Issue 892383003: emit premonomorphic ics for loads/stores in optimized code (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: src/hydrogen-instructions.h
diff --git a/src/hydrogen-instructions.h b/src/hydrogen-instructions.h
index 1c54fa5ba6464f7cc052bf5ee356ebb565635e8e..f3a04f67e090ac59f4f5e3805fff62c804a22b89 100644
--- a/src/hydrogen-instructions.h
+++ b/src/hydrogen-instructions.h
@@ -6568,13 +6568,16 @@ class HLoadNamedField FINAL : public HTemplateInstruction<2> {
class HLoadNamedGeneric FINAL : public HTemplateInstruction<2> {
public:
- DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P2(HLoadNamedGeneric, HValue*,
- Handle<Object>);
+ DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P3(HLoadNamedGeneric, HValue*,
+ Handle<Object>, InlineCacheState);
HValue* context() const { return OperandAt(0); }
HValue* object() const { return OperandAt(1); }
Handle<Object> name() const { return name_; }
+ InlineCacheState initialization_state() const {
+ return initialization_state_;
+ }
FeedbackVectorICSlot slot() const { return slot_; }
Handle<TypeFeedbackVector> feedback_vector() const {
return feedback_vector_;
@@ -6596,8 +6599,11 @@ class HLoadNamedGeneric FINAL : public HTemplateInstruction<2> {
DECLARE_CONCRETE_INSTRUCTION(LoadNamedGeneric)
private:
- HLoadNamedGeneric(HValue* context, HValue* object, Handle<Object> name)
- : name_(name), slot_(FeedbackVectorICSlot::Invalid()) {
+ HLoadNamedGeneric(HValue* context, HValue* object, Handle<Object> name,
+ InlineCacheState initialization_state)
+ : name_(name),
+ slot_(FeedbackVectorICSlot::Invalid()),
+ initialization_state_(initialization_state) {
SetOperandAt(0, context);
SetOperandAt(1, object);
set_representation(Representation::Tagged());
@@ -6607,6 +6613,7 @@ class HLoadNamedGeneric FINAL : public HTemplateInstruction<2> {
Handle<Object> name_;
Handle<TypeFeedbackVector> feedback_vector_;
FeedbackVectorICSlot slot_;
+ InlineCacheState initialization_state_;
};
@@ -7060,14 +7067,17 @@ class HStoreNamedField FINAL : public HTemplateInstruction<3> {
class HStoreNamedGeneric FINAL : public HTemplateInstruction<3> {
public:
- DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P4(HStoreNamedGeneric, HValue*,
+ DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P5(HStoreNamedGeneric, HValue*,
Handle<String>, HValue*,
- LanguageMode);
+ LanguageMode, InlineCacheState);
HValue* object() const { return OperandAt(0); }
HValue* value() const { return OperandAt(1); }
HValue* context() const { return OperandAt(2); }
Handle<String> name() const { return name_; }
LanguageMode language_mode() const { return language_mode_; }
+ InlineCacheState initialization_state() const {
+ return initialization_state_;
+ }
std::ostream& PrintDataTo(std::ostream& os) const OVERRIDE; // NOLINT
@@ -7079,8 +7089,11 @@ class HStoreNamedGeneric FINAL : public HTemplateInstruction<3> {
private:
HStoreNamedGeneric(HValue* context, HValue* object, Handle<String> name,
- HValue* value, LanguageMode language_mode)
- : name_(name), language_mode_(language_mode) {
+ HValue* value, LanguageMode language_mode,
+ InlineCacheState initialization_state)
+ : name_(name),
+ language_mode_(language_mode),
+ initialization_state_(initialization_state) {
SetOperandAt(0, object);
SetOperandAt(1, value);
SetOperandAt(2, context);
@@ -7089,6 +7102,7 @@ class HStoreNamedGeneric FINAL : public HTemplateInstruction<3> {
Handle<String> name_;
LanguageMode language_mode_;
+ InlineCacheState initialization_state_;
};

Powered by Google App Engine
This is Rietveld 408576698