Make the quadrant shift K a bool in do_sincos_* functions