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

Unified Diff: src/compiler/js-typed-lowering.h

Issue 1407413014: [turbofan] Pseudo-inline instanceof (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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/access-builder.cc ('k') | src/compiler/js-typed-lowering.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/js-typed-lowering.h
diff --git a/src/compiler/js-typed-lowering.h b/src/compiler/js-typed-lowering.h
index 2aafb7270b106e31e8fe2c0aa4735f4ec89cf10e..f4e11ec03fa11a87f00d575ad7fd66aaaef5c2d9 100644
--- a/src/compiler/js-typed-lowering.h
+++ b/src/compiler/js-typed-lowering.h
@@ -5,6 +5,7 @@
#ifndef V8_COMPILER_JS_TYPED_LOWERING_H_
#define V8_COMPILER_JS_TYPED_LOWERING_H_
+#include "src/base/flags.h"
#include "src/compiler/graph-reducer.h"
#include "src/compiler/opcodes.h"
@@ -12,6 +13,7 @@ namespace v8 {
namespace internal {
// Forward declarations.
+class CompilationDependencies;
class Factory;
@@ -28,7 +30,15 @@ class SimplifiedOperatorBuilder;
// Lowers JS-level operators to simplified operators based on types.
class JSTypedLowering final : public AdvancedReducer {
public:
- JSTypedLowering(Editor* editor, JSGraph* jsgraph, Zone* zone);
+ // Flags that control the mode of operation.
+ enum Flag {
+ kNoFlags = 0u,
+ kDeoptimizationEnabled = 1u << 0,
+ };
+ typedef base::Flags<Flag> Flags;
+
+ JSTypedLowering(Editor* editor, CompilationDependencies* dependencies,
+ Flags flags, JSGraph* jsgraph, Zone* zone);
~JSTypedLowering() final {}
Reduction Reduce(Node* node) final;
@@ -44,6 +54,7 @@ class JSTypedLowering final : public AdvancedReducer {
Reduction ReduceJSLoadNamed(Node* node);
Reduction ReduceJSLoadProperty(Node* node);
Reduction ReduceJSStoreProperty(Node* node);
+ Reduction ReduceJSInstanceOf(Node* node);
Reduction ReduceJSLoadContext(Node* node);
Reduction ReduceJSStoreContext(Node* node);
Reduction ReduceJSEqual(Node* node, bool invert);
@@ -87,15 +98,21 @@ class JSTypedLowering final : public AdvancedReducer {
CommonOperatorBuilder* common() const;
SimplifiedOperatorBuilder* simplified() const;
MachineOperatorBuilder* machine() const;
+ CompilationDependencies* dependencies() const;
+ Flags flags() const { return flags_; }
// Limits up to which context allocations are inlined.
static const int kFunctionContextAllocationLimit = 16;
static const int kBlockContextAllocationLimit = 16;
+ CompilationDependencies* dependencies_;
+ Flags flags_;
JSGraph* jsgraph_;
Type* shifted_int32_ranges_[4];
};
+DEFINE_OPERATORS_FOR_FLAGS(JSTypedLowering::Flags)
+
} // namespace compiler
} // namespace internal
} // namespace v8
« no previous file with comments | « src/compiler/access-builder.cc ('k') | src/compiler/js-typed-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698