Integrated: 8311879: SA ClassWriter generates invalid invokedynamic code

2023-07-19 Thread Daohan Qu
On Wed, 12 Jul 2023 13:49:17 GMT, Daohan Qu wrote: > This patch should fix the wrong CP index for `invokedynamic` instruction > generated by SA's `ClassWriter`. The buggy code in > `sun.jvm.hotspot.tools.jcore.ByteCodeRewriter` should have been up-to-date > with the followin

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v3]

2023-07-19 Thread Daohan Qu
On Fri, 14 Jul 2023 02:45:36 GMT, Daohan Qu wrote: >> This patch should fix the wrong CP index for `invokedynamic` instruction >> generated by SA's `ClassWriter`. The buggy code in >> `sun.jvm.hotspot.tools.jcore.ByteCodeRewriter` should have been up-to-date >> wi

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v3]

2023-07-14 Thread Daohan Qu
On Fri, 14 Jul 2023 11:37:54 GMT, Coleen Phillimore wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Update copyright year > > Looks good. Thanks for your review, @coleenp ! --

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v3]

2023-07-13 Thread Daohan Qu
On Fri, 14 Jul 2023 02:45:36 GMT, Daohan Qu wrote: >> This patch should fix the wrong CP index for `invokedynamic` instruction >> generated by SA's `ClassWriter`. The buggy code in >> `sun.jvm.hotspot.tools.jcore.ByteCodeRewriter` should have been up-to-date >> wi

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v2]

2023-07-13 Thread Daohan Qu
On Thu, 13 Jul 2023 03:25:38 GMT, Daohan Qu wrote: >> This patch should fix the wrong CP index for `invokedynamic` instruction >> generated by SA's `ClassWriter`. The buggy code in >> `sun.jvm.hotspot.tools.jcore.ByteCodeRewriter` should have been up-to-date >> wi

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v2]

2023-07-13 Thread Daohan Qu
On Thu, 13 Jul 2023 20:33:45 GMT, Chris Plummer wrote: > ByteCodeRewriter.java needs a copyright update. You also need to update the > PR tittle to match the CR. Updated. - PR Comment: https://git.openjdk.org/jdk/pull/14852#issuecomment-1635181325

Re: RFR: 8311879: SA ClassWriter generates invalid invokedynamic code [v3]

2023-07-13 Thread Daohan Qu
t; > ### Test Results of release build on Linux x64 > * `jtreg:test/hotspot/jtreg/serviceability` and `jtreg:test/jdk/sun/tools/`: > PASS > * `tier1`: PASS > * `tier2` and `tier3`: PASS (Failures of > `sun/security/lib/cacerts/VerifyCACerts.java` and > `sun/security/pkcs11/K

Re: RFR: 8311879: ClassWriter generates invalid invokedynamic code [v2]

2023-07-12 Thread Daohan Qu
On Wed, 12 Jul 2023 15:20:35 GMT, Chen Liang wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Use Assert instead of throwing exceptions > > src/jdk.hotspot.agent/share/class

Re: RFR: 8311879: ClassWriter generates invalid invokedynamic code [v2]

2023-07-12 Thread Daohan Qu
t; > ### Test Results of release build on Linux x64 > * `jtreg:test/hotspot/jtreg/serviceability` and `jtreg:test/jdk/sun/tools/`: > PASS > * `tier1`: PASS > * `tier2` and `tier3`: PASS (Failures of > `sun/security/lib/cacerts/VerifyCACerts.java` and > `sun/security/pkcs11/K

RFR: 8311879: ClassWriter generates invalid invokedynamic code

2023-07-12 Thread Daohan Qu
This patch should fix the wrong CP index for `invokedynamic` instruction generated by SA's `ClassWriter`. The buggy code in `sun.jvm.hotspot.tools.jcore.ByteCodeRewriter` should have been up-to-date with the following code snippet in `hotspot`: https://github.com/openjdk/jdk/blob/753bd563ecca6b

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 13:44:53 GMT, Daniel D. Daugherty wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add a simple check > > Folks the GHA for this PR reported a failure in > servi

Integrated: 8310618: Test serviceability/sa/ClhsdbDumpclass.java fails after 8242152: 'StackMapTable:' missing from stdout/stderr

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 09:17:46 GMT, Daohan Qu wrote: > This patch should fix > [JDK-8310618](https://bugs.openjdk.org/browse/JDK-8310618). It attempts to > correct my errors in fixing > [JDK-8242152](https://bugs.openjdk.org/browse/JDK-8242152). This pull request has now bee

Re: RFR: 8310618: Test serviceability/sa/ClhsdbDumpclass.java fails after 8242152: 'StackMapTable:' missing from stdout/stderr

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 09:17:46 GMT, Daohan Qu wrote: > This patch should fix > [JDK-8310618](https://bugs.openjdk.org/browse/JDK-8310618). It attempts to > correct my errors in fixing > [JDK-8242152](https://bugs.openjdk.org/browse/JDK-8242152). The failure in GHA on `linux-x86`

Re: RFR: 8310618: Test serviceability/sa/ClhsdbDumpclass.java fails after 8242152: 'StackMapTable:' missing from stdout/stderr

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 09:37:40 GMT, Kevin Walls wrote: >> This patch should fix >> [JDK-8310618](https://bugs.openjdk.org/browse/JDK-8310618). It attempts to >> correct my errors in fixing >> [JDK-8242152](https://bugs.openjdk.org/browse/JDK-8242152). > > Yes, looks good. 8-) Thanks a lot for y

Re: RFR: 8310618: Test serviceability/sa/ClhsdbDumpclass.java fails after 8242152: 'StackMapTable:' missing from stdout/stderr

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 09:37:40 GMT, Kevin Walls wrote: >> This patch should fix >> [JDK-8310618](https://bugs.openjdk.org/browse/JDK-8310618). It attempts to >> correct my errors in fixing >> [JDK-8242152](https://bugs.openjdk.org/browse/JDK-8242152). > > Yes, looks good. 8-) Thanks for your re

RFR: 8310618: Test serviceability/sa/ClhsdbDumpclass.java fails after 8242152: 'StackMapTable:' missing from stdout/stderr

2023-06-22 Thread Daohan Qu
This patch should fix [JDK-8310618](https://bugs.openjdk.org/browse/JDK-8310618). It attempts to correct my errors in fixing [JDK-8242152](https://bugs.openjdk.org/browse/JDK-8242152). - Commit messages: - Let javap print additional info for checking Changes: https://git.openjdk.

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 08:59:42 GMT, Kevin Walls wrote: > I see the failure too. javap needs "-v" to show the StackMap info, I see that > on linux release and debug builds. Exactly! @kevinjwalls. And a situation similar to [this one](https://github.com/openjdk/jdk/pull/3004#issuecomment-800679752

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 07:38:21 GMT, David Holmes wrote: > What output is the test looking for i.e why is supposed to be writing it? If > it is the if (DEBUG) debugMessage(...) calls they are not enabled. It is looking for `StackMapTable` info in the javap output. > I've filed https://bugs.openjd

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 04:00:14 GMT, Daohan Qu wrote: >> This patch adds `StackMapTable` for the class files generated by `clhsdb`'s >> `buildreplayjars` command. This bug manifests itself during my diagnosing >> [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) an

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-22 Thread Daohan Qu
On Thu, 22 Jun 2023 04:00:14 GMT, Daohan Qu wrote: >> This patch adds `StackMapTable` for the class files generated by `clhsdb`'s >> `buildreplayjars` command. This bug manifests itself during my diagnosing >> [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) an

Integrated: 8242152: SA does not include StackMapTables when dumping .class files

2023-06-21 Thread Daohan Qu
On Tue, 20 Jun 2023 11:31:40 GMT, Daohan Qu wrote: > This patch adds `StackMapTable` for the class files generated by `clhsdb`'s > `buildreplayjars` command. This bug manifests itself during my diagnosing > [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) and needs

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v2]

2023-06-21 Thread Daohan Qu
On Thu, 22 Jun 2023 02:37:08 GMT, Daohan Qu wrote: >> This patch adds `StackMapTable` for the class files generated by `clhsdb`'s >> `buildreplayjars` command. This bug manifests itself during my diagnosing >> [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) an

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v3]

2023-06-21 Thread Daohan Qu
st `tier1-3` of release build on x86 linux finding only > one failure in `tier2` caused by > [JDK-8309214](https://bugs.openjdk.org/browse/JDK-8309214). > `jtreg:test/hotspot/jtreg/serviceability` and `jtreg:test/jdk/sun/tools/` > also passed. Daohan Qu has updated the pull reques

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v2]

2023-06-21 Thread Daohan Qu
On Wed, 21 Jun 2023 20:26:20 GMT, Chris Plummer wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix some code format issues > > I made a couple of minor suggestions. Otherwise it loo

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v2]

2023-06-21 Thread Daohan Qu
On Wed, 21 Jun 2023 20:42:04 GMT, Serguei Spitsyn wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix some code format issues > > src/jdk.hotspot.agent/share/classes/sun/jvm/hotspo

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v2]

2023-06-21 Thread Daohan Qu
On Wed, 21 Jun 2023 20:19:59 GMT, Chris Plummer wrote: >> Daohan Qu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix some code format issues > > src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/oop

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files [v2]

2023-06-21 Thread Daohan Qu
st `tier1-3` of release build on x86 linux finding only > one failure in `tier2` caused by > [JDK-8309214](https://bugs.openjdk.org/browse/JDK-8309214). > `jtreg:test/hotspot/jtreg/serviceability` and `jtreg:test/jdk/sun/tools/` > also passed. Daohan Qu has updated the pull reques

Re: RFR: 8242152: SA does not include StackMapTables when dumping .class files

2023-06-20 Thread Daohan Qu
On Tue, 20 Jun 2023 14:02:35 GMT, Ashutosh Mehra wrote: > On another note since you mentioned > [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) I should let you > know I have a fix for it and am planning to open a PR soon. Good news! Never mind and thanks for your notice 😄. ---

RFR: 8242152: SA does not include StackMapTables when dumping .class files

2023-06-20 Thread Daohan Qu
This patch adds `StackMapTable` for the class files generated by `clhsdb`'s `buildreplayjars` command. This bug manifests itself during my diagnosing [JDK-8309751](https://bugs.openjdk.org/browse/JDK-8309751) and needs to be fixed first. I have run jtreg test `tier1-3` of release build on x86 l