RFR: 8332904: ubsan ppc64le: c1_LIRGenerator_ppc.cpp:581:21: runtime error: signed integer overflow: 9223372036854775807 + 1 cannot be represented in type 'long int'

Matthias Baesken mbaesken at openjdk.org
Mon May 27 14:53:07 UTC 2024


When using ubsan on Linux ppc64le we run into some overflows like this one

c1_LIRGenerator_ppc.cpp:581:21: runtime error: signed integer overflow: 9223372036854775807 + 1 cannot be represented in type 'long int'

Seems we have to add casts to get defined behavior.
There are similar places in the coding as well.

-------------

Commit messages:
 - JDK-8332904

Changes: https://git.openjdk.org/jdk/pull/19413/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=19413&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8332904
  Stats: 5 lines in 2 files changed: 0 ins; 0 del; 5 mod
  Patch: https://git.openjdk.org/jdk/pull/19413.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/19413/head:pull/19413

PR: https://git.openjdk.org/jdk/pull/19413


More information about the hotspot-compiler-dev mailing list