From duke at openjdk.org Tue Oct 11 19:18:19 2022 From: duke at openjdk.org (John Hamer) Date: Tue, 11 Oct 2022 19:18:19 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v5] In-Reply-To: References: Message-ID: On Mon, 26 Sep 2022 15:50:13 GMT, Ivan Ponomarev wrote: >> This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. >> >> See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). > > Ivan Ponomarev has updated the pull request incrementally with two additional commits since the last revision: > > - Merge pull request #7 from atp-mipt/jchekProblems > > jcheck Whitespace error fix > - jcheck Whitespace error fix Marked as reviewed by JohnHamer-Glasgow at github.com (no known OpenJDK username). ------------- PR: https://git.openjdk.org/jol/pull/24 From duke at openjdk.org Tue Oct 11 20:10:52 2022 From: duke at openjdk.org (John Hamer) Date: Tue, 11 Oct 2022 20:10:52 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v5] In-Reply-To: References: Message-ID: On Mon, 26 Sep 2022 15:50:13 GMT, Ivan Ponomarev wrote: >> This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. >> >> See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). > > Ivan Ponomarev has updated the pull request incrementally with two additional commits since the last revision: > > - Merge pull request #7 from atp-mipt/jchekProblems > > jcheck Whitespace error fix > - jcheck Whitespace error fix Marked as reviewed by JohnHamer-Glasgow at github.com (no known OpenJDK username). ------------- PR: https://git.openjdk.org/jol/pull/24 From duke at openjdk.org Tue Oct 11 20:10:54 2022 From: duke at openjdk.org (John Hamer) Date: Tue, 11 Oct 2022 20:10:54 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v2] In-Reply-To: <7y8viv04-M1IVLe7w4ea1RzRaAaBJ8i-kyXICzRbotw=.5193b836-860b-4087-a2c2-8d101e25c4de@github.com> References: <_0fDDdBGH0x5UUI9fnk_YEGHyZkV0VsiixwHZE18s8A=.dc26c851-0b81-4547-a27c-d15cc7ac7551@github.com> <7y8viv04-M1IVLe7w4ea1RzRaAaBJ8i-kyXICzRbotw=.5193b836-860b-4087-a2c2-8d101e25c4de@github.com> Message-ID: <1v61ixi4C136s__5ZrVfJW6lJcOCHgSdXrhKbCo4p7M=.647163c7-ab5e-4c47-bfe2-e585e7c6da49@github.com> On Thu, 29 Sep 2022 10:45:22 GMT, Aleksey Shipilev wrote: >> Yes, John indeed approves the whole idea, and he signed OCA on his own. >> He's not on GitHub, but he's available via email. > > Idea: can John send the reply to https://mail.openjdk.org/pipermail/jol-dev/2022-September/000464.html then? I'm happy for the GPL text to be removed. The original code is mine, and I am more than happy to have it included in JOL. ------------- PR: https://git.openjdk.org/jol/pull/24 From duke at openjdk.org Tue Oct 11 20:10:57 2022 From: duke at openjdk.org (John Hamer) Date: Tue, 11 Oct 2022 20:10:57 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v2] In-Reply-To: References: Message-ID: On Mon, 22 Aug 2022 07:51:02 GMT, Ivan Ponomarev wrote: >> This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. >> >> See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). > > Ivan Ponomarev has updated the pull request incrementally with one additional commit since the last revision: > > update copyright notice, lint jol-core/src/main/java/org/openjdk/jol/ljv/pom.xml line 30: > 28: > 29: John Hamer > 30: J.Hamer at cs.auckland.ac.nz Suggestion: John.Hamer at glasgow.ac.uk ------------- PR: https://git.openjdk.org/jol/pull/24 From shade at openjdk.org Wed Oct 12 13:04:26 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Wed, 12 Oct 2022 13:04:26 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v2] In-Reply-To: <1v61ixi4C136s__5ZrVfJW6lJcOCHgSdXrhKbCo4p7M=.647163c7-ab5e-4c47-bfe2-e585e7c6da49@github.com> References: <_0fDDdBGH0x5UUI9fnk_YEGHyZkV0VsiixwHZE18s8A=.dc26c851-0b81-4547-a27c-d15cc7ac7551@github.com> <7y8viv04-M1IVLe7w4ea1RzRaAaBJ8i-kyXICzRbotw=.5193b836-860b-4087-a2c2-8d101e25c4de@github.com> <1v61ixi4C136s__5ZrVfJW6lJcOCHgSdXrhKbCo4p7M=.647163c7-ab5e-4c47-bfe2-e585e7c6da49@github.com> Message-ID: On Sun, 2 Oct 2022 09:44:12 GMT, John Hamer wrote: >> Idea: can John send the reply to https://mail.openjdk.org/pipermail/jol-dev/2022-September/000464.html then? > > I'm happy for the GPL text to be removed. The original code is mine, and I am more than happy to have it included in JOL. Thank you for chiming in, @JohnHamer-Glasgow! (And welcome to JOL!) I have a suggestion to remove `Author` and `Created` lines from this file, because it does not match the style of other files in the project, and this might be lost by accident, or otherwise raise questions during the review. For example, if we ever divide/delete `LJV.java`, it would be hard to judge where these comments should go. There is a tangential rule that we try to avoid `@author` javadoc tags, to be consistent with OpenJDK code style. I think John is now recorded as developer in project properties, which is cleaner, better, and gives John the credit for the entire project, not just single file. ------------- PR: https://git.openjdk.org/jol/pull/24 From shade at openjdk.org Wed Oct 12 13:20:32 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Wed, 12 Oct 2022 13:20:32 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v5] In-Reply-To: References: Message-ID: On Mon, 26 Sep 2022 15:50:13 GMT, Ivan Ponomarev wrote: >> This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. >> >> See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). > > Ivan Ponomarev has updated the pull request incrementally with two additional commits since the last revision: > > - Merge pull request #7 from atp-mipt/jchekProblems > > jcheck Whitespace error fix > - jcheck Whitespace error fix All right! I have only a few minor nits from the final reading of this patch. John also had some comments, please address them as well. Then we are good to go! It would be a very important contribution to JOL, which extends its usefulness much further. Thank you all for perseverance in this PR! Even though not required by contribution rules, I'd like to get the blessing from @robilad for accepting this contribution :) jol-core/src/main/java/org/openjdk/jol/info/FieldLayout.java line 109: > 107: } > 108: > 109: public FieldData data() { I suggest we put a little comment in method body here: // TODO: This is public to let LJV access it. Figure out a cleaner way to do this without extending the API surface. jol-core/src/main/java/org/openjdk/jol/ljv/IntrospectionWithReflectionAPI.java line 90: > 88: if (!(Modifier.isStatic(field.getModifiers())) > 89: && !ljv.canIgnoreField(field) > 90: ) { Suggestion: if (!Modifier.isStatic(field.getModifiers()) && !ljv.canIgnoreField(field)) { jol-core/src/main/java/org/openjdk/jol/ljv/LJV.java line 28: > 26: > 27: //- Author: John Hamer > 28: //- Created: Sat May 10 15:27:48 2003 See the relevant discussion: https://github.com/openjdk/jol/pull/24/files/5001f98dc2117fbd0e0acd94ffddbccc36887acc#r993431410 jol-core/src/main/java/org/openjdk/jol/ljv/LJV.java line 240: > 238: || ignoreSet.contains(field.getType()) > 239: || ignoreSet.contains(field.getType().getPackage()) > 240: ; Suggestion: return Modifier.isStatic(field.getModifiers()) || ignoreSet.contains(field) || ignoreSet.contains(field.getName()) || ignoreSet.contains(field.getType()) || ignoreSet.contains(field.getType().getPackage()); jol-core/src/main/java/org/openjdk/jol/ljv/Quote.java line 41: > 39: || Character.isLetter(c) > 40: || Character.isDigit(c) > 41: ; Suggestion: return (canAppearUnquotedInLabelChars.indexOf(c) != -1) || Character.isLetter(c) || Character.isDigit(c); ------------- PR: https://git.openjdk.org/jol/pull/24 From shade at redhat.com Wed Oct 12 16:56:16 2022 From: shade at redhat.com (Aleksey Shipilev) Date: Wed, 12 Oct 2022 18:56:16 +0200 Subject: Heads-up: Dropping support for JDK 7 Message-ID: <153d9771-0bb0-5b1a-f671-5e22ec481799@redhat.com> Hi, We are intending to drop the JDK 7 support in JOL: https://github.com/openjdk/jol/pull/34 If you have a strong opinion that we should *not* drop JDK 7 support, please speak up soon. -- Thanks, -Aleksey From shade at openjdk.org Wed Oct 12 17:00:59 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Wed, 12 Oct 2022 17:00:59 GMT Subject: RFR: CODETOOLS-7903352: JOL: Drop support for JDK 7 Message-ID: <2QI4xCDd0ot0GHiI0ulkJqnMvuEHj-vLhBuvjcDVv0c=.e50990fc-c01a-4520-963b-582a9166626a@github.com> Head JDK 20-ea does not support building with -source/target 7 anymore. JDK 7 is very old and unlikely to be used widely. We can bump the minimal version to JDK 8 to get... ahem... all the new features that release brings! If you have a strong opinion that we should *not* drop JDK 7 support, please speak up soon. ------------- Commit messages: - Do not test JDK 7 either - Fix Changes: https://git.openjdk.org/jol/pull/34/files Webrev: https://webrevs.openjdk.org/?repo=jol&pr=34&range=00 Issue: https://bugs.openjdk.org/browse/CODETOOLS-7903352 Stats: 94 lines in 14 files changed: 1 ins; 40 del; 53 mod Patch: https://git.openjdk.org/jol/pull/34.diff Fetch: git fetch https://git.openjdk.org/jol pull/34/head:pull/34 PR: https://git.openjdk.org/jol/pull/34 From duke at openjdk.org Sat Oct 15 05:42:12 2022 From: duke at openjdk.org (Ivan Ponomarev) Date: Sat, 15 Oct 2022 05:42:12 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v6] In-Reply-To: References: Message-ID: > This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. > > See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). Ivan Ponomarev has updated the pull request incrementally with one additional commit since the last revision: fix review comments ------------- Changes: - all: https://git.openjdk.org/jol/pull/24/files - new: https://git.openjdk.org/jol/pull/24/files/4d44d66e..042c17a1 Webrevs: - full: https://webrevs.openjdk.org/?repo=jol&pr=24&range=05 - incr: https://webrevs.openjdk.org/?repo=jol&pr=24&range=04-05 Stats: 19 lines in 4 files changed: 2 ins; 8 del; 9 mod Patch: https://git.openjdk.org/jol/pull/24.diff Fetch: git fetch https://git.openjdk.org/jol pull/24/head:pull/24 PR: https://git.openjdk.org/jol/pull/24 From duke at openjdk.org Sat Oct 15 05:42:13 2022 From: duke at openjdk.org (Ivan Ponomarev) Date: Sat, 15 Oct 2022 05:42:13 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v2] In-Reply-To: References: Message-ID: On Sun, 2 Oct 2022 09:01:45 GMT, John Hamer wrote: >> Ivan Ponomarev has updated the pull request incrementally with one additional commit since the last revision: >> >> update copyright notice, lint > > jol-core/src/main/java/org/openjdk/jol/ljv/pom.xml line 30: > >> 28: >> 29: John Hamer >> 30: J.Hamer at cs.auckland.ac.nz > > Suggestion: > > John.Hamer at glasgow.ac.uk This POM file was a lefover of the LJV project and it is not included in the final version ------------- PR: https://git.openjdk.org/jol/pull/24 From shade at openjdk.org Tue Oct 18 16:28:24 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 16:28:24 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v6] In-Reply-To: References: Message-ID: On Sat, 15 Oct 2022 05:42:12 GMT, Ivan Ponomarev wrote: >> This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. >> >> See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). > > Ivan Ponomarev has updated the pull request incrementally with one additional commit since the last revision: > > fix review comments Looks good. As stated earlier, I'd like to have @robilad's blessing for this large contribution (even though it is not required). ------------- Marked as reviewed by shade (Committer). PR: https://git.openjdk.org/jol/pull/24 From shade at openjdk.org Tue Oct 18 16:48:31 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 16:48:31 GMT Subject: Withdrawn: CODETOOLS-7903352: JOL: Drop support for JDK 7 In-Reply-To: <2QI4xCDd0ot0GHiI0ulkJqnMvuEHj-vLhBuvjcDVv0c=.e50990fc-c01a-4520-963b-582a9166626a@github.com> References: <2QI4xCDd0ot0GHiI0ulkJqnMvuEHj-vLhBuvjcDVv0c=.e50990fc-c01a-4520-963b-582a9166626a@github.com> Message-ID: On Wed, 12 Oct 2022 16:46:10 GMT, Aleksey Shipilev wrote: > Head JDK 20-ea does not support building with -source/target 7 anymore. JDK 7 is very old and unlikely to be used widely. We can bump the minimal version to JDK 8 to get... ahem... all the new features that release brings! > > If you have a strong opinion that we should *not* drop JDK 7 support, please speak up soon. This pull request has been closed without being integrated. ------------- PR: https://git.openjdk.org/jol/pull/34 From duke at openjdk.org Tue Oct 18 16:49:52 2022 From: duke at openjdk.org (duke) Date: Tue, 18 Oct 2022 16:49:52 GMT Subject: git: openjdk/jol: 7903352: JOL: Drop support for JDK 7 Message-ID: <1bb075b4-1e15-4000-92b4-251145fa43f5@openjdk.org> Changeset: 153c1559 Author: Aleksey Shipil?v Committer: GitHub Date: 2022-10-18 18:45:41 +0000 URL: https://git.openjdk.org/jol/commit/153c1559cdf6b43b63ea1b0085cd09694ac82c4a 7903352: JOL: Drop support for JDK 7 ! .github/workflows/pre-integration.yml ! jol-cli/src/main/java/org/openjdk/jol/operations/ClasspathedOperation.java ! jol-cli/src/main/java/org/openjdk/jol/operations/HeapDumpStats.java ! jol-cli/src/main/java/org/openjdk/jol/operations/ObjectShapes.java ! jol-core/src/main/java/org/openjdk/jol/info/ClassData.java ! jol-core/src/main/java/org/openjdk/jol/info/FieldLayout.java ! jol-core/src/main/java/org/openjdk/jol/info/GraphLayout.java ! jol-core/src/main/java/org/openjdk/jol/layouters/HotSpotLayouter.java ! jol-core/src/main/java/org/openjdk/jol/vm/HotspotUnsafe.java ! jol-core/src/main/java/org/openjdk/jol/vm/VM.java ! jol-core/src/main/java/org/openjdk/jol/vm/sa/AttachMain.java ! jol-samples/src/main/java/org/openjdk/jol/samples/JOLSample_14_FatLocking.java ! jol-samples/src/main/java/org/openjdk/jol/samples/JOLSample_27_Colocation.java ! pom.xml From shade at openjdk.org Tue Oct 18 17:00:16 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 17:00:16 GMT Subject: RFR: CODETOOLS-7903363: JOL: Update pre-integration testing workflows Message-ID: Time to update our workflows: new JDKs, new OSes, new GH plugins. ------------- Commit messages: - Fix Changes: https://git.openjdk.org/jol/pull/35/files Webrev: https://webrevs.openjdk.org/?repo=jol&pr=35&range=00 Issue: https://bugs.openjdk.org/browse/CODETOOLS-7903363 Stats: 11 lines in 1 file changed: 1 ins; 5 del; 5 mod Patch: https://git.openjdk.org/jol/pull/35.diff Fetch: git fetch https://git.openjdk.org/jol pull/35/head:pull/35 PR: https://git.openjdk.org/jol/pull/35 From shade at openjdk.org Tue Oct 18 17:14:17 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 17:14:17 GMT Subject: RFR: CODETOOLS-7903363: JOL: Update pre-integration testing workflows [v2] In-Reply-To: References: Message-ID: > Time to update our workflows: new JDKs, new OSes, new GH plugins. Aleksey Shipilev has updated the pull request incrementally with one additional commit since the last revision: Try setup-java at v3 ------------- Changes: - all: https://git.openjdk.org/jol/pull/35/files - new: https://git.openjdk.org/jol/pull/35/files/1c62804d..fe57fa90 Webrevs: - full: https://webrevs.openjdk.org/?repo=jol&pr=35&range=01 - incr: https://webrevs.openjdk.org/?repo=jol&pr=35&range=00-01 Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod Patch: https://git.openjdk.org/jol/pull/35.diff Fetch: git fetch https://git.openjdk.org/jol pull/35/head:pull/35 PR: https://git.openjdk.org/jol/pull/35 From markus at markusheiden.de Sat Oct 15 11:32:04 2022 From: markus at markusheiden.de (Markus Heiden) Date: Sat, 15 Oct 2022 13:32:04 +0200 Subject: Self attach fails on macOS / Eclipse Temurin Message-ID: <6400497a-fc3b-8a39-bf82-9612c915cb90@markusheiden.de> Hi, I am using jol-core under macOS 12.6 with Eclipse Temurin 19 -Djdk.attach.allowAttachSelf -Djol.tryWithSudo=true and it is not able to attach itself: WARNING: Unable to attach Serviceability Agent. Unable to attach even with escalated privileges: sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper sudo: a password is required When manuall executing SenseAccessMain sun.jvm.hotspot.runtime.VM cannot be found and it thus exits with code 1: java.lang.ClassNotFoundException: sun.jvm.hotspot.runtime.VM Am I missing some point or do I really need to start my app as root? Thanks, Markus From shade at openjdk.org Tue Oct 18 17:20:17 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 17:20:17 GMT Subject: Withdrawn: CODETOOLS-7903363: JOL: Update pre-integration testing workflows In-Reply-To: References: Message-ID: On Tue, 18 Oct 2022 16:53:53 GMT, Aleksey Shipilev wrote: > Time to update our workflows: new JDKs, new OSes, new GH plugins. This pull request has been closed without being integrated. ------------- PR: https://git.openjdk.org/jol/pull/35 From shade at openjdk.org Tue Oct 18 17:23:17 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 17:23:17 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL In-Reply-To: References: <9xlrNd1y7irAwO8F4NMjwUgyCeQWs3Ekwn11aMYm-bg=.bc0bc6dc-309c-4f58-b21e-8909e68bf444@github.com> Message-ID: On Mon, 26 Sep 2022 15:21:53 GMT, Ivan Ponomarev wrote: >>> It seems that we managed to sort out everything with the OCA >> >> Nice, I checked the OCA signatories list, and all PR contributors seems to be accounted for. >> >> In this PR, I see the commits from two more people (@[OrangeFlag](https://github.com/atp-mipt/jol/commits?author=OrangeFlag) and @[gogagum](https://github.com/atp-mipt/jol/commits?author=gogagum) -- and who are not in PR contributor list. I see they have OCA on file, so that is not a problem for this PR, but maybe you want to credit them as well? >> >>> The code is linted and IMO ready for review >> >> I'll start reviewing it then! Thanks. > > @shipilev sorry for the inattention, hope everything is addressed now One more thing, @inponomarev -- please merge from current JOL master to get test pipeline fixes. GitHub actions need to test this PR, maybe you need to go to your fork "Actions" tab and press the "Approve workflow" button there. ------------- PR: https://git.openjdk.org/jol/pull/24 From duke at openjdk.org Tue Oct 18 17:24:11 2022 From: duke at openjdk.org (duke) Date: Tue, 18 Oct 2022 17:24:11 GMT Subject: git: openjdk/jol: 7903363: JOL: Update pre-integration testing workflows Message-ID: <5607b6aa-0881-4be5-acfe-636b749f87a4@openjdk.org> Changeset: 247f12ac Author: Aleksey Shipil?v Committer: GitHub Date: 2022-10-18 19:18:16 +0000 URL: https://git.openjdk.org/jol/commit/247f12ac57e58235d4232a4a766ae068b2b906bc 7903363: JOL: Update pre-integration testing workflows ! .github/workflows/pre-integration.yml From shade at redhat.com Tue Oct 18 18:14:00 2022 From: shade at redhat.com (Aleksey Shipilev) Date: Tue, 18 Oct 2022 20:14:00 +0200 Subject: Self attach fails on macOS / Eclipse Temurin In-Reply-To: <6400497a-fc3b-8a39-bf82-9612c915cb90@markusheiden.de> References: <6400497a-fc3b-8a39-bf82-9612c915cb90@markusheiden.de> Message-ID: <2ecfccc0-ccb0-8ca0-a2d7-00e57cfe90f5@redhat.com> On 10/15/22 13:32, Markus Heiden wrote: > I am using jol-core under macOS 12.6 with Eclipse Temurin 19 > -Djdk.attach.allowAttachSelf -Djol.tryWithSudo=true and it is not able > to attach itself: > > WARNING: Unable to attach Serviceability Agent. Unable to attach even > with escalated privileges: sudo: a terminal is required to read the > password; either use the -S option to read from standard input or > configure an askpass helper > sudo: a password is required > > When manuall executing SenseAccessMain sun.jvm.hotspot.runtime.VM cannot > be found and it thus exits with code 1: > java.lang.ClassNotFoundException: sun.jvm.hotspot.runtime.VM It is possible Serviceability Agent (SA) is not shipped with that JDK. > Am I missing some point or do I really need to start my app as root? You don't need to start with Serviceability Agent (SA) to get most out of the JOL. SA is there to poll some of the things from VM directly, without guessing. But the overwhelming majority of the time, JOL guesses correctly. I also see modern JDK reshuffled SA code a little bit, so current JOL fails there. I'll try to see if that code can be salvages somehow. Meanwhile, just trust JOL data without SA. -- Thanks, -Aleksey From shade at openjdk.org Tue Oct 18 19:05:27 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 19:05:27 GMT Subject: RFR: CODETOOLS-7903364: JOL: Fix support for modern SA Message-ID: SA shuffled a few things around in newer JDKs, we need to update JOL support to match it. ------------- Commit messages: - Fix Changes: https://git.openjdk.org/jol/pull/36/files Webrev: https://webrevs.openjdk.org/?repo=jol&pr=36&range=00 Issue: https://bugs.openjdk.org/browse/CODETOOLS-7903364 Stats: 52 lines in 4 files changed: 9 ins; 10 del; 33 mod Patch: https://git.openjdk.org/jol/pull/36.diff Fetch: git fetch https://git.openjdk.org/jol pull/36/head:pull/36 PR: https://git.openjdk.org/jol/pull/36 From shade at openjdk.org Tue Oct 18 19:09:03 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 19:09:03 GMT Subject: RFR: CODETOOLS-7903364: JOL: Fix support for modern SA [v2] In-Reply-To: References: Message-ID: > SA shuffled a few things around in newer JDKs, we need to update JOL support to match it. Aleksey Shipilev has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains two additional commits since the last revision: - Merge branch 'master' into CODETOOLS-7903364-modern-sa - Fix ------------- Changes: - all: https://git.openjdk.org/jol/pull/36/files - new: https://git.openjdk.org/jol/pull/36/files/79f829e0..10bde0d7 Webrevs: - full: https://webrevs.openjdk.org/?repo=jol&pr=36&range=01 - incr: https://webrevs.openjdk.org/?repo=jol&pr=36&range=00-01 Stats: 11 lines in 1 file changed: 1 ins; 5 del; 5 mod Patch: https://git.openjdk.org/jol/pull/36.diff Fetch: git fetch https://git.openjdk.org/jol pull/36/head:pull/36 PR: https://git.openjdk.org/jol/pull/36 From duke at openjdk.org Tue Oct 18 19:17:25 2022 From: duke at openjdk.org (duke) Date: Tue, 18 Oct 2022 19:17:25 GMT Subject: git: openjdk/jol: 7903364: JOL: Fix support for modern SA Message-ID: <883f77ad-a804-449e-964b-60df78f8a047@openjdk.org> Changeset: 2d958ff5 Author: Aleksey Shipil?v Committer: GitHub Date: 2022-10-18 21:16:25 +0000 URL: https://git.openjdk.org/jol/commit/2d958ff579c4fedfb906126dc4498dacb2dc2695 7903364: JOL: Fix support for modern SA ! jol-core/src/main/java/org/openjdk/jol/vm/HotspotUnsafe.java ! jol-core/src/main/java/org/openjdk/jol/vm/sa/Constants.java ! jol-core/src/main/java/org/openjdk/jol/vm/sa/ServiceabilityAgentSupport.java ! jol-core/src/main/java/org/openjdk/jol/vm/sa/UniverseTask.java From shade at redhat.com Tue Oct 18 19:19:47 2022 From: shade at redhat.com (Aleksey Shipilev) Date: Tue, 18 Oct 2022 21:19:47 +0200 Subject: Self attach fails on macOS / Eclipse Temurin In-Reply-To: <2ecfccc0-ccb0-8ca0-a2d7-00e57cfe90f5@redhat.com> References: <6400497a-fc3b-8a39-bf82-9612c915cb90@markusheiden.de> <2ecfccc0-ccb0-8ca0-a2d7-00e57cfe90f5@redhat.com> Message-ID: <367e164d-366c-fc29-9ed8-77077518f5a0@redhat.com> On 10/18/22 20:14, Aleksey Shipilev wrote: > I also see modern JDK reshuffled SA code a little bit, so current JOL fails there. I'll try to > see if that code can be salvages somehow. Seems doable! https://github.com/openjdk/jol/commit/2d958ff579c4fedfb906126dc4498dacb2dc2695 Please try to either build the fresh JOL from source, or pick the JAR here: https://builds.shipilev.net/jol/jol-cli-latest.jar While there might still be MacOS-specific issues left, this works reliably on Linux with Temurin 19+36 (note the absence of any additional options): $ ~/Install/temurin-19+36/bin/java -jar jol-cli-latest.jar internals java.lang.String # Running 64-bit HotSpot VM. # Using compressed oop with 3-bit shift. # Using compressed klass with 0x0000000800000000 base address and 0-bit shift. # Objects are 8 bytes aligned. # ref, bool, byte, char, shrt, int, flt, lng, dbl # Field sizes: 4, 1, 1, 2, 2, 4, 4, 8, 8 # Array element sizes: 4, 1, 1, 2, 2, 4, 4, 8, 8 # Array base offsets: 16, 16, 16, 16, 16, 16, 16, 16, 16 Instantiated the sample instance via default constructor. java.lang.String object internals: OFF SZ TYPE DESCRIPTION VALUE 0 8 (object header: mark) 0x0000000000000001 (non-biasable; age: 0) 8 4 (object header: class) 0x000089b8 12 4 int String.hash 0 16 1 byte String.coder 0 17 1 boolean String.hashIsZero false 18 2 (alignment/padding gap) 20 4 byte[] String.value [] Instance size: 24 bytes Space losses: 2 bytes internal + 0 bytes external = 2 bytes total -- Thanks, -Aleksey From shade at openjdk.org Tue Oct 18 19:21:02 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Tue, 18 Oct 2022 19:21:02 GMT Subject: Withdrawn: CODETOOLS-7903364: JOL: Fix support for modern SA In-Reply-To: References: Message-ID: On Tue, 18 Oct 2022 18:59:29 GMT, Aleksey Shipilev wrote: > SA shuffled a few things around in newer JDKs, we need to update JOL support to match it. This pull request has been closed without being integrated. ------------- PR: https://git.openjdk.org/jol/pull/36 From shade at openjdk.org Wed Oct 19 13:04:18 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Wed, 19 Oct 2022 13:04:18 GMT Subject: RFR: 7903366: JOL: Clean up VM configuration messages Message-ID: We can be a little more clean with VM configuration messages. ------------- Commit messages: - Work - Fix Changes: https://git.openjdk.org/jol/pull/37/files Webrev: https://webrevs.openjdk.org/?repo=jol&pr=37&range=00 Issue: https://bugs.openjdk.org/browse/CODETOOLS-7903366 Stats: 31 lines in 1 file changed: 16 ins; 8 del; 7 mod Patch: https://git.openjdk.org/jol/pull/37.diff Fetch: git fetch https://git.openjdk.org/jol pull/37/head:pull/37 PR: https://git.openjdk.org/jol/pull/37 From duke at openjdk.org Wed Oct 19 13:45:24 2022 From: duke at openjdk.org (duke) Date: Wed, 19 Oct 2022 13:45:24 GMT Subject: git: openjdk/jol: 7903366: JOL: Clean up VM configuration messages Message-ID: <9a025db6-99d0-4d5c-88f8-4aac1cd2e8c2@openjdk.org> Changeset: 482c0ee8 Author: Aleksey Shipil?v Committer: GitHub Date: 2022-10-19 15:43:21 +0000 URL: https://git.openjdk.org/jol/commit/482c0ee85a7767eda55defd2ebb9da74ae8e6985 7903366: JOL: Clean up VM configuration messages ! jol-core/src/main/java/org/openjdk/jol/vm/HotspotUnsafe.java From shade at openjdk.org Wed Oct 19 13:47:22 2022 From: shade at openjdk.org (Aleksey Shipilev) Date: Wed, 19 Oct 2022 13:47:22 GMT Subject: Withdrawn: 7903366: JOL: Clean up VM configuration messages In-Reply-To: References: Message-ID: On Wed, 19 Oct 2022 12:58:46 GMT, Aleksey Shipilev wrote: > We can be a little more clean with VM configuration messages. This pull request has been closed without being integrated. ------------- PR: https://git.openjdk.org/jol/pull/37 From duke at openjdk.org Wed Oct 19 14:43:38 2022 From: duke at openjdk.org (Ivan Ponomarev) Date: Wed, 19 Oct 2022 14:43:38 GMT Subject: RFR: CODETOOLS-7903176: Move LJV inside JOL [v7] In-Reply-To: References: Message-ID: > This moves https://github.com/atp-mipt/ljv project inside JOL in order for LJV to get access to internal JOL's APIs. > > See blogposts about LJV [in Russian](https://habr.com/ru/post/599045/) / [in English](https://dzone.com/articles/what-can-we-learn-from-java-data-structures-visual). Ivan Ponomarev has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 100 commits: - Merge remote-tracking branch 'upstream/master' - fix review comments - Merge pull request #7 from atp-mipt/jchekProblems jcheck Whitespace error fix - jcheck Whitespace error fix - leftover comments + braces (#6) * leftover comments + braces * remove leftover pom.xml * remove extra copyright comments Co-authored-by: Ivan Ponomarev - minor changes (#5) * HashCodeCollision reimplementation * JDK headers fix * LJV Github actions removed * other code review fixes Co-authored-by: Ivan Ponomarev - update copyright notice, lint - code cleanup - Move ljv inside jol (#2) * sub module ljv in jol-core * LJV 1.7 JDK version Co-authored-by: Victor Petrosyan - Merge remote-tracking branch 'upstream/master' - ... and 90 more: https://git.openjdk.org/jol/compare/482c0ee8...043009e8 ------------- Changes: https://git.openjdk.org/jol/pull/24/files Webrev: https://webrevs.openjdk.org/?repo=jol&pr=24&range=06 Stats: 4177 lines in 59 files changed: 4176 ins; 0 del; 1 mod Patch: https://git.openjdk.org/jol/pull/24.diff Fetch: git fetch https://git.openjdk.org/jol pull/24/head:pull/24 PR: https://git.openjdk.org/jol/pull/24