anoopj opened a new pull request, #3159:
URL: https://github.com/apache/iceberg-rust/pull/3159

   ## What changes are included in this PR?
   
   RecordBatchPartitionSplitter::split groups a batch's rows by partition value 
into a HashMap. It iterated the partition Structs by reference and cloned each 
one into the entry key, allocating a fresh Struct (and, for string partitions, 
copying the string) for every row  even though partition_structs is never used 
after the loop.
   
   Consume partition_structs with into_iter() and move each Struct into the 
entry, dropping the per-row clone.
   
   Behavior is unchanged: grouping is by key equality, unaffected by whether 
the key is moved or cloned. On a 100k-row string-partitioned batch, split() 
drops from ~430 to ~396 ns/row (~8%); numeric partitions see a smaller win.
   
   
   ## Are these changes tested?
   
   Existing tests


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to