[8u] RFR(S): 8244548: JDK 8u: sun.misc.Version.jdkUpdateVersion() returns wrong result
Andrew Hughes
gnu.andrew at redhat.com
Mon May 11 17:38:59 UTC 2020
On 07/05/2020 16:55, Simon Tooke wrote:
> (disclaimer: I am not a reviewer)
>
>
> I believe it's a "good thing" to shrink the reserved1 bitfield, as I
> suspect the entire struct grows by 4 bytes otherwise.
>
>
> Original:
>
> 644 unsigned int jdk_version; /* Consists of major, minor, micro (n.n.n)
> */ 1645 /* and build number (xx) */ 1646 unsigned int update_version :
> 8; /* Update release version (uu) */ 1647 unsigned int
> special_update_version : 8; /* Special update release version (c)*/ 1648
> unsigned int reserved1 : 16; 1649 unsigned int reserved2; The proposed
> patch: 44 unsigned int jdk_version; /* Consists of major, minor, micro
> (n.n.n) */ 1645 /* and build number (xx) */ 1646 unsigned int
> update_version : 16; /* Update release version (uu) */ 1647 unsigned int
> special_update_version : 8; /* Special update release version (c)*/ 1648
> unsigned int reserved1 : 16; 1649 unsigned int reserved2; Note that the
> original sum of bitfields is 32 bits, so it will fit into a 4 byte int
> (which it is surrounded by) The proposed sum of bitfields is 40 bits,
> which will probably cause a new 4 byte bitfield to be generated under
> the hood.
>
> -Simon
>
>
I don't know what happened here, but this is nearly impossible to read
as one unbroken line of text. Can you add some line breaks?
Thanks,
--
Andrew :)
Senior Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)
PGP Key: ed25519/0xCFDA0F9B35964222 (hkp://keys.gnupg.net)
Fingerprint = 5132 579D D154 0ED2 3E04 C5A0 CFDA 0F9B 3596 4222
More information about the jdk8u-dev
mailing list