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

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) >>

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

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

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

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

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

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

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: //

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

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) >>

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

2024-04-02 Thread Vladimir Ivanov
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) >>

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

2024-04-01 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) >>

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

2024-04-01 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