Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-18 Thread Vladimir Kozlov
On Wed, 12 Feb 2025 03:03:34 GMT, Chris Plummer wrote: >> Before I forgot to answer you, @plummercj >> I completely agree with your comment about cleaning up wrapper subclasses >> which do nothing. >> >> I think some wrapper subclasses for CodeBlob were kept because of `is*()` >> which were u

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-11 Thread Chris Plummer
On Tue, 11 Feb 2025 23:55:46 GMT, Vladimir Kozlov wrote: > I think some wrapper subclasses for CodeBlob were kept because of `is*()` > which were used only in `PStack` to print name. Why not use `getName()` for > this purpose without big `if/else` there? Possibly getName() didn't exist when PS

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-11 Thread Vladimir Kozlov
On Sun, 9 Feb 2025 19:43:29 GMT, Vladimir Kozlov wrote: >> Remove virtual methods from CodeBlob and nmethod to simplify >> saving/restoring in Leyden AOT cache. It avoids the need to patch hidden >> VPTR pointer to class's virtual table. >> >> Added C++ static asserts to make sure no virtual m

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-11 Thread Vladimir Kozlov
On Mon, 10 Feb 2025 03:11:22 GMT, Chris Plummer wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix Zero and Minimal VM builds > > I almost wished I hadn't looked because there is a lot of SA CodeBlob support >

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-10 Thread Vladimir Kozlov
On Mon, 10 Feb 2025 16:23:53 GMT, Stefan Karlsson wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix Zero and Minimal VM builds > > We have a similar situation with oopDesc that are not allowed to have a > vta

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-10 Thread Vladimir Kozlov
On Mon, 10 Feb 2025 03:25:30 GMT, Chris Plummer wrote: >> src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/code/CodeCache.java line >> 38: >> >>> 36: public class CodeCache { >>> 37: private static GrowableArray heapArray; >>> 38: private static VirtualConstructor virtualConstructor; >>

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-10 Thread Stefan Karlsson
On Sun, 9 Feb 2025 19:43:29 GMT, Vladimir Kozlov wrote: >> Remove virtual methods from CodeBlob and nmethod to simplify >> saving/restoring in Leyden AOT cache. It avoids the need to patch hidden >> VPTR pointer to class's virtual table. >> >> Added C++ static asserts to make sure no virtual m

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-10 Thread Vladimir Kozlov
On Mon, 10 Feb 2025 11:04:38 GMT, Andrew Dinn wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix Zero and Minimal VM builds > > src/hotspot/share/code/codeBlob.cpp line 58: > >> 56: #include >> 57: >> 58: //

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-10 Thread Andrew Dinn
On Sun, 9 Feb 2025 19:43:29 GMT, Vladimir Kozlov wrote: >> Remove virtual methods from CodeBlob and nmethod to simplify >> saving/restoring in Leyden AOT cache. It avoids the need to patch hidden >> VPTR pointer to class's virtual table. >> >> Added C++ static asserts to make sure no virtual m

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-09 Thread Chris Plummer
On Mon, 10 Feb 2025 02:47:58 GMT, Chris Plummer wrote: >> Vladimir Kozlov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix Zero and Minimal VM builds > > src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/code/CodeCache.java line >

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-09 Thread Chris Plummer
On Sun, 9 Feb 2025 19:43:29 GMT, Vladimir Kozlov wrote: >> Remove virtual methods from CodeBlob and nmethod to simplify >> saving/restoring in Leyden AOT cache. It avoids the need to patch hidden >> VPTR pointer to class's virtual table. >> >> Added C++ static asserts to make sure no virtual m

Re: RFR: 8349088: De-virtualize Codeblob and nmethod [v2]

2025-02-09 Thread Vladimir Kozlov
> Remove virtual methods from CodeBlob and nmethod to simplify saving/restoring > in Leyden AOT cache. It avoids the need to patch hidden VPTR pointer to > class's virtual table. > > Added C++ static asserts to make sure no virtual methods are added in a > future. > > Fixed/cleaned SA code whi