On Thu, 12 Sep 2024 12:44:41 GMT, Per Minborg wrote:
>> This PR proposes to add a new overload to `MemorySegment::getString` whereby
>> it is possible to pass in a known byte length of the content in a segment
>> that should be converted to a String. This is useful in case one already
>> knows
On Thu, 12 Sep 2024 13:44:34 GMT, Maurizio Cimadamore
wrote:
>> Per Minborg 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 10 additional
>> co
On Thu, 12 Sep 2024 12:44:41 GMT, Per Minborg wrote:
>> This PR proposes to add a new overload to `MemorySegment::getString` whereby
>> it is possible to pass in a known byte length of the content in a segment
>> that should be converted to a String. This is useful in case one already
>> knows
> This PR proposes to add a new overload to `MemorySegment::getString` whereby
> it is possible to pass in a known byte length of the content in a segment
> that should be converted to a String. This is useful in case one already
> knows the byte length and thereby does not need to scan for a nu
On Wed, 28 Aug 2024 09:57:42 GMT, Maurizio Cimadamore
wrote:
> Ok, I suppose what you do get is the auto-detection of charset length, which
> adjusts the size of the copy...
NVM, this is not what this impl is doing. I see no performance benefit for
using the new API over a `copy`. If so, this
On Tue, 27 Aug 2024 09:36:56 GMT, Per Minborg wrote:
> This PR proposes to add a new overload to `MemorySegment::getString` whereby
> it is possible to pass in a known byte length of the content in a segment
> that should be converted to a String. This is useful in case one already
> knows the
On Wed, 28 Aug 2024 09:56:43 GMT, Maurizio Cimadamore
wrote:
>> src/java.base/share/classes/java/lang/foreign/MemorySegment.java line 1316:
>>
>>> 1314:
>>> 1315: /**
>>> 1316: * Reads a string using the given byte length from this segment
>>> at the given offset,
>>
>> What happens
On Wed, 28 Aug 2024 09:52:10 GMT, Maurizio Cimadamore
wrote:
>> This PR proposes to add a new overload to `MemorySegment::getString` whereby
>> it is possible to pass in a known byte length of the content in a segment
>> that should be converted to a String. This is useful in case one already
On Tue, 27 Aug 2024 09:36:56 GMT, Per Minborg wrote:
> This PR proposes to add a new overload to `MemorySegment::getString` whereby
> it is possible to pass in a known byte length of the content in a segment
> that should be converted to a String. This is useful in case one already
> knows the
This PR proposes to add a new overload to `MemorySegment::getString` whereby it
is possible to pass in a known byte length of the content in a segment that
should be converted to a String. This is useful in case one already knows the
byte length and thereby does not need to scan for a null termi
10 matches
Mail list logo