GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — deps: V8: cherry-pick 53c4d057974a · nodejs/node@26cc160

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • common.gypi
  • deps/v8
    • src/regexp
      • regexp-bytecode-generator-inl.h
      • regexp-bytecode-generator.cc
      • regexp-bytecode-generator.h
    • test/mjsunit
      • mjsunit.status
      • regress
        • regress-1166138.js
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎common.gypi‎

Copy file name to clipboardExpand all lines: common.gypi
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636

3737
# Reset this number to 0 on major V8 upgrades.
3838
# Increment by one for each non-official patch applied to deps/v8.
39-
'v8_embedder_string': '-node.44',
39+
'v8_embedder_string': '-node.45',
4040

4141
##### V8 defaults for Node.js #####
4242

Collapse file

‎deps/v8/src/regexp/regexp-bytecode-generator-inl.h‎

Copy file name to clipboardExpand all lines: deps/v8/src/regexp/regexp-bytecode-generator-inl.h
+7-7Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ namespace v8 {
1414
namespace internal {
1515

1616
void RegExpBytecodeGenerator::Emit(uint32_t byte, uint32_t twenty_four_bits) {
17-
uint32_t word = ((twenty_four_bits << BYTECODE_SHIFT) | byte);
18-
DCHECK(pc_ <= buffer_.length());
19-
if (pc_ + 3 >= buffer_.length()) {
20-
Expand();
21-
}
22-
*reinterpret_cast<uint32_t*>(buffer_.begin() + pc_) = word;
23-
pc_ += 4;
17+
DCHECK(is_uint24(twenty_four_bits));
18+
Emit32((twenty_four_bits << BYTECODE_SHIFT) | byte);
19+
}
20+
21+
void RegExpBytecodeGenerator::Emit(uint32_t byte, int32_t twenty_four_bits) {
22+
DCHECK(is_int24(twenty_four_bits));
23+
Emit32((static_cast<uint32_t>(twenty_four_bits) << BYTECODE_SHIFT) | byte);
2424
}
2525

2626
void RegExpBytecodeGenerator::Emit16(uint32_t word) {
Collapse file

‎deps/v8/src/regexp/regexp-bytecode-generator.cc‎

Copy file name to clipboardExpand all lines: deps/v8/src/regexp/regexp-bytecode-generator.cc
+4-2Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,10 @@ bool RegExpBytecodeGenerator::Succeed() {
161161
void RegExpBytecodeGenerator::Fail() { Emit(BC_FAIL, 0); }
162162

163163
void RegExpBytecodeGenerator::AdvanceCurrentPosition(int by) {
164-
DCHECK_LE(kMinCPOffset, by);
165-
DCHECK_GE(kMaxCPOffset, by);
164+
// TODO(chromium:1166138): Turn back into DCHECKs once the underlying issue
165+
// is fixed.
166+
CHECK_LE(kMinCPOffset, by);
167+
CHECK_GE(kMaxCPOffset, by);
166168
advance_current_start_ = pc_;
167169
advance_current_offset_ = by;
168170
Emit(BC_ADVANCE_CP, by);
Collapse file

‎deps/v8/src/regexp/regexp-bytecode-generator.h‎

Copy file name to clipboardExpand all lines: deps/v8/src/regexp/regexp-bytecode-generator.h
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ class V8_EXPORT_PRIVATE RegExpBytecodeGenerator : public RegExpMacroAssembler {
8585
inline void Emit16(uint32_t x);
8686
inline void Emit8(uint32_t x);
8787
inline void Emit(uint32_t bc, uint32_t arg);
88+
inline void Emit(uint32_t bc, int32_t arg);
8889
// Bytecode buffer.
8990
int length();
9091
void Copy(byte* a);
Collapse file

‎deps/v8/test/mjsunit/mjsunit.status‎

Copy file name to clipboardExpand all lines: deps/v8/test/mjsunit/mjsunit.status
+3Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@
7373
# Enable once multi-byte prefixed opcodes are correctly handled
7474
'regress/wasm/regress-1065599': [SKIP],
7575

76+
# https://crbug.com/1166138
77+
'regress/regress-1166138': SKIP,
78+
7679
##############################################################################
7780
# Tests where variants make no sense.
7881
'd8/enable-tracing': [PASS, NO_VARIANTS],
Collapse file

‎deps/v8/test/mjsunit/regress/regress-1166138.js‎

Copy file name to clipboard
+7Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Copyright 2020 the V8 project authors. All rights reserved.
2+
// Use of this source code is governed by a BSD-style license that can be
3+
// found in the LICENSE file.
4+
5+
let badregexp = "(?:" + " ".repeat(32768*2)+ ")*";
6+
reg = RegExp(badregexp);
7+
reg.test()

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.