8322781: C1: Debug build crash in GraphBuilder::vmap() when print stats

Reviewed-by: kvn, thartmann, shade
This commit is contained in:
Denghui Dong 2024-01-04 13:11:47 +00:00
parent df22fb322e
commit 27d5f5c237
2 changed files with 14 additions and 1 deletions
src/hotspot/share/c1
test/hotspot/jtreg/compiler/arguments

@ -4468,7 +4468,9 @@ void GraphBuilder::append_unsafe_get_and_set(ciMethod* callee, bool is_add) {
#ifndef PRODUCT
void GraphBuilder::print_stats() {
vmap()->print();
if (UseLocalValueNumbering) {
vmap()->print();
}
}
#endif // PRODUCT

@ -57,6 +57,17 @@
*
*/
/**
* @test
* @bug 8322781
* @requires vm.debug
* @summary Test flag with c1 value numbering
*
* @run main/othervm -XX:+PrintValueNumbering -XX:+Verbose -XX:-UseLocalValueNumbering
* -Xcomp -XX:TieredStopAtLevel=1
* compiler.arguments.TestC1Globals
*/
package compiler.arguments;
public class TestC1Globals {