Hi All,
I am developing a client to dump dynamic instruction traces of specific functions.
Everything works fine but I don't know how to detect ASIMD instructions and their precisions. Here is an example:
Consider scalar double-precision floating-point multiplication:
double c, a, b;
c = a * b;
The assembly is this:
FMUL Dd, Dn, Dm
What Dynamorio gives me is this (which is correct):
FMUL Dd, Dn, Dm
Now consider ASIMD 2 single-precision floating-point multiplication:
float32x2_t c, a, b;
c = vmul_f32(a, b)
The assembly is this:
FMUL Vd.2S,Vn.2S,Vm.2S
What Dynamorio gives me is this (which is the scalar floating-point representation):
FMUL Dd, Dn, Dm
Which could be the output for 4 half-precision floating-point too:
FMUL Vd.4H,Vn.4H,Vm.4H
In other words, I couldn't find a way to detect the precision of a register. Here are the APIs I've used:
To decode the opcode:
const char *decode_opcode_name(int opcode);
To decode the registers:
const char *get_register_name(reg_id_t reg);
Is there any way to detect the precision of an ASIMD operation?
Best,
- Alireza