On 2/5/18 7:47 PM, Adam D. Ruppe wrote:
On Tuesday, 6 February 2018 at 00:08:12 UTC, Steven Schveighoffer wrote:
I think the CPU has to do extra work to throw away that high bit, no?

No, the x86 has never had any trouble with this, and I don't think ARM does either (worst case you load it as int, then save it as byte).

But you are saving to an int, not a byte. Anyway, I don't really know the specifics of it. I'm not enough of an assembly buff to know the differences between what instructions are used or how much they cost.

-Steve

Reply via email to