Date: | Tue, 13 Dec 2022 11:50:13 -0600 |
---|---|
From: | Barton Miller <bart@xxxxxxxxxxx> |
Subject: | Re: [DynInst_API:] Problem in pointer alias analysis by using Dyninst |
Hi Wen,
As Tim points out, statically, determining that these two instructions point to the location is a challenge in general. As Tim said, you might be able to use the DataflowAPI to slice backwards on each register to see if you can determine its value. However, that can't work in the most general case.
Dynamically, you can insert instrumentation into these
instructions to calculate the effective address. Dyninst makes
this easy with the BPatch_effectiveAddressExpr method (Section 3.3
in the Dyninst Programmer's Guide). That would allow you to gather
the information at runtime and compare them.
--bart
On 12/13/2022 11:43 AM, Tim Haines
wrote:
The general problem with pointer aliasing is that there are many different sources of memory and each presents its own challenge- particularly heap memory. This isn't my area of expertise, but I believe using dataflow analysis would be a place to start. DataflowAPI won't have a single method to solve pointer aliasing because it's too complex of a problem, but the information it provides should get you started. Feel free to ask more questions here or open a question issue on our Github. |
[← Prev in Thread] | Current Thread | [Next in Thread→] |
---|---|---|
|
Previous by Date: | Re: [DynInst_API:] Problem in pointer alias analysis by using Dyninst, Tim Haines |
---|---|
Next by Date: | [DynInst_API:] [dyninst/dyninst] c6b364: Libiberty cmake modernization (#1334), Tim Haines |
Previous by Thread: | Re: [DynInst_API:] Problem in pointer alias analysis by using Dyninst, Tim Haines |
Next by Thread: | Re: [DynInst_API:] Problem in pointer alias analysis by using Dyninst, Wen Zhang |
Indexes: | [Date] [Thread] |