Skip to content

Commit

Permalink
deps: V8: cherry-pick a3cc8522a4c8
Browse files Browse the repository at this point in the history
Original commit message:

    [riscv] avoid cpu probing in li_ptr

    CPU probing is an expensive thing to do and we should avoid doing it upon every li_ptr call.

    Fixes performance regresion bisected in riscv-forks/electron#1

    Change-Id: Ib5ff89b2a730e08de6735123ae60adeffe811ed8
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5612950
    Commit-Queue: Yahan Lu <yahan@iscas.ac.cn>
    Reviewed-by: Yahan Lu <yahan@iscas.ac.cn>
    Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#94349}

Refs: v8/v8@a3cc852
PR-URL: #53412
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
kxxt authored and targos committed Jun 20, 2024
1 parent 2defaaf commit bd68888
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

# Reset this number to 0 on major V8 upgrades.
# Increment by one for each non-official patch applied to deps/v8.
'v8_embedder_string': '-node.14',
'v8_embedder_string': '-node.15',

##### V8 defaults for Node.js #####

Expand Down
1 change: 1 addition & 0 deletions deps/v8/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@ Kevin Gibbons <bakkot@gmail.com>
Keyhan Vakil <kvakil@googlecontrib.kvakil.me>
Kris Selden <kris.selden@gmail.com>
Kyounga Ra <kyounga@alticast.com>
Levi Zim <rsworktech@outlook.com>
Loo Rong Jie <loorongjie@gmail.com>
Lu Yahan <yahan@iscas.ac.cn>
Ludovic Mermod <ludovic.mermod@gmail.com>
Expand Down
1 change: 0 additions & 1 deletion deps/v8/src/codegen/riscv/assembler-riscv.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1087,7 +1087,6 @@ void Assembler::GeneralLi(Register rd, int64_t imm) {
}

void Assembler::li_ptr(Register rd, int64_t imm) {
base::CPU cpu;
// Initialize rd with an address
// Pointers are 48 bits
// 6 fixed instructions are generated
Expand Down

0 comments on commit bd68888

Please sign in to comment.