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

Unified Diff: src/code-stubs.h

Issue 2113673002: [stubs]: Convert FastNewContext stub to turbofan (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rename based on feedback Created 4 years, 5 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 | « src/code-factory.cc ('k') | src/code-stubs.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stubs.h
diff --git a/src/code-stubs.h b/src/code-stubs.h
index 6dfbc4d4b8c2b60f1a69def0e1ea0def7e161b06..b1d45b63e3ed78d08469005931ce894939de1a88 100644
--- a/src/code-stubs.h
+++ b/src/code-stubs.h
@@ -63,7 +63,6 @@ namespace internal {
V(FastCloneRegExp) \
V(FastCloneShallowArray) \
V(FastFunctionBind) \
- V(FastNewContext) \
V(FastNewObject) \
V(FastNewRestParameter) \
V(FastNewSloppyArguments) \
@@ -118,6 +117,7 @@ namespace internal {
V(Dec) \
V(FastCloneShallowObject) \
V(FastNewClosure) \
+ V(FastNewFunctionContext) \
V(InstanceOf) \
V(LessThan) \
V(LessThanOrEqual) \
@@ -1056,26 +1056,23 @@ class FastNewClosureStub : public TurboFanCodeStub {
DEFINE_TURBOFAN_CODE_STUB(FastNewClosure, TurboFanCodeStub);
};
-
-class FastNewContextStub final : public HydrogenCodeStub {
+class FastNewFunctionContextStub final : public TurboFanCodeStub {
public:
static const int kMaximumSlots = 64;
- FastNewContextStub(Isolate* isolate, int slots) : HydrogenCodeStub(isolate) {
+ FastNewFunctionContextStub(Isolate* isolate, int slots)
+ : TurboFanCodeStub(isolate) {
DCHECK(slots >= 0 && slots <= kMaximumSlots);
- set_sub_minor_key(SlotsBits::encode(slots));
+ minor_key_ = SlotsBits::encode(slots);
}
- int slots() const { return SlotsBits::decode(sub_minor_key()); }
-
- // Parameters accessed via CodeStubGraphBuilder::GetParameter()
- static const int kFunction = 0;
+ int slots() const { return SlotsBits::decode(minor_key_); }
private:
class SlotsBits : public BitField<int, 0, 8> {};
- DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewContext);
- DEFINE_HYDROGEN_CODE_STUB(FastNewContext, HydrogenCodeStub);
+ DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewFunctionContext);
+ DEFINE_TURBOFAN_CODE_STUB(FastNewFunctionContext, TurboFanCodeStub);
};
« no previous file with comments | « src/code-factory.cc ('k') | src/code-stubs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698