************************************************************************ * Busy Wait Analyser - BWA - http://bwa.sourceforge.net/ * * * * (C) 2005 Raul Fechete, Georg Kienesberger, Peter Minarik. * ************************************************************************ BWA is a static analysis tool for Java programs that targets the detection of "Busy Wait". It takes ordinary class files as input, uses the Soot Framework (http://www.sable.mcgill.ca/) to extract control flow information, and then runs the analysis proposed by "Johann Blieberger, Bernd Burgstaller, Bernhard Scholz, Busy Wait Analysis, Ada-Europe'2003, Toulouse, France, 2003". So it basically is a command line tool which outputs class name, method name, the source line number of the busy wait loop and the busy wait variable (In order to output line number and variable name, it is required that debug information was generated during compilation.). Basic Usage =========== java bwa.Main [-s] [-l LEVEL] \ [[-v|-vv] [-o FILE] | -e FILE [-t VAL]] [-i FILE] \ [-r|-j| --method METHOD CLASS | CLASS1 CLASS2 ...] CLASS The only thing you really need to provide is the name of the class(es) you want to analyse. Your $CLASSPATH has to be set correctly, and in case you want to specify more than one class you cannot use -r, -j or --method. --method Followed by the name of a method and a single class, only this method is analysed. If the methodname within this class is not unique this option cannot be used. -r Starting from the given class, analyse all reachable methods in the callgraph. So if the main class of a program is given, the whole program should be considered during the analysis. See the usage notes below. -j Basically the same as -r, but packages starting with java.*, sun.*, org.apache.*, org.xml.* are also included in the callgraph. See the usage notes below. -l 0 Only the variables with the highest BW probability are being shown. As candidates, only the variables directly used in a termination statement are taken into consideration. This level also corresponds to a "lite scan" - a heuristic process to skip the counter-like nodes. e.g.: In the for(i=1;i