Is there a C function call (I'm using gcc) that will save an XMM register to a specified __m128 variable? I'd like to avoid direct assembly if possible.
The use case here is I'm writing an exception handler routine to print out information about signals received; in this case, I'm receiving a floating point invalid operation in a highly optimized program, so knowing exactly where the exception happens is difficult. And since a FPE invalid operation can be any one of a number of causes, I want to be able to print out hex values of all the SSE registers to help narrow down the cause. Hence, the need to copy XMM* to C variables, which can then be sent elsewhere for logging.
I'm thinking maybe _mm_storeu_ps() might be the intrinsic I need, but it's unclear to me how it's used (what is the syntax for specifying which XMM register?), and I can't find any examples.