[Soot-list] Jimple TypeResolver bug
Heejong Lee
heejong at gmail.com
Thu Jun 2 04:57:09 EDT 2011
Hi,
I've got a bug of jimple transformation like following:
BufferedReader in = new BufferedReader(new InputStreamReader(new
FileInputStream(queueFile)));
>>>>>
181 tmp = new java.io.BufferedReader;
182 tmp = new java.io.InputStreamReader;
183 tmp = new java.io.FileInputStream;
184 specialinvoke tmp.<java.io.FileInputStream: void
<init>(java.io.File)>(queueFile);
185 specialinvoke tmp.<java.io.InputStreamReader: void
<init>(java.io.InputStream)>(tmp);
186 specialinvoke tmp.<java.io.BufferedReader: void
<init>(java.io.Reader)>(tmp);
This IL is obviously incorrect. When I replace
soot.jimple.toolkits.typing.fast.TypeResolver.split_new()
with an empty method, the correct output is generated:
181 $r2 = new java.io.BufferedReader;
182 $r0 = new java.io.InputStreamReader;
183 $r1 = new java.io.FileInputStream;
184 specialinvoke $r1.<java.io.FileInputStream: void
<init>(java.io.File)>(queueFile);
185 specialinvoke $r0.<java.io.InputStreamReader: void
<init>(java.io.InputStream)>($r1);
186 specialinvoke $r2.<java.io.BufferedReader: void
<init>(java.io.Reader)>($r0);
What's the purpose of split_new() ?
(my executing options are "-p jb use-original-names:true
-allow-phantom-refs -f jimple" and removing
use-original-names option also resolves the problem.)
Regards,
--
Heejong Lee
Associate Research Engineer
Program Analysis Division
Fasoo.com, Inc. (www.spa-arrow.com)
More information about the Soot-list
mailing list