cuda element-wise utilities