NightOwl888 commented on issue #1135:
URL: https://github.com/apache/lucenenet/issues/1135#issuecomment-2868996068

   I am unable to reproduce the error, but I may have found the root cause. In 
ICU4N, unsafe pointers were used to access the memory behind 
`ValueStringBuilder` and `ReorderingBuffer` (which uses `ValueStringBuilder` as 
a field). `ValueStringBuilder` uses an optional initial buffer on the stack, 
but if the buffer is used entirely, it allocates additional space on the heap 
through the array pool. Memory on the heap requires a fixed pointer to ensure 
the OS doesn't suddenly do something like move its location.
   
   
https://github.com/NightOwl888/ICU4N/blob/v60.1.0-alpha.436/src/ICU4N/Support/Text/ValueStringBuilder.cs#L110-L120
   
https://github.com/NightOwl888/ICU4N/blob/v60.1.0-alpha.436/src/ICU4N/Impl/Norm2AllModes.cs#L315-L318
   
   The fact that my computer has 64GB of RAM and a relatively light load could 
explain why I cannot reproduce the bug. A machine with less RAM and a heavier 
load is more likely to run into the issue.
   
   I am working on a patch for ICU4N now.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@lucenenet.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to