[Soot-list] NaiveSideEffectTester
Phung Hua Nguyen
nhp at cse.unsw.edu.au
Mon Nov 8 01:35:05 EST 2004
Hi all,
I think NaiveSideEffectTester is a simple and cheap side effect tester but
it is so weak. I think we can improve the effect of the tester but still
keep it cheap by exploiting the final property of fields.
Particlarly, we can change:
if (s.containsInvokeExpr()) {
if (!(v instnaceof Local))
return true;
}
into
if (s.containsInvokeExpr()) {
if (!(v instanceof Local ||
((v instanceof FieldRef) && ((FieldRef)v).getField().isFinal()))
return true;
}
Am I correct ? I think it can improve significantly the effect of
NaiveSideEffectTester.
Nguyen Hua Phung
University of New South Wales
More information about the Soot-list
mailing list