Github user michaelkamprath commented on the issue:

    https://github.com/apache/spark/pull/16403
  
    I've refactored this issue's solution using the idea that @kiszk supplied 
above. This ended up being a better idea, thanks. It produced cleaner code than 
my original allocated buffer approach. Also, based on the input that this 
solution should have zero impact on the x86 platform, I've refactored to a 
functor design pattern which creates the equivalent performance behavior for 
x86 as before this fix. 
    
    The performance impact of the using an intermediate long as a buffer when 
fetching a double from a memory block looks to be about 10%. I ran some 
performance tests writing and reading random doubles to random  aligned 
locations in a buffer 100M times over. On my mac laptop and an ARM unit, the 
performance difference was the long-buffered approach was about 10% slower than 
the original direct fetch approach. However, since the this refactor isolates 
the fetching behavior into a functor, the 10% slowdown only affects the ARM 
platform.
    
    I also added some unit tests if only to convince myself I hadn't broken 
anything. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to