[12] RFR: 8214059: Undefined behaviour in ADLC

Simon Tooke stooke at redhat.com
Mon Nov 19 21:06:13 UTC 2018


I tried compiling with -fsanitize=undefined, and it found some issues in
ADLC, relying on undefined behaviour.

Issue: https://bugs.openjdk.java.net/browse/JDK-8214059

There are two issues: an incorrect C-style downcast (fixed by casting to
the correct class), and a reliance on undefined integer overflow
behaviour (proposed fix by using long long arithmetic and a compile-time
guard to check correct sizeof())

Thanks for your consideration,

More information about the hotspot-compiler-dev mailing list