PageRenderTime 108ms CodeModel.GetById 21ms RepoModel.GetById 2ms app.codeStats 1ms

/src/soot/options/soot_options.xml

https://github.com/Eeeeddddy/soot
XML | 6020 lines | 5836 code | 91 blank | 93 comment | 0 complexity | 9879a486b3a8764229590a7781599d2c MD5 | raw file

Large files files are truncated, but you can click here to view the full file

  1. <?xml-stylesheet type="text/xsl" href="soot_options.xsl" ?>
  2. <options>
  3. <intro>
  4. <p>
  5. The descriptions of Soot options talk about three categories of
  6. classes: argument classes, application classes, and library classes.</p>
  7. <p>
  8. <var>Argument classes</var> are those you specify explicitly to
  9. Soot. When you use Soot's command line interface, argument
  10. classes are those classes which are either listed explicitly on
  11. the command line or found in a directory specified with the
  12. <tt>-process-dir</tt> option. When you use the Soot's Eclipse
  13. plug-in, argument classes are those which you selected before
  14. starting Soot from the Navigator popup menu, or all classes in
  15. the current project if you started Soot from the Project
  16. menu.</p>
  17. <p>
  18. <var>Application classes</var> are classes that Soot analyzes,
  19. transforms, and turns into output files.</p>
  20. <p>
  21. <var>Library classes</var> are classes which are referred to,
  22. directly or indirectly, by the application classes, but which are
  23. not themselves application classes. Soot resolves these classes
  24. and reads <tt>.class</tt> or <tt>.jimple</tt> source files for
  25. them, but it does not perform transformations on library classes
  26. or write output files for them.</p>
  27. <p>
  28. All argument classes are necessarily application classes. When
  29. Soot <emph>is not</emph> in ``application mode'', argument
  30. classes are the only application classes; other classes
  31. referenced from the argument classes become library classes.</p>
  32. <p>
  33. When Soot <emph>is</emph> in application mode, every class
  34. referenced from the argument classes, directly or indirectly, is
  35. also an application class, unless its package name indicates that
  36. it is part of the standard Java runtime system.</p>
  37. <p>
  38. Users may fine-tune the designation of application and library
  39. classes using the Application Mode Options.
  40. </p>
  41. <p>
  42. Here is a simple example to clarify things. Suppose your program
  43. consists of three class files generated from the following
  44. source:
  45. <pre>
  46. // UI.java
  47. interface UI {
  48. public void display(String msg);
  49. }
  50. // HelloWorld.java
  51. class HelloWorld {
  52. public static void main(String[] arg) {
  53. UI ui = new TextUI();
  54. ui.display("Hello World");
  55. }
  56. }
  57. // TextUI.java
  58. import java.io.*;
  59. class TextUI implements UI {
  60. public void display(String msg) {
  61. System.out.println(msg);
  62. }
  63. }
  64. </pre></p>
  65. <p>
  66. If you run
  67. <pre>
  68. java soot.Main HelloWorld
  69. </pre>
  70. <tt>HelloWorld</tt> is the only argument class and the only
  71. application class. <tt>UI</tt> and <tt>TextUI</tt> are library
  72. classes, along with <tt>java.lang.System</tt>,
  73. <tt>java.lang.String</tt>, <tt>java.io.PrintStream</tt>, and a
  74. host of other classes from the Java runtime system that get
  75. dragged in indirectly by the references to <tt>String</tt> and
  76. <tt>System.out</tt>.</p>
  77. <p>
  78. If you run
  79. <pre>
  80. java soot.Main --app HelloWorld
  81. </pre>
  82. <tt>HelloWorld</tt> remains the
  83. only argument class, but the application classes include <tt>UI</tt>
  84. and <tt>TextUI</tt> as well as <tt>HelloWorld</tt>.
  85. <tt>java.lang.System</tt> et. al. remain library classes.
  86. </p>
  87. <p>
  88. If you run
  89. <pre>
  90. java soot.Main -i java. --app HelloWorld
  91. </pre>
  92. <tt>HelloWorld</tt> is still the only argument class, but the set
  93. of application classes includes the referenced Java runtime
  94. classes in packages whose names start with <tt>java.</tt> as well
  95. as <tt>HelloWorld</tt>, <tt>UI</tt>, and <tt>textUI</tt>. The set
  96. of library classes includes the referenced classes from other
  97. packages in the Java runtime.</p>
  98. </intro>
  99. <section>
  100. <name>General Options</name>
  101. <boolopt>
  102. <name>Help</name>
  103. <alias>h</alias>
  104. <alias>help</alias>
  105. <short_desc>Display help and exit</short_desc>
  106. <long_desc>
  107. Display the textual help message and exit immediately without
  108. further processing.
  109. </long_desc>
  110. </boolopt>
  111. <boolopt>
  112. <name>Phase List</name>
  113. <alias>pl</alias>
  114. <alias>phase-list</alias>
  115. <short_desc>Print list of available phases</short_desc>
  116. <long_desc>
  117. Print a list of the available phases and sub-phases, then exit.
  118. </long_desc>
  119. </boolopt>
  120. <listopt>
  121. <name>Phase Help</name>
  122. <alias>ph</alias>
  123. <alias>phase-help</alias>
  124. <set_arg_label>phase</set_arg_label>
  125. <short_desc>Print help for specified <use_arg_label/></short_desc>
  126. <long_desc>
  127. Print a help message about the phase or sub-phase named
  128. <use_arg_label/>, then exit. To see the help message of
  129. more than one phase, specify multiple phase-help options.
  130. </long_desc>
  131. </listopt>
  132. <boolopt>
  133. <name>Version</name>
  134. <alias>version</alias>
  135. <short_desc>Display version information and exit</short_desc>
  136. <long_desc>
  137. Display information about the version of Soot being run, then
  138. exit without further processing.
  139. </long_desc>
  140. </boolopt>
  141. <boolopt>
  142. <name>Verbose</name>
  143. <alias>v</alias>
  144. <alias>verbose</alias>
  145. <short_desc>Verbose mode</short_desc>
  146. <long_desc>
  147. Provide detailed information about what Soot is doing as it runs.
  148. </long_desc>
  149. </boolopt>
  150. <boolopt>
  151. <name>Interactive Mode</name>
  152. <alias>interactive-mode</alias>
  153. <short_desc>Run in interactive mode</short_desc>
  154. <long_desc>
  155. Runs interactively, with Soot providing detailed information as it iterates through intra-procedural analyses.
  156. </long_desc>
  157. </boolopt>
  158. <boolopt>
  159. <name>Unfriendly Mode</name>
  160. <alias>unfriendly-mode</alias>
  161. <short_desc>Allow Soot to run with no command-line options</short_desc>
  162. <long_desc>
  163. With this option, Soot does not stop even if it received no command-line options. Useful when setting Soot options programmatically and then calling soot.Main.main() with an empty list.
  164. </long_desc>
  165. </boolopt>
  166. <boolopt>
  167. <name>Application Mode</name>
  168. <alias>app</alias>
  169. <short_desc>Run in application mode</short_desc>
  170. <long_desc>
  171. <p>
  172. Run in application mode, processing all classes referenced by
  173. argument classes.</p>
  174. </long_desc>
  175. </boolopt>
  176. <boolopt>
  177. <name>Whole-Program Mode</name>
  178. <alias>w</alias>
  179. <alias>whole-program</alias>
  180. <short_desc>Run in whole-program mode</short_desc>
  181. <long_desc>
  182. <p>
  183. Run in whole program mode, taking into consideration the whole
  184. program when performing analyses and transformations. Soot
  185. uses the Call Graph Constructor to build a call graph for the
  186. program, then applies enabled transformations in the Whole-Jimple
  187. Transformation, Whole-Jimple Optimization, and Whole-Jimple
  188. Annotation packs before applying enabled intraprocedural
  189. transformations.</p>
  190. <p>
  191. Note that the Whole-Jimple Optimization pack is normally disabled
  192. (and thus not applied by whole program mode), unless you also
  193. specify the Whole Program Optimize option.</p>
  194. </long_desc>
  195. </boolopt>
  196. <boolopt>
  197. <name>Whole-Shimple Mode</name>
  198. <alias>ws</alias>
  199. <alias>whole-shimple</alias>
  200. <short_desc>Run in whole-shimple mode</short_desc>
  201. <long_desc>
  202. <p>
  203. Run in whole shimple mode, taking into consideration the whole program
  204. when performing Shimple analyses and transformations. Soot uses the
  205. Call Graph Constructor to build a call graph for the program, then
  206. applies enabled transformations in the Whole-Shimple Transformation
  207. and Whole-Shimple Optimization before applying enabled intraprocedural
  208. transformations.</p>
  209. <p>
  210. Note that the Whole-Shimple Optimization pack is normally disabled
  211. (and thus not applied by whole shimple mode), unless you also
  212. specify the Whole Program Optimize option.</p>
  213. </long_desc>
  214. </boolopt>
  215. <boolopt>
  216. <name>Validate</name>
  217. <alias>validate</alias>
  218. <short_desc>Run internal validation on bodies</short_desc>
  219. <long_desc>
  220. Causes internal checks to be done on bodies in the various Soot IRs,
  221. to make sure the transformations have not done something strange.
  222. This option may degrade Soot's performance.
  223. </long_desc>
  224. </boolopt>
  225. <boolopt>
  226. <name>Debug</name>
  227. <alias>debug</alias>
  228. <short_desc>Print various Soot debugging info</short_desc>
  229. <long_desc>
  230. Print various debugging information as Soot runs, particularly
  231. from the Baf Body Phase and the Jimple Annotation Pack Phase.
  232. </long_desc>
  233. </boolopt>
  234. <boolopt>
  235. <name>Debug Resolver</name>
  236. <alias>debug-resolver</alias>
  237. <short_desc>Print debugging info from SootResolver</short_desc>
  238. <long_desc>
  239. Print debugging information about class resolving.
  240. </long_desc>
  241. </boolopt>
  242. </section>
  243. <section>
  244. <name>Input Options</name>
  245. <stropt>
  246. <name>Soot Classpath</name>
  247. <alias>cp</alias>
  248. <alias>soot-class-path</alias>
  249. <alias>soot-classpath</alias>
  250. <set_arg_label>path</set_arg_label>
  251. <short_desc>Use <use_arg_label/> as the classpath for finding classes.</short_desc>
  252. <long_desc>
  253. <p>
  254. Use <use_arg_label/> as the list of directories in which Soot
  255. should search for classes. <use_arg_label/> should be a series of
  256. directories, separated by the path separator character for your
  257. system.</p>
  258. <p>
  259. If no classpath is set on the command line, but the system
  260. property <tt>soot.class.path</tt> has been set, Soot uses its
  261. value as the classpath.</p>
  262. <p>
  263. If neither the command line nor the system properties specify a
  264. Soot classpath, Soot falls back on a default classpath consisting
  265. of the value of the system property <tt>java.class.path</tt>
  266. followed <var>java.home</var><tt>/lib/rt.jar</tt>, where
  267. <var>java.home</var> stands for the contents of the system property
  268. <tt>java.home</tt> and <tt>/</tt> stands for the system file
  269. separator.</p>
  270. </long_desc>
  271. </stropt>
  272. <boolopt>
  273. <name>Prepend classpath</name>
  274. <alias>pp</alias>
  275. <alias>prepend-classpath</alias>
  276. <short_desc>Prepend the given soot classpath to the default classpath.</short_desc>
  277. <long_desc>
  278. <p>
  279. Instead of replacing the default soot classpath with the classpath given on the command line,
  280. prepent it with that classpath.
  281. The default classpath holds whatever is set in the CLASSPATH environment variable,
  282. followed by rt.jar (resolved through the JAVA-UNDERSCORE-HOME environment variable).
  283. If whole-program mode is enabled, jce.jar is also appended in the end.
  284. </p>
  285. </long_desc>
  286. </boolopt>
  287. <listopt>
  288. <name>Process Directories</name>
  289. <alias>process-path</alias>
  290. <alias>process-dir</alias>
  291. <set_arg_label>dir</set_arg_label>
  292. <short_desc>Process all classes found in <use_arg_label/></short_desc>
  293. <long_desc>
  294. <p>
  295. Add all classes found in <use_arg_label/> to the set of argument classes
  296. which is analyzed and transformed by Soot. You can specify the
  297. option more than once, to add argument classes from multiple directories.
  298. You can also state JAR files.
  299. </p>
  300. <p>
  301. If subdirectories of <use_arg_label/> contain <tt>.class</tt> or
  302. <tt>.jimple</tt> files, Soot assumes that the subdirectory names
  303. correspond to components of the classes' package names. If
  304. <use_arg_label/> contains <tt>subA/subB/MyClass.class</tt>, for
  305. instance, then Soot assumes <tt>MyClass</tt> is in package
  306. <tt>subA.subB</tt>.</p>
  307. </long_desc>
  308. </listopt>
  309. <boolopt>
  310. <name>One at a time</name>
  311. <alias>oaat</alias>
  312. <short_desc>From the process-dir, processes one class at a time.</short_desc>
  313. <long_desc>
  314. This option is meant to keep memory consumption low. If enabled, the
  315. -process-dir option must be used as well. From the process-dir, Soot
  316. will process one class at a time. Only body packs are run,
  317. no whole-program packs.
  318. </long_desc>
  319. </boolopt>
  320. <stropt>
  321. <name>Path to Android jar files</name>
  322. <alias>android-jars</alias>
  323. <set_arg_label>path</set_arg_label>
  324. <short_desc>Use <use_arg_label/> as the path for finding the android.jar file</short_desc>
  325. <long_desc>
  326. Use <use_arg_label/> as the directory in which Soot should search for the appropriate
  327. android.jar file to use.
  328. The directory must contain subdirectories named after the Android SDK version. Those
  329. subdirectories must each contain one android.jar file.
  330. For instance if the target directory is /home/user/androidSDK/platforms/ subdirectories
  331. containing android.jar for Android SDK 8 and 13 must be named android-8/ and android-13/
  332. respectively.
  333. Note, that this options requires that only one Android application is analyzed at a time.
  334. The Android application must contain the AndroidManifest.xml file.
  335. </long_desc>
  336. </stropt>
  337. <stropt>
  338. <name>Force specific Android jar file</name>
  339. <alias>force-android-jar</alias>
  340. <set_arg_label>path</set_arg_label>
  341. <short_desc>Force Soot to use <use_arg_label/> as the path for the android.jar file.</short_desc>
  342. <long_desc>
  343. Use <use_arg_label/> as the path to the android.jar file Soot should use.
  344. This option overrides the 'android-jars' option.
  345. </long_desc>
  346. </stropt>
  347. <boolopt>
  348. <name>Compute AST Metrics</name>
  349. <alias>ast-metrics</alias>
  350. <short_desc>Compute AST Metrics if performing java to jimple</short_desc>
  351. <long_desc>
  352. If this flag is set and soot converts java to jimple then AST metrics will be computed.
  353. </long_desc>
  354. </boolopt>
  355. <multiopt>
  356. <name>Input Source Precedence</name>
  357. <alias>src-prec</alias>
  358. <set_arg_label>format</set_arg_label>
  359. <short_desc>Sets source precedence to <use_arg_label/> files</short_desc>
  360. <long_desc>
  361. Sets <use_arg_label/> as Soot's preference for the type of source files to read when
  362. it looks for a class.
  363. </long_desc>
  364. <value>
  365. <name>Class File</name>
  366. <alias>c</alias>
  367. <alias>class</alias>
  368. <short_desc>Favour class files as Soot source</short_desc>
  369. <long_desc>
  370. Try to resolve classes first from <tt>.class</tt> files found in
  371. the Soot classpath. Fall back to <tt>.jimple</tt> files
  372. only when unable to find a <tt>.class</tt> file.
  373. </long_desc>
  374. <default/>
  375. </value>
  376. <value>
  377. <name>Only Class File</name>
  378. <alias>only-class</alias>
  379. <short_desc>Use only class files as Soot source</short_desc>
  380. <long_desc>
  381. Try to resolve classes first from <tt>.class</tt> files found in
  382. the Soot classpath. Do not try any other types of files even when
  383. unable to find a <tt>.class</tt> file.
  384. </long_desc>
  385. </value>
  386. <value>
  387. <name>Jimple File</name>
  388. <alias>J</alias>
  389. <alias>jimple</alias>
  390. <short_desc>Favour Jimple files as Soot source</short_desc>
  391. <long_desc>
  392. Try to resolve classes first from <tt>.jimple</tt> files found in
  393. the Soot classpath. Fall back to <tt>.class</tt> files only when
  394. unable to find a <tt>.jimple</tt> file.
  395. </long_desc>
  396. </value>
  397. <value>
  398. <name>Java File</name>
  399. <alias>java</alias>
  400. <short_desc>Favour Java files as Soot source</short_desc>
  401. <long_desc>
  402. Try to resolve classes first from <tt>.java</tt> files found in
  403. the Soot classpath. Fall back to <tt>.class</tt> files only when
  404. unable to find a <tt>.java</tt> file.
  405. </long_desc>
  406. </value>
  407. <value>
  408. <name>APK File</name>
  409. <alias>apk</alias>
  410. <short_desc>Favour APK files as Soot source</short_desc>
  411. <long_desc>
  412. Try to resolve classes first from <tt>.apk</tt> (Android Package) files found in
  413. the Soot classpath. Fall back to <tt>.class</tt>, <tt>.java</tt> or <tt>.jimple</tt>
  414. files only when unable to find a class in <tt>.apk</tt> files.
  415. </long_desc>
  416. </value>
  417. </multiopt>
  418. <boolopt>
  419. <name>Force complete resolver</name>
  420. <alias>full-resolver</alias>
  421. <short_desc>Force transitive resolving of referenced classes</short_desc>
  422. <long_desc>
  423. Normally, Soot resolves only that application classes and any classes that they
  424. refer to, along with any classes it needs for the Jimple typing, but it does not
  425. transitively resolve references in these additional classes that were resolved
  426. only because they were referenced. This switch forces full transitive resolution
  427. of all references found in all classes that are resolved, regardless of why they
  428. were resolved.
  429. In whole-program mode, class resolution is always fully transitive. Therefore,
  430. in whole-program mode, this switch has no effect, and class resolution is
  431. always performed as if it were turned on.
  432. </long_desc>
  433. </boolopt>
  434. <boolopt>
  435. <name>Allow Phantom References</name>
  436. <alias>allow-phantom-refs</alias>
  437. <short_desc>Allow unresolved classes; may cause errors</short_desc>
  438. <long_desc>
  439. Allow Soot to process a class even if it cannot find all classes
  440. referenced by that class. This may cause Soot to produce
  441. incorrect results.
  442. </long_desc>
  443. </boolopt>
  444. <boolopt>
  445. <name>Allow Phantom References</name>
  446. <alias>no-bodies-for-excluded</alias>
  447. <short_desc>Do not load bodies for excluded classes</short_desc>
  448. <long_desc>
  449. Prevents Soot from loading method bodies for all excluded classes (see exclude option), even
  450. when running in whole-program mode. This is useful for computing a shallow points-to analysis
  451. that does not, for instance, take into account the JDK. Of course, such analyses may be unsound.
  452. You get what you are asking for.
  453. </long_desc>
  454. </boolopt>
  455. <boolopt>
  456. <name>Use J2ME mode</name>
  457. <alias>j2me</alias>
  458. <default>false</default>
  459. <short_desc>Use J2ME mode; changes assignment of types</short_desc>
  460. <long_desc>
  461. Use J2ME mode. J2ME does not have class Cloneable nor Serializable, so we have
  462. to change type assignment to not refer to those classes.
  463. </long_desc>
  464. </boolopt>
  465. <stropt>
  466. <name>Main Class</name>
  467. <alias>main-class</alias>
  468. <set_arg_label>class</set_arg_label>
  469. <short_desc>Sets the main class for whole-program analysis.</short_desc>
  470. <long_desc>
  471. <p>
  472. By default, the first class encountered with a main method is treated
  473. as the main class (entry point) in whole-program analysis. This option
  474. overrides this default.
  475. </p>
  476. </long_desc>
  477. </stropt>
  478. <boolopt>
  479. <name>Use Polyglot frontend</name>
  480. <alias>polyglot</alias>
  481. <default>false</default>
  482. <short_desc>Use Java 1.4 Polyglot frontend instead of JastAdd</short_desc>
  483. <long_desc>
  484. Use Java 1.4 Polyglot frontend instead of JastAdd, which supports Java 5 syntax.
  485. </long_desc>
  486. </boolopt>
  487. </section>
  488. <section>
  489. <name>Output Options</name>
  490. <stropt>
  491. <name>Output Directory</name>
  492. <alias>d</alias>
  493. <alias>output-dir</alias>
  494. <default>./sootOutput</default>
  495. <set_arg_label>dir</set_arg_label>
  496. <short_desc>Store output files in <use_arg_label/></short_desc>
  497. <long_desc>
  498. Store output files in <use_arg_label/>. <use_arg_label/> may be
  499. relative to the working directory.
  500. </long_desc>
  501. </stropt>
  502. <multiopt>
  503. <name>Output Format</name>
  504. <alias>f</alias>
  505. <alias>output-format</alias>
  506. <set_arg_label>format</set_arg_label>
  507. <short_desc>Set output format for Soot</short_desc>
  508. <long_desc>
  509. <p>
  510. Specify the format of output files Soot should produce, if
  511. any.</p>
  512. <p>
  513. Note that while the abbreviated formats (<tt>jimp</tt>,
  514. <tt>shimp</tt>, <tt>b</tt>, and <tt>grimp</tt>) are easier to
  515. read than their unabbreviated counterparts (<tt>jimple</tt>,
  516. <tt>shimple</tt>, <tt>baf</tt>, and <tt>grimple</tt>), they may
  517. contain ambiguities. Method signatures in the abbreviated
  518. formats, for instance, are not uniquely determined.</p>
  519. </long_desc>
  520. <value>
  521. <name>Jimple File</name>
  522. <alias>J</alias>
  523. <alias>jimple</alias>
  524. <short_desc>Produce <tt>.jimple</tt> Files</short_desc>
  525. <long_desc>
  526. Produce <tt>.jimple</tt> files, which contain a textual
  527. form of Soot's Jimple internal representation.
  528. </long_desc>
  529. </value>
  530. <value>
  531. <name>Jimp File</name>
  532. <alias>j</alias>
  533. <alias>jimp</alias>
  534. <short_desc>Produce <tt>.jimp</tt> (abbreviated Jimple) files</short_desc>
  535. <long_desc>
  536. Produce <tt>.jimp</tt> files, which contain an abbreviated form
  537. of Jimple.
  538. </long_desc>
  539. </value>
  540. <value>
  541. <name>Shimple File</name>
  542. <alias>S</alias>
  543. <alias>shimple</alias>
  544. <short_desc>Produce <tt>.shimple</tt> files</short_desc>
  545. <long_desc>
  546. Produce <tt>.shimple files</tt>, containing a textual form of
  547. Soot's SSA Shimple internal representation. Shimple adds
  548. Phi nodes to Jimple.
  549. </long_desc>
  550. </value>
  551. <value>
  552. <name>Shimp File</name>
  553. <alias>s</alias>
  554. <alias>shimp</alias>
  555. <short_desc>Produce <tt>.shimp</tt> (abbreviated Shimple) files</short_desc>
  556. <long_desc>
  557. Produce .shimp files, which contain an abbreviated form of
  558. Shimple.
  559. </long_desc>
  560. </value>
  561. <value>
  562. <name>Baf File</name>
  563. <alias>B</alias>
  564. <alias>baf</alias>
  565. <short_desc>Produce <tt>.baf</tt> files</short_desc>
  566. <long_desc>
  567. Produce <tt>.baf</tt> files, which contain a textual form of
  568. Soot's Baf internal representation.
  569. </long_desc>
  570. </value>
  571. <value>
  572. <name>Abbreviated Baf File</name>
  573. <alias>b</alias>
  574. <short_desc>Produce <tt>.b</tt> (abbreviated Baf) files</short_desc>
  575. <long_desc>
  576. Produce <tt>.b</tt> files, which contain an abbreviated form of Baf.
  577. </long_desc>
  578. </value>
  579. <value>
  580. <name>Grimp File</name>
  581. <alias>G</alias>
  582. <alias>grimple</alias>
  583. <short_desc>Produce <tt>.grimple</tt> files</short_desc>
  584. <long_desc>
  585. Produce <tt>.grimple</tt> files, which contain a textual
  586. form of Soot's Grimp internal representation.
  587. </long_desc>
  588. </value>
  589. <value>
  590. <name>Abbreviated Grimp File</name>
  591. <alias>g</alias>
  592. <alias>grimp</alias>
  593. <short_desc>Produce <tt>.grimp</tt> (abbreviated Grimp) files</short_desc>
  594. <long_desc>
  595. Produce <tt>.grimp</tt> files, which contain an abbreviated form
  596. of Grimp.
  597. </long_desc>
  598. </value>
  599. <value>
  600. <name>Xml File</name>
  601. <alias>X</alias>
  602. <alias>xml</alias>
  603. <short_desc>Produce <tt>.xml</tt> Files</short_desc>
  604. <long_desc>
  605. Produce <tt>.xml</tt> files containing an annotated
  606. version of the Soot's Jimple internal representation.
  607. </long_desc>
  608. </value>
  609. <value>
  610. <name>Dalvik Executable File</name>
  611. <alias>dex</alias>
  612. <short_desc>Produce Dalvik Virtual Machine files</short_desc>
  613. <long_desc>Produce Dalvik Virtual Machine files. If input was an Android
  614. Package (APK), a new APK is generated with it's classes.dex replaced. If
  615. no input APK is found, only a classes.dex is generated.</long_desc>
  616. </value>
  617. <value>
  618. <name>No Output File</name>
  619. <alias>n</alias>
  620. <alias>none</alias>
  621. <short_desc>Produce no output</short_desc>
  622. <long_desc>
  623. Produce no output files.
  624. </long_desc>
  625. </value>
  626. <value>
  627. <name>Jasmin File</name>
  628. <alias>jasmin</alias>
  629. <short_desc>Produce <tt>.jasmin</tt> files</short_desc>
  630. <long_desc>
  631. Produce <tt>.jasmin</tt> files, suitable as input to the jasmin
  632. bytecode assembler.
  633. </long_desc>
  634. </value>
  635. <value>
  636. <name>Class File</name>
  637. <alias>c</alias>
  638. <alias>class</alias>
  639. <default/>
  640. <short_desc>Produce <tt>.class</tt> Files</short_desc>
  641. <long_desc>
  642. Produce Java <tt>.class</tt> files, executable by any Java
  643. Virtual Machine.
  644. </long_desc>
  645. </value>
  646. <value>
  647. <name>Dava Decompiled File</name>
  648. <alias>d</alias>
  649. <alias>dava</alias>
  650. <short_desc>Produce dava-decompiled <tt>.java</tt> files</short_desc>
  651. <long_desc>
  652. Produce <tt>.java</tt> files generated by the Dava decompiler.
  653. </long_desc>
  654. </value>
  655. <value>
  656. <name>Jimle Template File</name>
  657. <alias>t</alias>
  658. <alias>template</alias>
  659. <short_desc>Produce <tt>.java</tt> files with Jimple templates.</short_desc>
  660. <long_desc>
  661. Produce <tt>.java</tt> files with Jimple templates.
  662. </long_desc>
  663. </value>
  664. </multiopt>
  665. <boolopt>
  666. <name>Output Jar File</name>
  667. <alias>outjar</alias>
  668. <alias>output-jar</alias>
  669. <short_desc>Make output dir a Jar file instead of dir</short_desc>
  670. <long_desc>
  671. Saves output files into a Jar file instead of a directory. The output
  672. Jar file name should be specified using the Output Directory
  673. (<tt>output-dir</tt>) option. Note that if the output Jar file exists
  674. before Soot runs, any files inside it will first be removed.
  675. </long_desc>
  676. </boolopt>
  677. <boolopt>
  678. <name>Save Tags to XML</name>
  679. <alias>xml-attributes</alias>
  680. <short_desc>Save tags to XML attributes for Eclipse</short_desc>
  681. <long_desc>
  682. Save in XML format a variety of tags which Soot has attached to
  683. its internal representations of the application classes. The XML
  684. file can then be read by the Soot plug-in for the Eclipse IDE,
  685. which can display the annotations together with the program
  686. source, to aid program understanding.
  687. </long_desc>
  688. </boolopt>
  689. <boolopt>
  690. <name>Print Tags in Output</name>
  691. <alias>print-tags</alias>
  692. <alias>print-tags-in-output</alias>
  693. <short_desc>Print tags in output files after stmt</short_desc>
  694. <long_desc>
  695. Print in output files (either in Jimple or Dave) a variety of tags which
  696. Soot has attached to
  697. its internal representations of the application classes. The tags will
  698. be printed on the line succeeding the stmt that they are attached to.
  699. </long_desc>
  700. </boolopt>
  701. <boolopt>
  702. <name>Don't Output Source File Attribute</name>
  703. <alias>no-output-source-file-attribute</alias>
  704. <short_desc>Don't output Source File Attribute when producing class files</short_desc>
  705. <long_desc>
  706. Don't output Source File Attribute when producing class files.
  707. </long_desc>
  708. </boolopt>
  709. <boolopt>
  710. <name>Don't Output Inner Classes Attribute</name>
  711. <alias>no-output-inner-classes-attribute</alias>
  712. <short_desc>Don't output inner classes attribute in class files</short_desc>
  713. <long_desc>
  714. Don't output inner classes attribute in class files.
  715. </long_desc>
  716. </boolopt>
  717. <listopt>
  718. <name>Body Dumping Phases</name>
  719. <alias>dump-body</alias>
  720. <set_arg_label>phaseName</set_arg_label>
  721. <short_desc>Dump the internal representation of each method before and after phase <use_arg_label/></short_desc>
  722. <long_desc>
  723. <p>
  724. Specify that <use_arg_label/> is one of the phases to be dumped.
  725. For example <code>-dump-body jb -dump-body jb.a</code> would dump each
  726. method before and after the <code>jb</code> and <code>jb.a</code>
  727. phases. The pseudo phase name ``<code>ALL</code>''
  728. causes all phases to be dumped.</p>
  729. <p>
  730. Output files appear in subdirectories under the
  731. soot output directory, with names like
  732. <var>className</var><code>/</code><var>methodSignature</var><code>/</code><var>phasename</var><code>-</code><var>graphType</var><code>-</code><var>number</var><code>.in</code>
  733. and
  734. <var>className</var><code>/</code><var>methodSignature</var><code>/</code><var>phasename</var><code>-</code><var>graphType</var><code>-</code><var>number</var><code>.out</code>.
  735. The ``<code>in</code>'' and
  736. ``<code>out</code>'' suffixes distinguish the internal
  737. representations of the method before and after the phase
  738. executed.</p>
  739. </long_desc>
  740. </listopt>
  741. <listopt>
  742. <name>CFG Dumping Phases</name>
  743. <alias>dump-cfg</alias>
  744. <set_arg_label>phaseName</set_arg_label>
  745. <short_desc>Dump the internal representation of each CFG constructed during phase <use_arg_label/></short_desc>
  746. <long_desc>
  747. <p>
  748. Specify that any control flow graphs constructed during the
  749. <use_arg_label/> phases should be dumped.
  750. For example <code>-dump-cfg jb -dump-cfg bb.lso</code> would dump
  751. all
  752. CFGs constructed during the <code>jb</code> and <code>bb.lso</code>
  753. phases. The pseudo phase name ``<code>ALL</code>''
  754. causes CFGs constructed in all phases to be dumped.</p>
  755. <p>The control flow graphs are dumped in the form
  756. of a file containing input to <code>dot</code> graph visualization
  757. tool. Output <code>dot</code> files are stored beneath the soot
  758. output directory, in files with names like:
  759. <var>className</var><code>/</code><var>methodSignature</var><code>/</code><var>phasename</var><code>-</code><var>graphType</var><code>-</code><var>number</var><code>.dot</code>,
  760. where <var>number</var> serves to distinguish graphs in phases
  761. that produce more than one (for example, the Aggregator may
  762. produce multiple <code>ExceptionalUnitGraph</code>s).</p>
  763. </long_desc>
  764. </listopt>
  765. <boolopt>
  766. <name>Show Exception Destinations</name>
  767. <alias>show-exception-dests</alias>
  768. <default>true</default>
  769. <short_desc>Include exception destination edges as well as CFG edges in dumped CFGs</short_desc>
  770. <long_desc>
  771. Indicate whether to show exception destination edges as
  772. well as control flow edges in
  773. dumps of exceptional control flow graphs.
  774. </long_desc>
  775. </boolopt>
  776. <boolopt>
  777. <name>GZipped IR output</name>
  778. <alias>gzip</alias>
  779. <default>false</default>
  780. <short_desc>GZip IR output files</short_desc>
  781. <long_desc>
  782. This option causes Soot to compress output files of intermediate representations
  783. with GZip. It does not apply to class files output by Soot.
  784. </long_desc>
  785. </boolopt>
  786. </section>
  787. <section>
  788. <name>Processing Options</name>
  789. <phaseopt>
  790. <name>Phase Options</name>
  791. <alias>p</alias>
  792. <alias>phase-option</alias>
  793. <set_arg_label>phase opt:val</set_arg_label>
  794. <short_desc>Set <var>phase</var>&apos;s <var>opt</var> option to <var>value</var></short_desc>
  795. <long_desc>
  796. <p>
  797. Set <var>phase</var>'s run-time option named <var>opt</var> to
  798. <var>value</var>.</p>
  799. <p>
  800. This is a mechanism for specifying phase-specific options to
  801. different parts of Soot. See <var>Soot phase options</var> for
  802. details about the available phases and options.</p>
  803. </long_desc>
  804. <phase>
  805. <name>Jimple Body Creation</name>
  806. <alias>jb</alias>
  807. <class>JBOptions</class>
  808. <short_desc>Creates a <tt>JimpleBody</tt> for each method</short_desc>
  809. <long_desc>
  810. Jimple Body Creation creates a <tt>JimpleBody</tt> for each input
  811. method, using either coffi, to read <tt>.class</tt> files, or the
  812. jimple parser, to read <tt>.jimple</tt> files.
  813. </long_desc>
  814. <boolopt>
  815. <name>Enabled</name>
  816. <alias>enabled</alias>
  817. <default>true</default>
  818. <short_desc/>
  819. <long_desc/>
  820. </boolopt>
  821. <boolopt>
  822. <name>Use Original Names</name>
  823. <alias>use-original-names</alias>
  824. <default>false</default>
  825. <short_desc/>
  826. <long_desc>
  827. Retain the original names for local variables when the source
  828. includes those names. Otherwise, Soot gives variables generic
  829. names based on their types.
  830. </long_desc>
  831. </boolopt>
  832. <boolopt>
  833. <name>Preserve source-level annotations</name>
  834. <alias>preserve-source-annotations</alias>
  835. <default>false</default>
  836. <short_desc/>
  837. <long_desc>
  838. Preserves annotations of retention type SOURCE. (for
  839. everything but package and local variable annotations)
  840. </long_desc>
  841. </boolopt>
  842. <sub_phase>
  843. <name>Local Splitter</name>
  844. <alias>jb.ls</alias>
  845. <boolopt>
  846. <name>Enabled</name>
  847. <alias>enabled</alias>
  848. <default>true</default>
  849. </boolopt>
  850. <short_desc>Local splitter: one local per DU-UD web</short_desc>
  851. <long_desc>
  852. The Local Splitter identifies DU-UD webs for local variables and
  853. introduces new variables so that each disjoint web is associated
  854. with a single local.
  855. </long_desc>
  856. </sub_phase>
  857. <sub_phase>
  858. <name>Jimple Local Aggregator</name>
  859. <alias>jb.a</alias>
  860. <short_desc>Aggregator: removes some unnecessary copies</short_desc>
  861. <long_desc>
  862. <p>
  863. The Jimple Local Aggregator removes some unnecessary copies by
  864. combining local variables. Essentially, it finds definitions
  865. which have only a single use and, if it is safe to do so, removes
  866. the original definition after replacing the use with the
  867. definition's right-hand side.</p>
  868. <p>
  869. At this stage in <tt>JimpleBody</tt> construction, local
  870. aggregation serves largely to remove the copies to and from stack
  871. variables which simulate load and store instructions in the
  872. original bytecode.</p>
  873. </long_desc>
  874. <boolopt>
  875. <name>Enabled</name>
  876. <alias>enabled</alias>
  877. <default>true</default>
  878. </boolopt>
  879. <boolopt>
  880. <name>Only Stack Locals</name>
  881. <alias>only-stack-locals</alias>
  882. <long_desc>
  883. Only aggregate locals that represent stack locations in the
  884. original bytecode. (Stack locals can be distinguished in Jimple
  885. by the <dollar/> character with which their names begin.)
  886. </long_desc>
  887. <default>true</default>
  888. </boolopt>
  889. </sub_phase>
  890. <sub_phase>
  891. <name>Unused Local Eliminator</name>
  892. <alias>jb.ule</alias>
  893. <short_desc>Unused local eliminator</short_desc>
  894. <long_desc>
  895. The Unused Local Eliminator removes any unused locals from the
  896. method.
  897. </long_desc>
  898. <boolopt>
  899. <name>Enabled</name>
  900. <alias>enabled</alias>
  901. <default>true</default>
  902. </boolopt>
  903. </sub_phase>
  904. <sub_phase>
  905. <short_desc>Assigns types to locals</short_desc>
  906. <long_desc>
  907. The Type Assigner gives local variables types which will
  908. accommodate the values stored in them over the course of the
  909. method.
  910. </long_desc>
  911. <name>Type Assigner</name>
  912. <class>JBTROptions</class>
  913. <alias>jb.tr</alias>
  914. <boolopt>
  915. <name>Enabled</name>
  916. <alias>enabled</alias>
  917. <default>true</default>
  918. </boolopt>
  919. <boolopt>
  920. <name>Ignore wrong static-ness</name>
  921. <alias>ignore-wrong-staticness</alias>
  922. <default>false</default>
  923. <short_desc>Ignores errors due to wrong staticness</short_desc>
  924. <long_desc>
  925. Some projects have been shown to contain invalid bytecode that tries to access
  926. a static field or method in a non-static way or the other way around. The VM's bytecode
  927. verifier will reject such bytecode when loaded into the VM. This option, when enabled,
  928. causes to create Jimple bodies in such cases nontheless, ignoring the error.
  929. </long_desc>
  930. </boolopt>
  931. <boolopt>
  932. <name>Use older type assigner</name>
  933. <alias>use-older-type-assigner</alias>
  934. <default>false</default>
  935. <short_desc>Enables the older type assigner</short_desc>
  936. <long_desc>
  937. This enables the older type assigner that was in use until May 2008.
  938. The current type assigner is a reimplementation by Ben Bellamy
  939. that uses an entirely new and faster algorithm which always assigns
  940. the most narrow type possible. If compare-type-assigners is on,
  941. this option causes the older type assigner to execute first.
  942. (Otherwise the newer one is executed first.)
  943. </long_desc>
  944. </boolopt>
  945. <boolopt>
  946. <name>Compare type assigners</name>
  947. <alias>compare-type-assigners</alias>
  948. <default>false</default>
  949. <short_desc>Compares Ben Bellamy's and the older type assigner</short_desc>
  950. <long_desc>
  951. Enables comparison (both runtime and results) of Ben Bellamy's type assigner with the
  952. older type assigner that was in Soot.
  953. </long_desc>
  954. </boolopt>
  955. </sub_phase>
  956. <sub_phase>
  957. <name>Unsplit-originals Local Packer</name>
  958. <alias>jb.ulp</alias>
  959. <short_desc>Local packer: minimizes number of locals</short_desc>
  960. <long_desc>
  961. The Unsplit-originals Local Packer executes only when the
  962. `<tt>use-original-names</tt>&apos; option is chosen for the
  963. `<tt>jb</tt>&apos; phase. The Local Packer attempts to minimize
  964. the number of local variables required in a method by reusing the
  965. same variable for disjoint DU-UD webs. Conceptually, it is the
  966. inverse of the Local Splitter.
  967. </long_desc>
  968. <boolopt>
  969. <name>Enabled</name>
  970. <alias>enabled</alias>
  971. <default>true</default>
  972. <short_desc/>
  973. <long_desc/>
  974. </boolopt>
  975. <boolopt>
  976. <name>Unsplit Original Locals</name>
  977. <alias>unsplit-original-locals</alias>
  978. <default>true</default>
  979. <short_desc/>
  980. <long_desc>
  981. Use the variable names in the original source as a guide when
  982. determining how to share local variables among non-interfering
  983. variable usages. This recombines named locals which were split by
  984. the Local Splitter.
  985. </long_desc>
  986. </boolopt>
  987. </sub_phase>
  988. <sub_phase>
  989. <name>Local Name Standardizer</name>
  990. <alias>jb.lns</alias>
  991. <short_desc>Local name standardizer</short_desc>
  992. <long_desc>
  993. The Local Name Standardizer assigns generic names to local variables.
  994. </long_desc>
  995. <boolopt>
  996. <name>Enabled</name>
  997. <alias>enabled</alias>
  998. <default>true</default>
  999. <short_desc/>
  1000. <long_desc/>
  1001. </boolopt>
  1002. <boolopt>
  1003. <name>Only Stack Locals</name>
  1004. <alias>only-stack-locals</alias>
  1005. <default>false</default>
  1006. <short_desc/>
  1007. <long_desc>
  1008. Only standardizes the names of variables that represent stack
  1009. locations in the original bytecode. This becomes the default when
  1010. the `<tt>use-original-names</tt>&apos; option is specified for
  1011. the `<tt>jb</tt>&apos; phase.
  1012. </long_desc>
  1013. </boolopt>
  1014. </sub_phase>
  1015. <sub_phase>
  1016. <name>Copy Propagator</name>
  1017. <alias>jb.cp</alias>
  1018. <short_desc>Copy propagator</short_desc>
  1019. <long_desc>
  1020. This phase performs cascaded copy propagation.
  1021. If the propagator encounters situations of the form:
  1022. <pre>
  1023. A: a = ...;
  1024. ...
  1025. B: x = a;
  1026. ...
  1027. C: ... = ... x;
  1028. </pre>
  1029. where <tt>a</tt> and <tt>x</tt> are each defined only once (at
  1030. <tt>A</tt> and <tt>B</tt>, respectively), then it can propagate
  1031. immediately without checking between <tt>B</tt> and <tt>C</tt>
  1032. for redefinitions of <tt>a</tt>. In
  1033. this case the propagator is global.
  1034. Otherwise, if <tt>a</tt> has multiple definitions then the
  1035. propagator checks for redefinitions and propagates copies
  1036. only within extended basic blocks.
  1037. </long_desc>
  1038. <boolopt>
  1039. <name>Enabled</name>
  1040. <alias>enabled</alias>
  1041. <default>true</default>
  1042. <short_desc/>
  1043. <long_desc/>
  1044. </boolopt>
  1045. <boolopt>
  1046. <name>Only Regular Locals</name>
  1047. <alias>only-regular-locals</alias>
  1048. <default>false</default>
  1049. <short_desc/>
  1050. <long_desc>
  1051. Only propagate copies through ``regular&apos;&apos; locals, that is,
  1052. those declared in the source bytecode.
  1053. </long_desc>
  1054. </boolopt>
  1055. <boolopt>
  1056. <name>Only Stack Locals</name>
  1057. <alias>only-stack-locals</alias>
  1058. <default>true</default>
  1059. <short_desc/>
  1060. <long_desc>
  1061. Only propagate copies through locals that represent stack locations in
  1062. the original bytecode.
  1063. </long_desc>
  1064. </boolopt>
  1065. </sub_phase>
  1066. <sub_phase>
  1067. <name>Dead Assignment Eliminator</name>
  1068. <alias>jb.dae</alias>
  1069. <short_desc>Dead assignment eliminator</short_desc>
  1070. <long_desc>
  1071. The Dead Assignment Eliminator eliminates assignment statements
  1072. to locals whose values are not subsequently used, unless
  1073. evaluating the right-hand side of the assignment may cause
  1074. side-effects.
  1075. </long_desc>
  1076. <boolopt>
  1077. <name>Enabled</name>
  1078. <alias>enabled</alias>
  1079. <default>true</default>
  1080. <short_desc/>
  1081. <long_desc/>
  1082. </boolopt>
  1083. <boolopt>
  1084. <name>Only Stack Locals</name>
  1085. <alias>only-stack-locals</alias>
  1086. <default>true</default>
  1087. <short_desc/>
  1088. <long_desc>
  1089. Only eliminate dead assignments to locals that represent stack
  1090. locations in the original bytecode.
  1091. </long_desc>
  1092. </boolopt>
  1093. </sub_phase>
  1094. <sub_phase>
  1095. <name>Post-copy propagation Unused Local Eliminator</name>
  1096. <alias>jb.cp-ule</alias>
  1097. <short_desc>Post-copy propagation unused local eliminator</short_desc>
  1098. <long_desc>
  1099. This phase removes any locals that are unused after copy propagation.
  1100. </long_desc>
  1101. <boolopt>
  1102. <name>Enabled</name>
  1103. <alias>enabled</alias>
  1104. <default>true</default>
  1105. </boolopt>
  1106. </sub_phase>
  1107. <sub_phase>
  1108. <name>Local Packer</name>
  1109. <alias>jb.lp</alias>
  1110. <short_desc>Local packer: minimizes number of locals</short_desc>
  1111. <long_desc>
  1112. The Local Packer attempts to minimize the number of local
  1113. variables required in a method by reusing the same variable for
  1114. disjoint DU-UD webs. Conceptually, it is the inverse of the
  1115. Local Splitter.
  1116. </long_desc>
  1117. <boolopt>
  1118. <name>Enabled</name>
  1119. <alias>enabled</alias>
  1120. <default>false</default>
  1121. </boolopt>
  1122. <boolopt>
  1123. <name>Unsplit Original Locals</name>
  1124. <alias>unsplit-original-locals</alias>
  1125. <default>false</default>
  1126. <long_desc>
  1127. Use the variable names in the original source as a guide when
  1128. determining how to share local variables across non-interfering
  1129. variable usages. This recombines named locals which were split by
  1130. the Local Splitter.
  1131. </long_desc>
  1132. </boolopt>
  1133. </sub_phase>
  1134. <sub_phase>
  1135. <name>Nop Eliminator</name>
  1136. <alias>jb.ne</alias>
  1137. <short_desc>Nop eliminator</short_desc>
  1138. <long_desc>
  1139. The Nop Eliminator removes <tt>nop</tt> statements from the method.
  1140. </long_desc>
  1141. <boolopt>
  1142. <name>Enabled</name>
  1143. <alias>enabled</alias>
  1144. <default>true</default>
  1145. </boolopt>
  1146. </sub_phase>
  1147. <sub_phase>
  1148. <name>Unreachable Code Eliminator</name>
  1149. <alias>jb.uce</alias>
  1150. <short_desc>Unreachable code eliminator</short_desc>
  1151. <long_desc>
  1152. The Unreachable Code Eliminator removes unreachable code and
  1153. traps whose catch blocks are empty.
  1154. </long_desc>
  1155. <boolopt>
  1156. <name>Enabled</name>
  1157. <alias>enabled</alias>
  1158. <default>true</default>
  1159. </boolopt>
  1160. <boolopt>
  1161. <name>Remove unreachable traps</name>
  1162. <alias>remove-unreachable-traps</alias>
  1163. <default>false</default>
  1164. <long_desc>
  1165. Remove exception table entries when none of the protected instructions can
  1166. throw the exception being caught.
  1167. </long_desc>
  1168. </boolopt>
  1169. </sub_phase>
  1170. <sub_phase>
  1171. <name>Trap Tightener</name>
  1172. <alias>jb.tt</alias>
  1173. <short_desc>Trap Tightener</short_desc>
  1174. <long_desc>
  1175. The Trap Tightener changes the area protected by each exception handler,
  1176. so that it begins with the first instruction in the old protected
  1177. area which is actually capable of throwing an exception caught by the
  1178. handler, and ends just after the last instruction in the old
  1179. protected area which can throw an exception caught by the
  1180. handler. This reduces the chance of producing unverifiable code
  1181. as a byproduct of pruning exceptional control flow within CFGs.
  1182. </long_desc>
  1183. <boolopt>
  1184. <name>Enabled</name>
  1185. <alias>enabled</alias>
  1186. <default>false</default>
  1187. </boolopt>
  1188. </sub_phase>
  1189. </phase>
  1190. <phase>
  1191. <name>Java To Jimple Body Creation</name>
  1192. <alias>jj</alias>
  1193. <class>JJOptions</class>
  1194. <short_desc>Creates a <tt>JimpleBody</tt> for each method directly from source</short_desc>
  1195. <long_desc>
  1196. Jimple Body Creation creates a <tt>JimpleBody</tt> for each input
  1197. method, using polyglot, to read <tt>.java</tt> files.
  1198. </long_desc>
  1199. <boolopt>
  1200. <name>Enabled</name>
  1201. <alias>enabled</alias>
  1202. <default>true</default>
  1203. <short_desc/>
  1204. <long_desc/>
  1205. </boolopt>
  1206. <boolopt>
  1207. <name>Use Original Names</name>
  1208. <alias>use-original-names</alias>
  1209. <default>true</default>
  1210. <short_desc/>
  1211. <long_desc>
  1212. Retain the original names for local variables when the source
  1213. includes those names. Otherwise, Soot gives variables generic
  1214. names based on their types.
  1215. </long_desc>
  1216. </boolopt>
  1217. <sub_phase>
  1218. <name>Local Splitter</name>
  1219. <alias>jj.ls</alias>
  1220. <boolopt>
  1221. <name>Enabled</name>
  1222. <alias>enabled</alias>
  1223. <default>false</default>
  1224. </boolopt>
  1225. <short_desc>Local splitter: one local per DU-UD web</short_desc>
  1226. <long_desc>
  1227. The Local Splitter identifies DU-UD webs for local variables and
  1228. introduces new variables so that each disjoint web is associated
  1229. with a single local.
  1230. </long_desc>
  1231. </sub_phase>
  1232. <sub_phase>
  1233. <name>Jimple Local Aggregator</name>
  1234. <alias>jj.a</alias>
  1235. <short_desc>Aggregator: removes some unnecessary copies</short_desc>
  1236. <long_desc>
  1237. <p>
  1238. The Jimple Local Aggregator removes some unnecessary copies by
  1239. combining local variables. Essentially, it finds definitions
  1240. which have only a single use and, if it is safe to do so, removes
  1241. the original definition after replacing the use with the
  1242. definition's right-hand side.</p>
  1243. <p>
  1244. At this stage in <tt>JimpleBody</tt> construction, local
  1245. aggregation serves largely to remove the copies to and from stack
  1246. variables which simulate load and store instructions in the
  1247. original bytecode.</p>
  1248. </long_desc>
  1249. <boolopt>
  1250. <name>Enabled</name>
  1251. <alias>enabled</alias>
  1252. <default>true</default>
  1253. </boolopt>
  1254. <boolopt>
  1255. <name>Only Stack Locals</name>
  1256. <alias>only-stack-locals</alias>
  1257. <long_desc>
  1258. Only aggregate locals that represent stack locations in the
  1259. original bytecode. (Stack locals can be distinguished in Jimple
  1260. by the <dollar/> character with which their names begin.)
  1261. </long_desc>
  1262. <default>true</default>
  1263. </boolopt>
  1264. </sub_phase>
  1265. <sub_phase>
  1266. <name>Unused Local Eliminator</name>
  1267. <alias>jj.ule</alias>
  1268. <short_desc>Unused local eliminator</short_desc>
  1269. <long_desc>
  1270. The Unused Local Eliminator removes any unused locals from the
  1271. method.
  1272. </long_desc>
  1273. <boolopt>
  1274. <name>Enabled</name>
  1275. <alias>enabled</alias>
  1276. <default>true</default>
  1277. </boolopt>
  1278. </sub_phase>
  1279. <sub_phase>
  1280. <short_desc>Assigns types to locals</short_desc>
  1281. <long_desc>
  1282. The Type Assigner gives local variables types which will
  1283. accommodate the values stored in them over the course of the
  1284. method.
  1285. </long_desc>
  1286. <name>Type Assigner</name>
  1287. <alias>jj.tr</alias>
  1288. <boolopt>
  1289. <name>Enabled</name>
  1290. <alias>enabled</alias>
  1291. <default>false</default>
  1292. </boolopt>
  1293. </sub_phase>
  1294. <sub_phase>
  1295. <name>Unsplit-originals Local Packer</name>
  1296. <alias>jj.ulp</alias>
  1297. <short_desc>Local packer: minimizes number of locals</short_desc>
  1298. <long_desc>
  1299. The Unsplit-originals Local Packer executes only when the
  1300. `<tt>use-original-names</tt>&apos; option is chosen for the
  1301. `<tt>jb</tt>&apos; phase. The Local Packer attempts to minimize
  1302. the number of local variables required in a method by reusing the
  1303. same variable for disjoint DU-UD webs. Conceptually, it is the
  1304. inverse of the Local Splitter.
  1305. </long_desc>
  1306. <boolopt>
  1307. <name>Enabled</name>
  1308. <alias>enabled</alias>
  1309. <default>false</default>
  1310. <short_desc/>
  1311. <long_desc/>
  1312. </boolopt>
  1313. <boolopt>
  1314. <name>Unsplit Original Locals</name>
  1315. <alias>unsplit-original-locals</alias>
  1316. <default>false</default>
  1317. <short_desc/>
  1318. <long_desc>
  1319. Use the variable names in the original source as a guide when
  1320. determining how to share local variables among non-interfering
  1321. variable usages. This recombines named locals which were split by
  1322. the Local Splitter.
  1323. </long_desc>
  1324. </boolopt>
  1325. </sub_phase>
  1326. <sub_phase>
  1327. <name>Local Name Standardizer</name>
  1328. <alias>jj.lns</alias>
  1329. <short_desc>Local name standardizer</short_desc>
  1330. <long_desc>
  1331. The Local Name Standardizer assigns generic names to local variables.
  1332. </long_desc>
  1333. <boolopt>
  1334. <name>Enabled</name>
  1335. <alias>enabled</alias>
  1336. <default>true</default>
  1337. <short_desc/>
  1338. <long_desc/>
  1339. </boolopt>
  1340. <boolopt>
  1341. <name>Only Stack Locals</name>
  1342. <alias>only-stack-locals</alias>
  1343. <default>false</default>
  1344. <short_desc/>
  1345. <long_desc>
  1346. Only standardizes the names of variables that represent stack
  1347. locations in the original bytecode. This becomes the default when
  1348. the `<tt>use-original-names</tt>&apos; option is specified for
  1349. the `<tt>jb</tt>&apos; phase.
  1350. </long_desc>
  1351. </boolopt>
  1352. </sub_phase>
  1353. <sub_phase>
  1354. <name>Copy Propagator</name>
  1355. <alias>jj.cp</alias>
  1356. <short_desc>Copy propagator</short_desc>
  1357. <long_desc>
  1358. This phase performs cascaded copy propagation.
  1359. If the propagator encounters situations of the form:
  1360. <pre>
  1361. A: a = ...;
  1362. ...
  1363. B: x = a;
  1364. ...
  1365. C: ... = ... x;
  1366. </pre>
  1367. where <tt>a</tt> and <tt>x</tt> are each defined only once (at
  1368. <tt>A</tt> and <tt>B</tt>, respectively), then it can propagate
  1369. immediately without checking between <tt>B</tt> and <tt>C</tt>
  1370. for redefinitions of <tt>a</tt>. In
  1371. this case the propagator is global.
  1372. Otherwise, if <tt>a</tt> has multiple definitions then the
  1373. propagator checks for redefinitions and propagates copies
  1374. only within extended basic blocks.
  1375. </long_desc>
  1376. <boolopt>
  1377. <name>Enabled</name>
  1378. <alias>enabled</alias>
  1379. <default>true</default>
  1380. <short_desc/>
  1381. <long_desc/>
  1382. </boolopt>
  1383. <boolopt>
  1384. <name>Only Regular Locals</name>
  1385. <alias>only-regular-locals</alias>
  1386. <default>false</default>
  1387. <short_desc/>
  1388. <long_desc>
  1389. Only propagate copies through ``regular&apos;&apos; locals, that is,
  1390. those declared in the source bytecode.
  1391. </long_desc>
  1392. </boolopt>
  1393. <boolopt>
  1394. <name>Only Stack Locals</name>
  1395. <alias>only-stack-locals</alias>
  1396. <default>tru

Large files files are truncated, but you can click here to view the full file