Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v3]

2024-04-03 Thread Axel Boldt-Christmas
On Thu, 4 Apr 2024 00:05:20 GMT, Vladimir Kozlov wrote: >> Revert [JDK-8152664](https://bugs.openjdk.org/browse/JDK-8152664) RFE >> [changes](https://github.com/openjdk/jdk/commit/b853eb7f5ca24eeeda18acbb14287f706499c365) >> which was used for AOT [JEP 295](https://openjdk.org/jeps/295) >> imp

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v3]

2024-04-03 Thread Vladimir Kozlov
On Thu, 4 Apr 2024 00:05:20 GMT, Vladimir Kozlov wrote: >> Revert [JDK-8152664](https://bugs.openjdk.org/browse/JDK-8152664) RFE >> [changes](https://github.com/openjdk/jdk/commit/b853eb7f5ca24eeeda18acbb14287f706499c365) >> which was used for AOT [JEP 295](https://openjdk.org/jeps/295) >> imp

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v3]

2024-04-03 Thread Coleen Phillimore
On Wed, 3 Apr 2024 23:50:47 GMT, Daniel D. Daugherty wrote: >> Coleen Phillimore has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix spacing and punctuation. make log_info into log_debug. > > src/hotspot/share/oops/instanceKlass.cpp lin

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v4]

2024-04-03 Thread Coleen Phillimore
> This change simplifies the code that grows the jmethodID cache in > InstanceKlass. Instead of lazily, when there's a rare request for a > jmethodID for an obsolete method, the jmethodID cache is grown during the > RedefineClasses safepoint. The InstanceKlass's jmethodID cache is lazily > al

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v3]

2024-04-03 Thread Vladimir Kozlov
> Revert [JDK-8152664](https://bugs.openjdk.org/browse/JDK-8152664) RFE > [changes](https://github.com/openjdk/jdk/commit/b853eb7f5ca24eeeda18acbb14287f706499c365) > which was used for AOT [JEP 295](https://openjdk.org/jeps/295) > implementation in JDK 9. The code was left in HotSpot assuming it

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v3]

2024-04-03 Thread Daniel D . Daugherty
On Wed, 3 Apr 2024 23:05:24 GMT, Coleen Phillimore wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Coleen Phillimore
On Wed, 3 Apr 2024 13:25:36 GMT, Coleen Phillimore wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Coleen Phillimore
On Wed, 3 Apr 2024 20:46:55 GMT, Daniel D. Daugherty wrote: >> Coleen Phillimore has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Refactoring suggested by Serguei. > > src/hotspot/share/oops/method.cpp line 2200: > >> 2198: >> 2199: R

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v3]

2024-04-03 Thread Coleen Phillimore
> This change simplifies the code that grows the jmethodID cache in > InstanceKlass. Instead of lazily, when there's a rare request for a > jmethodID for an obsolete method, the jmethodID cache is grown during the > RedefineClasses safepoint. The InstanceKlass's jmethodID cache is lazily > al

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Daniel D . Daugherty
On Wed, 3 Apr 2024 13:25:36 GMT, Coleen Phillimore wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses

Re: RFR: JDK-8322042: HeapDumper should perform merge on the current thread instead of VMThread [v2]

2024-04-03 Thread Kevin Walls
On Tue, 2 Apr 2024 21:13:33 GMT, Alex Menkov wrote: >> The fix updated HeapDumper to always perform merge on the current thread. >> >> Testing: tier1-5, all HeapDump-related tests >> Covered heap dumping scenarios: >> - `jcmd GC.heap_dump` command; >> - `HotSpotDiagnosticMXBean.dumpHea

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Chris Plummer
On Wed, 3 Apr 2024 13:37:56 GMT, Christoph Langer wrote: > Couldn't we just have an unconditional default for the GC.heap_dump > `filename` option? This would simplify the documentation. E.g. we could write > `If not specified, defaults to java_pid.hprof in the working directory > or value con

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Chris Plummer
On Wed, 3 Apr 2024 09:04:34 GMT, Matthias Baesken wrote: > > There's still the question of whether or not it is even appropriate to have > > -XX options taking the place of jcmd options. > > Some people (like our cloud support colleagues and also some who commented) > would like this approach,

Re: RFR: JDK-8322042: HeapDumper should perform merge on the current thread instead of VMThread [v2]

2024-04-03 Thread Alex Menkov
On Wed, 3 Apr 2024 10:09:20 GMT, Kevin Walls wrote: > Are we saying there is never any need to perform the merge in a VM Operation? > Originally (JDK-8306441) it's either done in the attach thread, or a VM > operation if we are in another thread. But maybe that was just being cautious. Correct

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Chris Plummer
On Wed, 3 Apr 2024 08:03:22 GMT, Matthias Baesken wrote: > > There's also a question of whether currently missing doc updates for > > HeapDumpGzipLevel should be made part of this PR > > because it complicates back porting. > > It should most likely be a separate PR (the title of this one does

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 17:55:38 GMT, Stefan Karlsson wrote: >> No, `CodeCache::blob_count()` uses different macro `FOR_ALL_HEAPS(heap)` >> because it looks for all code blobs, not only nmethods. >> >> `CodeCache::nmethod_count()` is the only place where `FOR_ALL_NMETHOD_HEAPS >> ` was used. So I

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 17:50:15 GMT, Stefan Karlsson wrote: >> No special rules here. I simply want to see all `virtual` methods explicitly >> and `override` is required by C++. >> I would like to keep it this way in these changes. I am investigating >> possibility to convert all these virtual meth

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Mon, 1 Apr 2024 21:07:31 GMT, Vladimir Kozlov wrote: >> Revert [JDK-8152664](https://bugs.openjdk.org/browse/JDK-8152664) RFE >> [changes](https://github.com/openjdk/jdk/commit/b853eb7f5ca24eeeda18acbb14287f706499c365) >> which was used for AOT [JEP 295](https://openjdk.org/jeps/295) >> imp

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 16:00:01 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > Nice! > > We've wanted to clean up some interfaces between the CodeCache an

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 15:35:49 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/gc/x/xUnload.cpp line 78: > >> 76: class XIsUnloadingBeha

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Alex Menkov
On Wed, 3 Apr 2024 13:25:36 GMT, Coleen Phillimore wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 15:49:00 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/runtime/frame.cpp line 208: > >> 206: address frame::raw_

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Stefan Karlsson
On Wed, 3 Apr 2024 16:38:13 GMT, Vladimir Kozlov wrote: >> src/hotspot/share/code/codeCache.cpp line 1009: >> >>> 1007: int CodeCache::nmethod_count() { >>> 1008: int count = 0; >>> 1009: for (GrowableArrayIterator heap = >>> _nmethod_heaps->begin(); heap != _nmethod_heaps->end(); ++heap) {

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Stefan Karlsson
On Wed, 3 Apr 2024 16:29:03 GMT, Vladimir Kozlov wrote: >> src/hotspot/share/code/codeBlob.hpp line 409: >> >>> 407: >>> 408: // GC/Verification support >>> 409: virtual void preserve_callee_argument_oops(frame fr, const >>> RegisterMap *reg_map, OopClosure* f) override { /* nothing to do

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 15:30:00 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/compiler/compileBroker.cpp line 1379: > >> 1377: if (os

Integrated: JDK-8327474 Review use of java.io.tmpdir in jdk tests

2024-04-03 Thread Bill Huang
On Mon, 18 Mar 2024 16:47:24 GMT, Bill Huang wrote: > This task addresses an essential aspect of our testing infrastructure: the > proper handling and cleanup of temporary files and socket files created > during test execution. The motivation behind these changes is to prevent the > accumulati

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 15:12:31 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/code/nmethod.cpp line 812: > >> 810: // By calling th

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 15:01:22 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/code/codeCache.cpp line 1009: > >> 1007: int CodeCache::n

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 14:44:03 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed not_used state of nmethod > > src/hotspot/share/code/codeBlob.hpp line 409: > >> 407: >> 408: // GC/Ve

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Serguei Spitsyn
On Wed, 3 Apr 2024 13:25:36 GMT, Coleen Phillimore wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Vladimir Kozlov
On Wed, 3 Apr 2024 02:55:52 GMT, Vladimir Ivanov wrote: > What about `CompiledMethod_lock`? There's no `CompiledMethod` anymore, but > the lock name still refers to it. It was different changes [JDK-8226705](https://bugs.openjdk.org/browse/JDK-8226705). Renaming it will complicate these chang

Re: RFR: 8329332: Remove CompiledMethod and CodeBlobLayout classes [v2]

2024-04-03 Thread Stefan Karlsson
On Mon, 1 Apr 2024 21:07:31 GMT, Vladimir Kozlov wrote: >> Revert [JDK-8152664](https://bugs.openjdk.org/browse/JDK-8152664) RFE >> [changes](https://github.com/openjdk/jdk/commit/b853eb7f5ca24eeeda18acbb14287f706499c365) >> which was used for AOT [JEP 295](https://openjdk.org/jeps/295) >> imp

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Christoph Langer
On Wed, 27 Mar 2024 13:44:42 GMT, Matthias Baesken wrote: >> Currently jcmd command GC.heap_dump only works with an additionally provided >> file name. >> Syntax : GC.heap_dump [options] >> >> In case the JVM has the XX - flag HeapDumpPath set, we should support an >> additional mode where th

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Coleen Phillimore
On Wed, 3 Apr 2024 12:42:30 GMT, Coleen Phillimore wrote: >> src/hotspot/share/oops/instanceKlass.cpp line 2335: >> >>> 2333: jmethodID new_id = Method::make_jmethod_id(class_loader_data(), >>> method); >>> 2334: Atomic::release_store(&jmeths[idnum+1], new_id); >>> 2335: retur

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass [v2]

2024-04-03 Thread Coleen Phillimore
> This change simplifies the code that grows the jmethodID cache in > InstanceKlass. Instead of lazily, when there's a rare request for a > jmethodID for an obsolete method, the jmethodID cache is grown during the > RedefineClasses safepoint. The InstanceKlass's jmethodID cache is lazily > al

Re: RFR: 8313332: Simplify lazy jmethodID cache in InstanceKlass

2024-04-03 Thread Coleen Phillimore
On Wed, 3 Apr 2024 02:41:06 GMT, Serguei Spitsyn wrote: >> This change simplifies the code that grows the jmethodID cache in >> InstanceKlass. Instead of lazily, when there's a rare request for a >> jmethodID for an obsolete method, the jmethodID cache is grown during the >> RedefineClasses s

Integrated: 8236736: Change notproduct JVM flags to develop flags

2024-04-03 Thread Coleen Phillimore
On Thu, 28 Mar 2024 22:53:22 GMT, Coleen Phillimore wrote: > Remove the notproduct distinction for command line options, rather than > trying to wrestle the macros to fix the bug that they've been treated as > develop options for some time now. This simplifies the command line option > macros

Re: RFR: 8236736: Change notproduct JVM flags to develop flags [v4]

2024-04-03 Thread Coleen Phillimore
On Tue, 2 Apr 2024 19:47:23 GMT, Coleen Phillimore wrote: >> Remove the notproduct distinction for command line options, rather than >> trying to wrestle the macros to fix the bug that they've been treated as >> develop options for some time now. This simplifies the command line option >> mac

Re: RFR: JDK-8322042: HeapDumper should perform merge on the current thread instead of VMThread [v2]

2024-04-03 Thread Kevin Walls
On Tue, 2 Apr 2024 21:13:33 GMT, Alex Menkov wrote: >> The fix updated HeapDumper to always perform merge on the current thread. >> >> Testing: tier1-5, all HeapDump-related tests >> Covered heap dumping scenarios: >> - `jcmd GC.heap_dump` command; >> - `HotSpotDiagnosticMXBean.dumpHea

Re: RFR: JDK-8303689: javac -Xlint could/should report on "dangling" doc comments

2024-04-03 Thread Magnus Ihse Bursie
On Wed, 27 Mar 2024 22:04:30 GMT, Jonathan Gibbons wrote: > Please review the updates to support a proposed new > `-Xlint:dangling-doc-comments` option. > > The work can be thought of as in 3 parts: > > 1. An update to the `javac` internal class `DeferredLintHandler` so that it > is possible

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Matthias Baesken
On Fri, 29 Mar 2024 04:15:24 GMT, Chris Plummer wrote: > There's still the question of whether or not it is even appropriate to have > -XX options taking the place of jcmd options. Some people (like our cloud support colleagues and also some who commented) would like this approach, some find i

Re: RFR: JDK-8327769: jcmd GC.heap_dump without options should write to location given by -XX:HeapDumpPath, if set [v10]

2024-04-03 Thread Matthias Baesken
On Fri, 29 Mar 2024 04:15:24 GMT, Chris Plummer wrote: > There's also a question of whether currently missing doc updates for > HeapDumpGzipLevel should be made part of this PR > because it complicates back porting. It should most likely be a separate PR (the title of this one does not match,