[Soot-list] Retrieving branch information
Patrick Lam
plam at sable.mcgill.ca
Wed Jun 10 13:59:45 EDT 2009
Kristen Walcott wrote:
> Hi,
>
> I am able to extract the condition from a branch, but now I'm trying to
> break the condition down so that I can plug it in as a condition in a
> constraint solver. Is there some easy way that I'm missing?
> For example, if you have the condition $i0 < 10, I can extract the $i0
> and 10 using the use boxes, but is there a way to get the "<" as well?
The Value that you get from the IfStmt.getCondition() would be an
instanceof LtExpr. Or you could toString() the Expr; that might be
suitable for your constraint solver. By the way, do you want simple
three-address code expressions like in Jimple, or aggregated expressions
(x + y < 10) as in Grimp?
pat
More information about the Soot-list
mailing list