-
Bug
-
Resolution: Duplicate
-
P4
-
None
-
9
After upgrading to Xcode 7.3 (7D175), clang generates new warnings such as:
/Users/dsimon/hs-comp/hotspot/src/share/vm/oops/klass.hpp:327:58: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
return (juint)lh >= (juint)(_lh_array_tag_type_value << _lh_array_tag_shift);
~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/dsimon/hs-comp/hotspot/src/share/vm/oops/klass.hpp:331:55: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
return (jint)lh < (jint)(_lh_array_tag_type_value << _lh_array_tag_shift);
~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/dsimon/hs-comp/hotspot/src/share/vm/opto/library_call.cpp:3773:20: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
<< Klass::_lh_array_tag_shift)
^
I think the fix is shown in http://hg.openjdk.java.net/graal/graal-jvmci-9/hotspot/rev/881f8ce4bb11
Also, the supported clang version check needs to be updated:
http://hg.openjdk.java.net/graal/graal-jvmci-9/hotspot/rev/a774e0a83dd4
/Users/dsimon/hs-comp/hotspot/src/share/vm/oops/klass.hpp:327:58: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
return (juint)lh >= (juint)(_lh_array_tag_type_value << _lh_array_tag_shift);
~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/dsimon/hs-comp/hotspot/src/share/vm/oops/klass.hpp:331:55: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
return (jint)lh < (jint)(_lh_array_tag_type_value << _lh_array_tag_shift);
~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/dsimon/hs-comp/hotspot/src/share/vm/opto/library_call.cpp:3773:20: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
<< Klass::_lh_array_tag_shift)
^
I think the fix is shown in http://hg.openjdk.java.net/graal/graal-jvmci-9/hotspot/rev/881f8ce4bb11
Also, the supported clang version check needs to be updated:
http://hg.openjdk.java.net/graal/graal-jvmci-9/hotspot/rev/a774e0a83dd4
- duplicates
-
JDK-8152856 Xcode 7.3 -Wshift-negative-value compile failure on Mac OS X
- Resolved