Re: RFR: 8356693: AOT assembly phase fails with -javaagent [v2]

2025-05-14 Thread Ioi Lam
On Tue, 13 May 2025 08:50:59 GMT, Aleksey Shipilev wrote: >> Ioi Lam 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 five additional commits >>

Re: RFR: 8356693: AOT assembly phase fails with -javaagent [v2]

2025-05-14 Thread Calvin Cheung
On Wed, 14 May 2025 21:03:35 GMT, Ioi Lam wrote: >> https://openjdk.org/jeps/483 mentions: >> >>> To enjoy the benefits of the AOT cache generated during a training run, the >>> training run and all subsequent runs must be essentially similar. [...] All >>> runs must not use JVMTI agents that

Re: RFR: 8356693: AOT assembly phase fails with -javaagent [v2]

2025-05-14 Thread Ashutosh Mehra
On Wed, 14 May 2025 16:05:18 GMT, Ioi Lam wrote: >>> That's what I had in an earlier version, but then there's no code to free >>> the allocated entries, and I am too lazy to write the deallocator. >>> >>> Either way the effect is the same. The trivial amount of memory used by the >>> entries

Re: RFR: 8356693: AOT assembly phase fails with -javaagent [v2]

2025-05-14 Thread Ashutosh Mehra
On Wed, 14 May 2025 21:03:35 GMT, Ioi Lam wrote: >> https://openjdk.org/jeps/483 mentions: >> >>> To enjoy the benefits of the AOT cache generated during a training run, the >>> training run and all subsequent runs must be essentially similar. [...] All >>> runs must not use JVMTI agents that

Re: RFR: 8356693: AOT assembly phase fails with -javaagent [v2]

2025-05-14 Thread Ioi Lam
> https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can arbitrarily rewrite classfiles >> using ClassFileL

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-14 Thread Ioi Lam
On Wed, 14 May 2025 02:21:39 GMT, Ashutosh Mehra wrote: >>> Instead of intercepting here would it be better if we can clear >>> `JvmtiAgentList::_list` in `CDSConfig::check_aotmode_create()`? >> >> That's what I had in an earlier version, but then there's no code to free >> the allocated entri

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Ashutosh Mehra
On Tue, 13 May 2025 20:59:48 GMT, Ioi Lam wrote: > That's what I had in an earlier version, but then there's no code to free the > allocated entries, and I am too lazy to write the deallocator. > > Either way the effect is the same. The trivial amount of memory used by the > entries are not re

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Ioi Lam
On Tue, 13 May 2025 20:45:24 GMT, Ashutosh Mehra wrote: > Instead of intercepting here would it be better if we can clear > `JvmtiAgentList::_list` in `CDSConfig::check_aotmode_create()`? That's what I had in an earlier version, but then there's no code to free the allocated entries, and I am

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Ashutosh Mehra
On Sun, 11 May 2025 04:57:44 GMT, Ioi Lam wrote: > https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can a

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Andrey Turbanov
On Sun, 11 May 2025 04:57:44 GMT, Ioi Lam wrote: > https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can a

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Aleksey Shipilev
On Sun, 11 May 2025 04:57:44 GMT, Ioi Lam wrote: > https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can a

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-12 Thread Aleksey Shipilev
On Mon, 12 May 2025 17:21:30 GMT, Ioi Lam wrote: >> src/hotspot/share/prims/jvmtiAgent.cpp line 588: >> >>> 586: // Agents are allowed with -XX:AOTMode=record and >>> -XX:AOTMode=on/auto. >>> 587: // Agents are completely disabled when -XX:AOTMode=create >>> 588: assert(!CDSConfig::

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-12 Thread Ioi Lam
On Mon, 12 May 2025 14:46:44 GMT, Aleksey Shipilev wrote: >> https://openjdk.org/jeps/483 mentions: >> >>> To enjoy the benefits of the AOT cache generated during a training run, the >>> training run and all subsequent runs must be essentially similar. [...] All >>> runs must not use JVMTI age

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-12 Thread Aleksey Shipilev
On Sun, 11 May 2025 04:57:44 GMT, Ioi Lam wrote: > https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can a