summaryrefslogtreecommitdiff
path: root/deps/v8/src/interpreter/bytecodes.h
diff options
context:
space:
mode:
authorMichaël Zasso <targos@protonmail.com>2017-05-02 10:50:00 +0200
committerMichaël Zasso <targos@protonmail.com>2017-05-06 20:02:35 +0200
commit60d1aac8d225e844e68ae48e8f3d58802e635fbe (patch)
tree922f347dd054db18d88666fad7181e5a777f4022 /deps/v8/src/interpreter/bytecodes.h
parent73d9c0f903ae371cd5011af64c3a6f69a1bda978 (diff)
downloadnode-new-60d1aac8d225e844e68ae48e8f3d58802e635fbe.tar.gz
deps: update V8 to 5.8.283.38
PR-URL: https://github.com/nodejs/node/pull/12784 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Diffstat (limited to 'deps/v8/src/interpreter/bytecodes.h')
-rw-r--r--deps/v8/src/interpreter/bytecodes.h54
1 files changed, 36 insertions, 18 deletions
diff --git a/deps/v8/src/interpreter/bytecodes.h b/deps/v8/src/interpreter/bytecodes.h
index f09af85be4..f6085269ff 100644
--- a/deps/v8/src/interpreter/bytecodes.h
+++ b/deps/v8/src/interpreter/bytecodes.h
@@ -51,7 +51,10 @@ namespace interpreter {
V(PopContext, AccumulatorUse::kNone, OperandType::kReg) \
V(LdaContextSlot, AccumulatorUse::kWrite, OperandType::kReg, \
OperandType::kIdx, OperandType::kUImm) \
+ V(LdaImmutableContextSlot, AccumulatorUse::kWrite, OperandType::kReg, \
+ OperandType::kIdx, OperandType::kUImm) \
V(LdaCurrentContextSlot, AccumulatorUse::kWrite, OperandType::kIdx) \
+ V(LdaImmutableCurrentContextSlot, AccumulatorUse::kWrite, OperandType::kIdx) \
V(StaContextSlot, AccumulatorUse::kRead, OperandType::kReg, \
OperandType::kIdx, OperandType::kUImm) \
V(StaCurrentContextSlot, AccumulatorUse::kRead, OperandType::kIdx) \
@@ -94,6 +97,8 @@ namespace interpreter {
OperandType::kIdx, OperandType::kIdx) \
V(StaNamedPropertyStrict, AccumulatorUse::kRead, OperandType::kReg, \
OperandType::kIdx, OperandType::kIdx) \
+ V(StaNamedOwnProperty, AccumulatorUse::kRead, OperandType::kReg, \
+ OperandType::kIdx, OperandType::kIdx) \
V(StaKeyedPropertySloppy, AccumulatorUse::kRead, OperandType::kReg, \
OperandType::kReg, OperandType::kIdx) \
V(StaKeyedPropertyStrict, AccumulatorUse::kRead, OperandType::kReg, \
@@ -151,6 +156,8 @@ namespace interpreter {
OperandType::kRegCount, OperandType::kIdx) \
V(CallProperty, AccumulatorUse::kWrite, OperandType::kReg, \
OperandType::kRegList, OperandType::kRegCount, OperandType::kIdx) \
+ V(CallWithSpread, AccumulatorUse::kWrite, OperandType::kReg, \
+ OperandType::kRegList, OperandType::kRegCount) \
V(TailCall, AccumulatorUse::kWrite, OperandType::kReg, \
OperandType::kRegList, OperandType::kRegCount, OperandType::kIdx) \
V(CallRuntime, AccumulatorUse::kWrite, OperandType::kRuntimeId, \
@@ -164,11 +171,11 @@ namespace interpreter {
V(InvokeIntrinsic, AccumulatorUse::kWrite, OperandType::kIntrinsicId, \
OperandType::kRegList, OperandType::kRegCount) \
\
- /* New operators */ \
- V(New, AccumulatorUse::kReadWrite, OperandType::kReg, OperandType::kRegList, \
- OperandType::kRegCount, OperandType::kIdx) \
- V(NewWithSpread, AccumulatorUse::kWrite, OperandType::kRegList, \
- OperandType::kRegCount) \
+ /* Construct operators */ \
+ V(Construct, AccumulatorUse::kReadWrite, OperandType::kReg, \
+ OperandType::kRegList, OperandType::kRegCount, OperandType::kIdx) \
+ V(ConstructWithSpread, AccumulatorUse::kReadWrite, OperandType::kReg, \
+ OperandType::kRegList, OperandType::kRegCount) \
\
/* Test Operators */ \
V(TestEqual, AccumulatorUse::kReadWrite, OperandType::kReg, \
@@ -226,9 +233,9 @@ namespace interpreter {
\
/* Control Flow -- carefully ordered for efficient checks */ \
/* - [Unconditional jumps] */ \
- V(JumpLoop, AccumulatorUse::kNone, OperandType::kImm, OperandType::kImm) \
+ V(JumpLoop, AccumulatorUse::kNone, OperandType::kUImm, OperandType::kImm) \
/* - [Forward jumps] */ \
- V(Jump, AccumulatorUse::kNone, OperandType::kImm) \
+ V(Jump, AccumulatorUse::kNone, OperandType::kUImm) \
/* - [Start constant jumps] */ \
V(JumpConstant, AccumulatorUse::kNone, OperandType::kIdx) \
/* - [Conditional jumps] */ \
@@ -244,15 +251,15 @@ namespace interpreter {
V(JumpIfToBooleanFalseConstant, AccumulatorUse::kRead, OperandType::kIdx) \
/* - [End constant jumps] */ \
/* - [Conditional immediate jumps] */ \
- V(JumpIfToBooleanTrue, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfToBooleanFalse, AccumulatorUse::kRead, OperandType::kImm) \
+ V(JumpIfToBooleanTrue, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfToBooleanFalse, AccumulatorUse::kRead, OperandType::kUImm) \
/* - [End ToBoolean jumps] */ \
- V(JumpIfTrue, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfFalse, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfNull, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfUndefined, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfJSReceiver, AccumulatorUse::kRead, OperandType::kImm) \
- V(JumpIfNotHole, AccumulatorUse::kRead, OperandType::kImm) \
+ V(JumpIfTrue, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfFalse, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfNull, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfUndefined, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfJSReceiver, AccumulatorUse::kRead, OperandType::kUImm) \
+ V(JumpIfNotHole, AccumulatorUse::kRead, OperandType::kUImm) \
\
/* Complex flow control For..in */ \
V(ForInPrepare, AccumulatorUse::kNone, OperandType::kReg, \
@@ -508,7 +515,9 @@ class V8_EXPORT_PRIVATE Bytecodes final {
bytecode == Bytecode::kLdaTheHole ||
bytecode == Bytecode::kLdaConstant ||
bytecode == Bytecode::kLdaContextSlot ||
- bytecode == Bytecode::kLdaCurrentContextSlot;
+ bytecode == Bytecode::kLdaCurrentContextSlot ||
+ bytecode == Bytecode::kLdaImmutableContextSlot ||
+ bytecode == Bytecode::kLdaImmutableCurrentContextSlot;
}
// Return true if |bytecode| is a register load without effects,
@@ -610,9 +619,14 @@ class V8_EXPORT_PRIVATE Bytecodes final {
}
// Returns true if the bytecode is a call or a constructor call.
- static constexpr bool IsCallOrNew(Bytecode bytecode) {
+ static constexpr bool IsCallOrConstruct(Bytecode bytecode) {
return bytecode == Bytecode::kCall || bytecode == Bytecode::kCallProperty ||
- bytecode == Bytecode::kTailCall || bytecode == Bytecode::kNew;
+ bytecode == Bytecode::kTailCall ||
+ bytecode == Bytecode::kConstruct ||
+ bytecode == Bytecode::kCallWithSpread ||
+ bytecode == Bytecode::kConstructWithSpread ||
+ bytecode == Bytecode::kInvokeIntrinsic ||
+ bytecode == Bytecode::kCallJSRuntime;
}
// Returns true if the bytecode is a call to the runtime.
@@ -717,6 +731,10 @@ class V8_EXPORT_PRIVATE Bytecodes final {
// Returns the equivalent jump bytecode without the accumulator coercion.
static Bytecode GetJumpWithoutToBoolean(Bytecode bytecode);
+ // Returns true if there is a call in the most-frequently executed path
+ // through the bytecode's handler.
+ static bool MakesCallAlongCriticalPath(Bytecode bytecode);
+
// Returns true if the bytecode is a debug break.
static bool IsDebugBreak(Bytecode bytecode);