# Programming Language Benchmark 2

**URL:** <https://discourse.julialang.org/t/programming-language-benchmark-2/108429>\
**Category:** Performance\
**Created:** [January 6, 2024, 10:01am UTC](https://discourse.julialang.org/t/programming-language-benchmark-2/108429 "2024-01-06T10:01:40Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![Benny](https://avatars.discourse-cdn.com/v4/letter/b/49beb7/32.png) [@Benny](https://discourse.julialang.org/u/Benny)\
**Post date:** [January 6, 2024, 12:11pm UTC](https://discourse.julialang.org/t/programming-language-benchmark-2/108429/8 "2024-01-06T12:11:58Z")

</div>

Had a hunch this might’ve been a thread already. So the benchmark can be optimized with additional masking right off the bat?

> [@How to shift bits faster](https://discourse.julialang.org/t/how-to-shift-bits-faster/19405):
>
> I thought I’d share something that I’ve run into before, and that I’ve seen a couple of times now on this forum (most recently in [this topic](https://discourse.julialang.org/t/help-me-improve-my-poker-hand-evaluator/19360)). If you want to shift the integer n to the left or right by k bits, the natural way to do it is simply n \<\< k or n \>\> k. However, this is not the most efficient way, since Julia’s shift operator differs from the native shift operator. On 64-bit CPUs, the shift count is masked with 63, so trying to shift to the left with 65 bits results in shifting to the …

---

_[View the full topic](https://discourse.julialang.org/t/programming-language-benchmark-2/108429)._
