Re: [go-nuts] Efficient bitmask twiddling

2020-09-02 Thread Aleksey Tulinov
https://godbolt.org/z/6n7G8q I'm actually not sure how good this assembly is, it would be interesting to hear from you, but it looks promising. вт, 1 сент. 2020 г. в 22:54, Oliver Smith : > > In the process of developing a piece of middleware, I need to translate from > a bit-array into a

[go-nuts] Efficient bitmask twiddling

2020-09-01 Thread Oliver Smith
In the process of developing a piece of middleware, I need to translate from a bit-array into a bitmask. I am struggling to find a way to express this in go that doesn't result in terrible performance. The approaches I would try in most other languages were along the lines of: ``` mask =