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

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

Issue 1475973002: [turbofan] Introduce proper JSCreateLiteralRegExp operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Use ReplaceWithStubCall. 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 9d744a8f2dea1000b81602b7999dfd44961e6be0..3c8b7bb22dbe2b2776cf531a28b0cc4cda1afcc4 100644
--- a/src/compiler/js-operator.h
+++ b/src/compiler/js-operator.h
@@ -404,19 +404,19 @@ const CreateClosureParameters& CreateClosureParametersOf(const Operator* op);
// Defines shared information for the literal that should be created. This is
-// used as parameter by JSCreateLiteralArray and JSCreateLiteralObject
-// operators.
+// used as parameter by JSCreateLiteralArray, JSCreateLiteralObject and
+// JSCreateLiteralRegExp operators.
class CreateLiteralParameters final {
public:
- CreateLiteralParameters(Handle<FixedArray> constants, int flags, int index)
- : constants_(constants), flags_(flags), index_(index) {}
+ CreateLiteralParameters(Handle<HeapObject> constant, int flags, int index)
+ : constant_(constant), flags_(flags), index_(index) {}
- Handle<FixedArray> constants() const { return constants_; }
+ Handle<HeapObject> constant() const { return constant_; }
int flags() const { return flags_; }
int index() const { return index_; }
private:
- Handle<FixedArray> const constants_;
+ Handle<HeapObject> const constant_;
int const flags_;
int const index_;
};
@@ -476,6 +476,8 @@ class JSOperatorBuilder final : public ZoneObject {
int literal_flags, int literal_index);
const Operator* CreateLiteralObject(Handle<FixedArray> constant_properties,
int literal_flags, int literal_index);
+ const Operator* CreateLiteralRegExp(Handle<String> constant_pattern,
+ int literal_flags, int literal_index);
const Operator* CallFunction(
size_t arity, LanguageMode language_mode,
« 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