#include int16_t int16_topbit_mask(int16_t x) { x >>= 15; return -(1 & x); }