diff options
author | Paul Phillips <paulp@improving.org> | 2011-01-04 01:17:32 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2011-01-04 01:17:32 +0000 |
commit | 234ee6d56bdbf4234f8f6f0f2ebc0560f25701ee (patch) | |
tree | 336171608f51da71ef600db63b27b265c871b373 /tools/profile_scala | |
parent | 266a2ca1c4ed1c655989c2435a9e83650b06f79a (diff) | |
download | scala-234ee6d56bdbf4234f8f6f0f2ebc0560f25701ee.tar.gz scala-234ee6d56bdbf4234f8f6f0f2ebc0560f25701ee.tar.bz2 scala-234ee6d56bdbf4234f8f6f0f2ebc0560f25701ee.zip |
Some profiler changes.
after each phase, so all the allocations are partitionable by phase
in the profiler. I also changed the name of -Yprofile-resident to
-Yprofile-memory and had it snapshot after the run instead of between
them, so it is usable for regular scalac usage as well.
Added tools/profile_scalac which can be used as a drop-in replacement
which handles some tedious setup. Review by dragos.
Diffstat (limited to 'tools/profile_scala')
-rwxr-xr-x | tools/profile_scala | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tools/profile_scala b/tools/profile_scala new file mode 100755 index 0000000000..037fc327bd --- /dev/null +++ b/tools/profile_scala @@ -0,0 +1,17 @@ +#!/bin/bash +# + +# Uses quick by default +CLASSPATH=`tools/quickcp` + +AGENT=${YOURKIT_PATH:-/Applications/YourKit.app/bin/mac/libyjpagent.jnilib} + +java $JAVA_OPTS \ + -classpath $CLASSPATH \ + -agentpath:$AGENT=$YNP_STARTUP_OPTIONS \ + scala.tools.nsc.MainGenericRunner -usejavacp \ + -i <(cat <<EOF +lazy val profiler = new scala.tools.util.YourkitProfiling { } +import profiler._ +EOF +) "$@" |