Re: [DynInst_API:] Accessing Packed Floats


Date: Sat, 08 Oct 2016 17:53:25 +0100
From: Blair Archibald <mrblairarchibald@xxxxxxxxx>
Subject: Re: [DynInst_API:] Accessing Packed Floats
Hi John,

Sorry for the slow reply. Unfortunately I've lost the actual code I was using for this (switched to a new machine).

It was along the lines of using:

BPatch_registerExpr(Dyninst::MachRegister reg)

To access an XMM register and then trying various combinations of dereferecing (BPatch_deref) to try and access elements. I also tried not dereferencing to see what happened (nothing!). The idea was to then use this as an argument to a printf call.

What I found strange was that the newly generated code never had any mention of xmm0 in it at all.

I'll try and recreate the code soon. Before then, do you have any pointers of how I should be accessing elements. Is dereferencing into the BPatch_registerExpr the correct method?

Many thanks,
Blair

On 27 September 2016 at 17:23, John Detter <jdetter@xxxxxxxx> wrote:

Blair,

You should be able to do this using Dyninst. Could I see the code you're trying to use for this analysis?

-- John


On 09/27/2016 04:52 AM, Blair Archibald wrote:
Hi everyone,

I'm looking to do some analysis on (AVX) vectorised values stored in XMM/YMM. Is it possible to access the individual packed floats within these registers?

I've tried using BPatch_registerExpr to get the register I care about but I'm stuck trying to access the values. I thought something like *(regVal + 1) might work to get the second float but I've had no luck so far.

As an aside: I don't think YMM is configured correctly in the registerSpace and I had to manually add it to initialise64().

Any ideas if this is possible/how to do it?

Many thanks,
Blair


_______________________________________________
Dyninst-api mailing list
Dyninst-api@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/dyninst-api


[← Prev in Thread] Current Thread [Next in Thread→]