multimedia/yt-dlp: update to 2025.1.12
[oi-userland.git] / components / runtime / openjdk-8 / patches / 0034-patch-hotspot_src_share_vm_oops_klass.hpp.patch
blobf6a818c158114bb47482df9f3aa4b109f123cfce
1 $NetBSD: patch-hotspot_src_share_vm_oops_klass.hpp,v 1.1 2015/09/12 16:56:48 joerg Exp $
3 Left shift of negative values is UB.
5 --- hotspot/src/share/vm/oops/klass.hpp.orig
6 +++ hotspot/src/share/vm/oops/klass.hpp
7 @@ -358,11 +358,11 @@
9 static bool layout_helper_is_typeArray(jint lh) {
10 // _lh_array_tag_type_value == (lh >> _lh_array_tag_shift);
11 - return (juint)lh >= (juint)(_lh_array_tag_type_value << _lh_array_tag_shift);
12 + return (juint)lh >= ((juint)_lh_array_tag_type_value << _lh_array_tag_shift);
14 static bool layout_helper_is_objArray(jint lh) {
15 // _lh_array_tag_obj_value == (lh >> _lh_array_tag_shift);
16 - return (jint)lh < (jint)(_lh_array_tag_type_value << _lh_array_tag_shift);
17 + return (jint)lh < (jint)((juint)_lh_array_tag_type_value << _lh_array_tag_shift);
19 static int layout_helper_header_size(jint lh) {
20 assert(lh < (jint)_lh_neutral_value, "must be array");