[Soot-list] Error in Shimple

Al aaloanmiftah at yahoo.com
Wed Jun 26 12:35:22 EDT 2013


Hey,

I'll have more time this coming few months so I might be able to reimplement ssa, since the new parser I worked on for jimple uses many of the same heuristics ssa is based on.

Al

On Jun 26, 2013, at 9:35 AM, Patrick Lam <plam at sable.mcgill.ca> wrote:

> Navindra Umanee. I think he's working at Microsoft these days, but I'm 
> not sure. Er, he's my Facebook friend...
> 
> pat
> 
> On 06/26/13 08:36, Marc-André Laverdière-Papineau wrote:
>> Hi Ishan,
>> 
>> Thanks for investigating the bugs. With your help, we may be able to get
>> a solid SSA implementation :)
>> 
>> Eric,
>> 
>> Do you know who has worked on the Shimple component in the past? Maybe
>> we could get their help again?
>> 
>> Marc-André Laverdière-Papineau
>> Doctorant - PhD Candidate
>> 
>> On 24/06/13 08:10 AM, Ishan Khot wrote:
>>> Hello Soot List,
>>> I tried to convert the following java code to extended shimple(SSI) and
>>> the program goes into an infinite loop.
>>> 
>>> public class ShimpleTest {
>>> 
>>> /**
>>> * @param args
>>> */
>>> public static void main(String[] args) {
>>> // TODO Auto-generated method stub
>>> 
>>>    int x = 100;
>>>    boolean doIt = true;
>>> 
>>>    if(doIt){
>>>        if(x<  200){
>>>            x = 100;
>>>        }
>>> 
>>>        else{
>>>            x = 200;
>>>        }
>>>    }
>>> 
>>>    System.out.println(x);
>>> }
>>> 
>>> }
>>> 
>>> The options I used to run soot are :
>>> -cp . -pp -process-dir bin -d SootOutput -f shimple -p shimple extended:true
>>> 
>>> I also did a little debugging on soot and found that the following piece
>>> of code is responsible for causing the infinite loop in the class
>>> ShimpleBodyBuilder
>>> 
>>>  public void transform()
>>>     {
>>>         phi.insertTrivialPhiNodes();
>>> 
>>>         boolean change = false;
>>>         if(options.extended()){
>>>             change = pi.insertTrivialPiNodes();
>>> 
>>>             while(change){
>>>                 if(phi.insertTrivialPhiNodes()){
>>>                     change = pi.insertTrivialPiNodes();
>>>                 }
>>>                 else{
>>>                     break;
>>>                 }
>>>             }
>>>         }
>>>     .....
>>> 
>>> The above while loop goes infinite with change = true and the
>>> phi.insertTrivialPhiNodes() method keeps on inserting the same phi node
>>> statement infinite times into a particular cfg block.
>>> It would be great if someone could help me in removing this bug.
>>> 
>>> Thanks
>>> 
>>> 
>>> 
>>> _______________________________________________
>>> Soot-list mailing list
>>> Soot-list at sable.mcgill.ca
>>> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list
>> _______________________________________________
>> Soot-list mailing list
>> Soot-list at sable.mcgill.ca
>> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list
> 
> _______________________________________________
> Soot-list mailing list
> Soot-list at sable.mcgill.ca
> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list


More information about the Soot-list mailing list