Re: [PATCH] fat: Refactor fat_tolower with branchless implementation

From: Al Viro
Date: Tue Mar 18 2025 - 00:03:40 EST


On Tue, Mar 18, 2025 at 11:43:09AM +0800, I Hsin Cheng wrote:
> Elimate the need of if-else branch within fat_tolower, replace it with a
> branchless bitwise operation. This can reduce the number of branch ~130
> regarding to the test script[1].

... and for values outside of 32..126 it would give wrong results.