bkietz commented on PR #40237: URL: https://github.com/apache/arrow/pull/40237#issuecomment-1967189304
> why is a ArraySpan or BufferSpan being initialized concurrently? The problem is we want FillFromScalar to act like copying a constant value into the ArraySpan. It would not be an error for multiple threads to copy a `const int` into a local `int`. However FillFromScalar mutates the constant scalar from which we're copying. One way to resolve this without sync would be setting up the offset scratch space when the scalar is constructed. IIRC we didn't do that in the first place because there are places where we assign to `BinaryScalar::value`, which would invalidate the offsets. Cleaning those up would be annoying but is more in line with Scalar behaving as an immutable value -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
