
Commit 1db51d8eb2 switched from int64_t to `APInt` to prevent high precision integer overflow. However, when comparing the "range" of switch cases, we should switch to unsigned integer to prevent overflow. This patch fixes https://github.com/llvm/llvm-project/issues/93152. Some test cases are added. Signed-off-by: Peter Rong <PeterRong96@gmail.com>