Cast to int for case perf