aboutsummaryrefslogtreecommitdiff
path: root/deps/v8/src/interpreter
diff options
context:
space:
mode:
authorMichaël Zasso <targos@protonmail.com>2018-10-24 15:30:26 +0200
committerMichaël Zasso <targos@protonmail.com>2018-10-28 10:17:58 +0100
commit124d91667abb203098baa7d6cf6011e8df5eeeff (patch)
tree105c8717e6a97f67656b3744863a1b8b310c74ce /deps/v8/src/interpreter
parent1b473542dc54cbf6185c12021076d5c7626046ea (diff)
downloadandroid-node-v8-124d91667abb203098baa7d6cf6011e8df5eeeff.tar.gz
android-node-v8-124d91667abb203098baa7d6cf6011e8df5eeeff.tar.bz2
android-node-v8-124d91667abb203098baa7d6cf6011e8df5eeeff.zip
deps: patch V8 to 7.0.276.32
Refs: https://github.com/v8/v8/compare/7.0.276.28...7.0.276.32 PR-URL: https://github.com/nodejs/node/pull/23851 Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Diffstat (limited to 'deps/v8/src/interpreter')
-rw-r--r--deps/v8/src/interpreter/bytecode-array-accessor.cc13
-rw-r--r--deps/v8/src/interpreter/bytecode-array-accessor.h2
2 files changed, 15 insertions, 0 deletions
diff --git a/deps/v8/src/interpreter/bytecode-array-accessor.cc b/deps/v8/src/interpreter/bytecode-array-accessor.cc
index ef6bdd30a1..3ec2cc595b 100644
--- a/deps/v8/src/interpreter/bytecode-array-accessor.cc
+++ b/deps/v8/src/interpreter/bytecode-array-accessor.cc
@@ -28,6 +28,19 @@ void BytecodeArrayAccessor::SetOffset(int offset) {
UpdateOperandScale();
}
+void BytecodeArrayAccessor::ApplyDebugBreak() {
+ // Get the raw bytecode from the bytecode array. This may give us a
+ // scaling prefix, which we can patch with the matching debug-break
+ // variant.
+ interpreter::Bytecode bytecode =
+ interpreter::Bytecodes::FromByte(bytecode_array_->get(bytecode_offset_));
+ if (interpreter::Bytecodes::IsDebugBreak(bytecode)) return;
+ interpreter::Bytecode debugbreak =
+ interpreter::Bytecodes::GetDebugBreak(bytecode);
+ bytecode_array_->set(bytecode_offset_,
+ interpreter::Bytecodes::ToByte(debugbreak));
+}
+
void BytecodeArrayAccessor::UpdateOperandScale() {
if (OffsetInBounds()) {
uint8_t current_byte = bytecode_array()->get(bytecode_offset_);
diff --git a/deps/v8/src/interpreter/bytecode-array-accessor.h b/deps/v8/src/interpreter/bytecode-array-accessor.h
index 443929aefe..e36eed8ade 100644
--- a/deps/v8/src/interpreter/bytecode-array-accessor.h
+++ b/deps/v8/src/interpreter/bytecode-array-accessor.h
@@ -70,6 +70,8 @@ class V8_EXPORT_PRIVATE BytecodeArrayAccessor {
void SetOffset(int offset);
+ void ApplyDebugBreak();
+
Bytecode current_bytecode() const;
int current_bytecode_size() const;
int current_offset() const { return bytecode_offset_; }