Skip to content

Commit 54653c6

Browse files
author
Jennifer Lhoták
committed
- made nop eliminator run before jb phase for java to jimple
1 parent 5ea9d86 commit 54653c6

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

TODO

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Todo (as of 2.0.1)
22

33
VERY HIGH - fix problem that xml attribute tags are only generated if output == jimple (they should work if other output formats are selected also) - fixed
44

5-
VERY HIGH - fix the mechanism used to generate attributes in the source viewers in Eclipse - fixed - needs more work
5+
VERY HIGH - fix the mechanism used to generate attributes in the source viewers in Eclipse - fixed - needs more work - fixed
66

77
HIGH - finish coloring for stmts - fixed
88

@@ -12,9 +12,10 @@ HIGH - implement getting the actual Soot Output dir from Soot so the plugin can
1212

1313
HIGH - minimize amount of XML being generated - done
1414

15-
HIGH - write documentation and howto's
15+
HIGH - write documentation and howto's - done
1616

1717
HIGH - implement running on all source files in project from project menu (currently can only run for all class files - unless process-dir is changed manually)
18+
- done
1819

1920
HIGH - implement being able to run Soot on a package of java files (not classes) and being able to do more then just decompile when a package/folder is selected
2021

src/soot/javaToJimple/AnonClassInitMethodSource.java

+1
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ public soot.Body getBody(soot.SootMethod sootMethod, String phaseName){
4646
// return
4747
soot.jimple.ReturnVoidStmt retStmt = soot.jimple.Jimple.v().newReturnVoidStmt();
4848
body.getUnits().add(retStmt);
49+
PackManager.v().getTransform("jb.ne").apply(body);
4950

5051
PackManager.v().getPack("jb").apply(body);
5152

src/soot/javaToJimple/PolyglotMethodSource.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ public PolyglotMethodSource(polyglot.ast.Block block, List formals){
3030
public soot.Body getBody(soot.SootMethod sm, String phaseName) {
3131
JimpleBodyBuilder jbb = new JimpleBodyBuilder();
3232
soot.jimple.JimpleBody jb = jbb.createJimpleBody(block, formals, sm);
33-
33+
34+
PackManager.v().getTransform("jb.ne").apply(jb);
3435
PackManager.v().getPack("jb").apply(jb);
3536
return jb;
3637
}

0 commit comments

Comments
 (0)