[Soot-list] Why create temp$xx variables?

Eric Bodden eric.bodden at mail.mcgill.ca
Wed Apr 22 14:45:36 EDT 2009


I am glad that it works for you. However, I agree with Patrick that
usually this should be working by default:
http://www.sable.mcgill.ca/soot/tutorial/phase/phase.html#SECTION00027000000000000000
Enabled (enabled)
(default value: true)

Eric

2009/4/22 Peng Du <imdupeng at gmail.com>:
> It works now. Thanks, Pat. I guess the reason why it did not work
> previously was that the conversion was from Java to Jimple/Shimple but I
> forgot to turn on [Constant Propagator] in [Java to Jimple Body
> Creation], which was not enabled by default.
>
> SOOT is a very elegantly put together framework to work with. Thank you
> all.
>
> Peng
>
>
>
> On Wed, 2009-04-22 at 13:48 -0400, Patrick Lam wrote:
>> Peng Du wrote:
>> > Thanks, Hamid
>> >
>> > I think your solution will work. Just curious about those temp$
>> > variables. There got be some more elegant way to eliminate those. I
>> > tried lots of command line options, as well Eclipse plugin, all of them
>> > generated temp$.
>> >
>> >  I will try your idea as a last resort.
>>
>> -src-prec jimple doesn't generate temp$ variables because they've been
>> optimized away by the copy and constant propagators when Soot created
>> the Jimple in the first place.
>>
>> The more elegant way to eliminate them is what Soot normally does, the
>> copy and constant propagators. It's an artifact of the way that Soot
>> creates three-address code from stack-based code. You don't quite seem
>> to understand this, but I suggest that you figure out what's going on
>> before proceeding.
>>
>> pat
>
> _______________________________________________
> Soot-list mailing list
> Soot-list at sable.mcgill.ca
> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list
>



-- 
Eric Bodden
Sable Research Group, McGill University
Montréal, Québec, Canada


More information about the Soot-list mailing list