aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Format/WhitespaceManager.cpp
diff options
context:
space:
mode:
authorIvan Tadeu Ferreira Antunes Filho <antunesi@google.com>2025-09-25 12:32:31 -0400
committerGitHub <noreply@github.com>2025-09-25 12:32:31 -0400
commit68a253da6498abe20b0e61e9dce488943aaf2c28 (patch)
tree08846f1e6d7ed2943a64abab75c3c4181c0d2cdc /clang/lib/Format/WhitespaceManager.cpp
parentc1b211034b854737245409b435726cd169349a4b (diff)
downloadllvm-68a253da6498abe20b0e61e9dce488943aaf2c28.zip
llvm-68a253da6498abe20b0e61e9dce488943aaf2c28.tar.gz
llvm-68a253da6498abe20b0e61e9dce488943aaf2c28.tar.bz2
[lldb][RISCV] Use uint64_t for emulating ADDI (#160550)
In RISC-V, the same instruction is used for both signed and unsigned additions. Signed integer overflow is undefined behavior in C++, but signed integer overflow is defined behavior when using ADDI in RISC-V. As we are emulating the RISC-V behavior we should be using uint. This fix the failure with ubsan introduced by #159842: lldb/source/Plugins/Instruction/RISCV/EmulateInstructionRISCV.cpp:807:40: runtime error: signed integer overflow: -9223372036854775808 + -16 cannot be represented in type 'int64_t' (aka 'long')
Diffstat (limited to 'clang/lib/Format/WhitespaceManager.cpp')
0 files changed, 0 insertions, 0 deletions