-
Notifications
You must be signed in to change notification settings - Fork 342
Description
There is already a robust implementation of 128-bit integers available here: c128. This code can be ported to ISPC fairly easily.
Currently, I'm relying on this implementation, but it would be nice if ISPC could directly use the scalar native full 64-bit multiplier instead. At the moment, I'm forced to fall back on schoolbook multiplication, which performs no better than using the scalar native multiplier and likely increases energy consumption.
A similar issue exists for 128-bit division with a 64-bit result. native scalar instructions can handle this efficiently which ispc could utilize as well.
ISPC could optimize these operations to outperform scalar implementation where the platform allows or use scalar implementation to reduce energy consumption if there is no performance benefit.
note: c128 implementation above supports operations with 128bit operands as well. basically like __uint128_t/__int128