On Thu, 13 Mar 2025 16:21:07 GMT, Maurizio Cimadamore
wrote:
>> Quan Anh Mai has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> expand wildcard imports
>
> Marked as reviewed by mcimadamore (Reviewer).
@mcimadamore @JornVernee Thanks a lo
On Thu, 13 Mar 2025 05:46:44 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in
On Thu, 13 Mar 2025 05:46:44 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in
On Wed, 12 Mar 2025 11:15:29 GMT, Maurizio Cimadamore
wrote:
>> Quan Anh Mai 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 nine additional
>>
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Fri, 7 Mar 2025 17:38:13 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in t
On Fri, 7 Mar 2025 17:38:13 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in t
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Wed, 5 Feb 2025 10:18:01 GMT, Maurizio Cimadamore
wrote:
>> Only the return value of `CALLOC` is converted to `MemorySegment` in an
>> equivalent way, I believe passing a `MemorySegment` to a downcall involves
>> acquiring the corresponding segment? As a result, `FREE` is made to accept
>>
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Sat, 25 Jan 2025 02:32:56 GMT, Quan Anh Mai wrote:
>> But the address is immediately converted to memory segment using
>> MemorySegment::ofAddress, which is what the linker does anyway?
>
> Only the return value of `CALLOC` is converted to `MemorySegment` in an
> equivalent way, I believe pa
On Fri, 24 Jan 2025 11:57:06 GMT, Maurizio Cimadamore
wrote:
>> The main goal here is that passing/receiving raw addresses as longs is
>> cheaper than as `MemorySegment`s.
>
> But the address is immediately converted to memory segment using
> MemorySegment::ofAddress, which is what the linker
On Wed, 22 Jan 2025 16:45:39 GMT, Quan Anh Mai wrote:
>> test/micro/org/openjdk/bench/java/lang/foreign/AllocTest.java line 77:
>>
>>> 75: var freeAddr = lookup.findOrThrow("free");
>>> 76: CALLOC = linker.downcallHandle(callocAddr,
>>> FunctionDescriptor.of(ValueLayout.
On Mon, 16 Dec 2024 11:01:11 GMT, Maurizio Cimadamore
wrote:
>> Quan Anh Mai has updated the pull request incrementally with two additional
>> commits since the last revision:
>>
>> - wrong init
>> - move segment instance creation to SegmentFactories
>
> test/micro/org/openjdk/bench/java/lan
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Wed, 11 Dec 2024 19:29:13 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in
On Wed, 11 Dec 2024 19:29:13 GMT, Quan Anh Mai wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in
On Wed, 11 Dec 2024 18:50:18 GMT, Maurizio Cimadamore
wrote:
>> I want to put it here so that even if `SegmentFactories::allocateNative` is
>> not inlined, this small method will be more likely to be inlined and the
>> segment can be non-escape, then. I have added a comment regarding class
>>
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Wed, 11 Dec 2024 18:37:06 GMT, Quan Anh Mai wrote:
>> src/java.base/share/classes/jdk/internal/foreign/ArenaImpl.java line 53:
>>
>>> 51: Utils.checkAllocationSizeAndAlign(byteSize, byteAlignment);
>>> 52: long address = SegmentFactories.allocateNative(byteSize,
>>> byteAlign
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the uncommon path,
> increasing the chance the object being sc
On Mon, 9 Dec 2024 12:48:07 GMT, Maurizio Cimadamore
wrote:
>> src/java.base/share/classes/jdk/internal/foreign/SegmentFactories.java line
>> 213:
>>
>>> 211:
>>> 212: @DontInline
>>> 213: private static long allocateNativeOveraligned(long byteSize, long
>>> byteAlignment, MemorySess
On Fri, 6 Dec 2024 18:29:46 GMT, Jorn Vernee wrote:
>> Quan Anh Mai has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> address review
>
> src/java.base/share/classes/jdk/internal/foreign/ArenaImpl.java line 53:
>
>> 51: Utils.check
On Fri, 6 Dec 2024 16:30:47 GMT, Quan Anh Mai wrote:
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the unco
On Fri, 6 Dec 2024 18:33:33 GMT, Jorn Vernee wrote:
>> Hi,
>>
>> This patch improves the performance of a typical `Arena::allocate` in
>> several ways:
>>
>> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge
>> of the instance with the one obtained from the call in th
On Fri, 6 Dec 2024 16:30:47 GMT, Quan Anh Mai wrote:
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the unco
On Fri, 6 Dec 2024 16:30:47 GMT, Quan Anh Mai wrote:
> Hi,
>
> This patch improves the performance of a typical `Arena::allocate` in several
> ways:
>
> - Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
> the instance with the one obtained from the call in the unco
Hi,
This patch improves the performance of a typical `Arena::allocate` in several
ways:
- Delay the creation of the NativeMemorySegmentImpl. This avoids the merge of
the instance with the one obtained from the call in the uncommon path,
increasing the chance the object being scalar replaced.
-
28 matches
Mail list logo