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

Unified Diff: src/compiler/js-operator.h

Issue 1424943008: [turbofan] Desugar lookup slot optimization in graph builder. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comment. Created 5 years, 1 month 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 | « src/compiler/js-generic-lowering.cc ('k') | src/compiler/js-operator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/js-operator.h
diff --git a/src/compiler/js-operator.h b/src/compiler/js-operator.h
index 9fe91d2649ef2c3cf3b5132a64bf165411d7a33c..932efac6c81a09e0fd9eab41cdbf0bb5e3de5f51 100644
--- a/src/compiler/js-operator.h
+++ b/src/compiler/js-operator.h
@@ -172,84 +172,28 @@ std::ostream& operator<<(std::ostream&, ContextAccess const&);
ContextAccess const& ContextAccessOf(Operator const*);
-// Defines the name for a dynamic variable lookup. The {check_bitset} allows to
-// inline checks whether the lookup yields in a global variable. This is used as
-// a parameter by JSLoadDynamicGlobal and JSStoreDynamicGlobal operators.
-class DynamicGlobalAccess final {
+// Defines the name for a dynamic variable lookup. This is used as a parameter
+// by JSLoadDynamic and JSStoreDynamic operators.
+class DynamicAccess final {
public:
- DynamicGlobalAccess(const Handle<String>& name, uint32_t check_bitset,
- const VectorSlotPair& feedback, TypeofMode typeof_mode);
+ DynamicAccess(const Handle<String>& name, TypeofMode typeof_mode);
const Handle<String>& name() const { return name_; }
- uint32_t check_bitset() const { return check_bitset_; }
- const VectorSlotPair& feedback() const { return feedback_; }
TypeofMode typeof_mode() const { return typeof_mode_; }
- // Indicates that an inline check is disabled.
- bool RequiresFullCheck() const {
- return check_bitset() == kFullCheckRequired;
- }
-
- // Limit of context chain length to which inline check is possible.
- static const int kMaxCheckDepth = 30;
-
- // Sentinel for {check_bitset} disabling inline checks.
- static const uint32_t kFullCheckRequired = -1;
-
private:
const Handle<String> name_;
- const uint32_t check_bitset_;
- const VectorSlotPair feedback_;
const TypeofMode typeof_mode_;
};
-size_t hash_value(DynamicGlobalAccess const&);
-
-bool operator==(DynamicGlobalAccess const&, DynamicGlobalAccess const&);
-bool operator!=(DynamicGlobalAccess const&, DynamicGlobalAccess const&);
-
-std::ostream& operator<<(std::ostream&, DynamicGlobalAccess const&);
-
-DynamicGlobalAccess const& DynamicGlobalAccessOf(Operator const*);
-
-
-// Defines the name for a dynamic variable lookup. The {check_bitset} allows to
-// inline checks whether the lookup yields in a context variable. This is used
-// as a parameter by JSLoadDynamicContext and JSStoreDynamicContext operators.
-class DynamicContextAccess final {
- public:
- DynamicContextAccess(const Handle<String>& name, uint32_t check_bitset,
- const ContextAccess& context_access);
-
- const Handle<String>& name() const { return name_; }
- uint32_t check_bitset() const { return check_bitset_; }
- const ContextAccess& context_access() const { return context_access_; }
-
- // Indicates that an inline check is disabled.
- bool RequiresFullCheck() const {
- return check_bitset() == kFullCheckRequired;
- }
-
- // Limit of context chain length to which inline check is possible.
- static const int kMaxCheckDepth = 30;
-
- // Sentinel for {check_bitset} disabling inline checks.
- static const uint32_t kFullCheckRequired = -1;
-
- private:
- const Handle<String> name_;
- const uint32_t check_bitset_;
- const ContextAccess context_access_;
-};
-
-size_t hash_value(DynamicContextAccess const&);
+size_t hash_value(DynamicAccess const&);
-bool operator==(DynamicContextAccess const&, DynamicContextAccess const&);
-bool operator!=(DynamicContextAccess const&, DynamicContextAccess const&);
+bool operator==(DynamicAccess const&, DynamicAccess const&);
+bool operator!=(DynamicAccess const&, DynamicAccess const&);
-std::ostream& operator<<(std::ostream&, DynamicContextAccess const&);
+std::ostream& operator<<(std::ostream&, DynamicAccess const&);
-DynamicContextAccess const& DynamicContextAccessOf(Operator const*);
+DynamicAccess const& DynamicAccessOf(Operator const*);
// Defines the property of an object for a named access. This is
@@ -495,13 +439,8 @@ class JSOperatorBuilder final : public ZoneObject {
const Operator* LoadContext(size_t depth, size_t index, bool immutable);
const Operator* StoreContext(size_t depth, size_t index);
- const Operator* LoadDynamicGlobal(const Handle<String>& name,
- uint32_t check_bitset,
- const VectorSlotPair& feedback,
- TypeofMode typeof_mode);
- const Operator* LoadDynamicContext(const Handle<String>& name,
- uint32_t check_bitset, size_t depth,
- size_t index);
+ const Operator* LoadDynamic(const Handle<String>& name,
+ TypeofMode typeof_mode);
const Operator* TypeOf();
const Operator* InstanceOf();
« no previous file with comments | « src/compiler/js-generic-lowering.cc ('k') | src/compiler/js-operator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698