RFR(XS): 8245051: c1 is broken if it is compiled by gcc without -fno-lifetime-dse
Liu, Xin
xxinliu at amazon.com
Fri May 15 18:49:00 UTC 2020
Hi,
Please review the following patch.
Jbs: https://bugs.openjdk.java.net/browse/JDK-8245051
Webrev: http://cr.openjdk.java.net/~xliu/8245051/00/webrev/
I found this problem from centos’s java-11-openjdk. https://git.centos.org/rpms/java-11-openjdk/blob/c7/f/SPECS/java-11-openjdk.spec#_1327
'-std=gnu++98' is not a valid option for cc1. As a result, configure will fail to determine gcc supports -fno-lifetime-dse or not.
C1 acts weird if it is compiled by GCC without that flag.
After then, I built hotspot with -fsanitize=undefined. I found some interesting points for c1. With this patch, I can build the whole openjdk without -fno-lifetime-dse.
I've tested hotspot:tier1 and "gtest:all". Even though everything looks fine, I don't think we reach a point to lift "-fno-lifetime-dse". This patch just attempts to fix C1.
Thanks,
--lx
More information about the hotspot-compiler-dev
mailing list