# HG changeset patch # User neliasso # Date 1499416672 -7200 # Node ID 3c5c50af29a7f1edb22dd546884d9f6123fc7ac4 # Parent ad6940426976489f8e8b2ebd2a88c42180ca4a0d 8183271: VectorizeDebug compiler directive command is broken Summary: Add parser support for uint Reviewed-by: kvn, thartmann diff -r ad6940426976 -r 3c5c50af29a7 hotspot/src/share/vm/compiler/compilerDirectives.hpp --- a/hotspot/src/share/vm/compiler/compilerDirectives.hpp Mon Jul 03 11:41:19 2017 +0200 +++ b/hotspot/src/share/vm/compiler/compilerDirectives.hpp Fri Jul 07 10:37:52 2017 +0200 @@ -64,7 +64,7 @@ NOT_PRODUCT(cflags(TraceOptoOutput, bool, TraceOptoOutput, TraceOptoOutput)) \ cflags(TraceSpilling, bool, TraceSpilling, TraceSpilling) \ cflags(Vectorize, bool, false, Vectorize) \ - cflags(VectorizeDebug, uintx, 0, VectorizeDebug) \ + cflags(VectorizeDebug, uintx, 0, VectorizeDebug) \ cflags(CloneMapDebug, bool, false, CloneMapDebug) \ cflags(IGVPrintLevel, intx, PrintIdealGraphLevel, IGVPrintLevel) \ cflags(MaxNodeLimit, intx, MaxNodeLimit, MaxNodeLimit) diff -r ad6940426976 -r 3c5c50af29a7 hotspot/src/share/vm/compiler/directivesParser.cpp --- a/hotspot/src/share/vm/compiler/directivesParser.cpp Mon Jul 03 11:41:19 2017 +0200 +++ b/hotspot/src/share/vm/compiler/directivesParser.cpp Fri Jul 07 10:37:52 2017 +0200 @@ -283,17 +283,18 @@ break; case JSON_NUMBER_INT: - if (option_key->flag_type != intxFlag) { - if (option_key->flag_type == doubleFlag) { - double dval = (double)v->int_value; - (set->*test)((void *)&dval); - break; - } + if (option_key->flag_type == intxFlag) { + intx ival = v->int_value; + (set->*test)((void *)&ival); + } else if (option_key->flag_type == uintxFlag) { + uintx ival = v->uint_value; + (set->*test)((void *)&ival); + } else if (option_key->flag_type == doubleFlag) { + double dval = (double)v->int_value; + (set->*test)((void *)&dval); + } else { error(VALUE_ERROR, "Cannot use int value for an %s flag", flag_type_names[option_key->flag_type]); return false; - } else { - intx ival = v->int_value; - (set->*test)((void *)&ival); } break; @@ -627,6 +628,8 @@ " match: \"foo/bar.*\"," "\n" " c2: {" "\n" " PrintInlining: false," "\n" + " VectorizeDebug: 1," "\n" + " VectorizeDebug: -1," "\n" " }" "\n" " }" "\n" "]" "\n", true); diff -r ad6940426976 -r 3c5c50af29a7 hotspot/src/share/vm/utilities/json.hpp --- a/hotspot/src/share/vm/utilities/json.hpp Mon Jul 03 11:41:19 2017 +0200 +++ b/hotspot/src/share/vm/utilities/json.hpp Fri Jul 07 10:37:52 2017 +0200 @@ -52,6 +52,7 @@ typedef union { int64_t int_value; + uint64_t uint_value; double double_value; struct {