From: Pavel V. <va...@us...> - 2002-03-04 00:14:11
|
Update of /cvsroot/javaprofiler/test/snapshot In directory usw-pr-cvs1:/tmp/cvs-serv10945 Modified Files: TestSnap.java PrintSnap.java Log Message: configuration class added Index: TestSnap.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/TestSnap.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** TestSnap.java 26 Jan 2002 19:37:37 -0000 1.2 --- TestSnap.java 4 Mar 2002 00:14:09 -0000 1.3 *************** *** 42,45 **** --- 42,46 ---- import net.sourceforge.javaprofiler.jpi.*; + public class TestSnap { *************** *** 52,77 **** public void getSnapShot( ) { ! //conf ! boolean withCPU = true; ! boolean withAlloc = true; ! boolean withMon = true; ! boolean withArenas = true; ! boolean withGC = true; ! boolean withTraces = true; ! boolean withThreads = true; //only traces with more hits than this will be extracted ! int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more allocations than this will be extracted ! int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more hits than this will be extracted ! int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; long start = System.currentTimeMillis(); ! Snapshot mirror = new SnapshotImpl( iprof, withCPU, withAlloc, ! withMon, withArenas, withGC, withTraces, withThreads, ! CPUTraces_MinVal, ! AllocTraces_MinVal, ! MonTraces_MinVal); System.out.println( mirror.time() ); --- 53,76 ---- public void getSnapShot( ) { ! ! SnapshotImpl.Configuration conf = new SnapshotImpl.Configuration(); ! ! conf.withCPU = true; ! conf.withAlloc = true; ! conf.withMon = true; ! conf.withArenas = true; ! conf.withGC = true; ! conf.withTraces = true; ! conf.withThreads = true; //only traces with more hits than this will be extracted ! conf.CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more allocations than this will be extracted ! conf.AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more hits than this will be extracted ! conf.MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; long start = System.currentTimeMillis(); ! Snapshot mirror = new SnapshotImpl( iprof, conf ); System.out.println( mirror.time() ); Index: PrintSnap.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/PrintSnap.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** PrintSnap.java 3 Mar 2002 00:26:30 -0000 1.3 --- PrintSnap.java 4 Mar 2002 00:14:09 -0000 1.4 *************** *** 54,75 **** public void printSnapShot( ) { //conf ! boolean withCPU = true; ! boolean withAlloc = true; ! boolean withMon = true; ! boolean withTraces = true; ! boolean withThreads = true; ! boolean withArenas = true; ! boolean withGC = true; ! int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; DebugOutput dbgPrn = new DebugOutput(); ! SnapshotImpl mirror = new SnapshotImpl( iprof, withCPU, withAlloc, ! withMon, withTraces, withThreads, withArenas, withGC, ! CPUTraces_MinVal, ! AllocTraces_MinVal, ! MonTraces_MinVal); dbgPrn.print( mirror ); --- 54,76 ---- public void printSnapShot( ) { //conf ! SnapshotImpl.Configuration conf = new SnapshotImpl.Configuration(); ! ! conf.withCPU = true; ! conf.withAlloc = true; ! conf.withMon = true; ! conf.withArenas = true; ! conf.withGC = true; ! conf.withTraces = true; ! conf.withThreads = true; ! //only traces with more hits than this will be extracted ! conf.CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more allocations than this will be extracted ! conf.AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more hits than this will be extracted ! conf.MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; DebugOutput dbgPrn = new DebugOutput(); ! SnapshotImpl mirror = new SnapshotImpl( iprof, conf ); dbgPrn.print( mirror ); |