From f781318ac32a76d35c97b85975bfe783b75d3752 Mon Sep 17 00:00:00 2001 From: zhangyi Date: Fri, 13 Dec 2024 23:29:18 +0800 Subject: [PATCH] Add "--ttl" option to asprof --- profiler.sh | 392 ------------------------ src/arguments.cpp | 2 +- src/arguments.h | 2 +- src/fdtransfer.h | 2 - src/launcher/fdtransferServer_linux.cpp | 65 +--- src/launcher/main.cpp | 4 + src/profiler.cpp | 3 +- src/vmEntry.cpp | 9 - 8 files changed, 14 insertions(+), 465 deletions(-) delete mode 100755 profiler.sh diff --git a/profiler.sh b/profiler.sh deleted file mode 100755 index 290b45ebc..000000000 --- a/profiler.sh +++ /dev/null @@ -1,392 +0,0 @@ -#!/bin/sh -set -eu - -usage() { - echo "Usage: $0 [action] [options] " - echo "Actions:" - echo " start start profiling and return immediately" - echo " resume resume profiling without resetting collected data" - echo " stop stop profiling" - echo " dump dump collected data without stopping profiling session" - echo " check check if the specified profiling event is available" - echo " status print profiling status" - echo " meminfo print profiler memory stats" - echo " list list profiling events supported by the target JVM" - echo " collect collect profile for the specified period of time" - echo " and then stop (default action)" - echo "Options:" - echo " -e event profiling event: cpu|alloc|lock|cache-misses etc." - echo " -d duration run profiling for seconds" - echo " -f filename dump output to " - echo " -i interval sampling interval in nanoseconds" - echo " -j jstackdepth maximum Java stack depth" - echo " -t profile different threads separately" - echo " -s simple class names instead of FQN" - echo " -g print method signatures" - echo " -a annotate Java methods" - echo " -l prepend library names" - echo " -o fmt output format: flat|traces|collapsed|flamegraph|tree|jfr" - echo " -I include output only stack traces containing the specified pattern" - echo " -X exclude exclude stack traces with the specified pattern" - echo " -v, --version display version string" - echo "" - echo " --title string FlameGraph title" - echo " --minwidth pct skip frames smaller than pct%" - echo " --reverse generate stack-reversed FlameGraph / Call tree" - echo "" - echo " --loop time run profiler in a loop" - echo " --ttl time automatically shutdown profiler at