Skip to content

Commit

Permalink
split the scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
alina-yur committed Aug 6, 2024
1 parent 2af5595 commit 0a32468
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
24 changes: 24 additions & 0 deletions bench-native-optimized.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
set -e

function print() {
printf "\033[1;35m$1\033[0m\n"
}

print "Starting the native app 🚀"

./target/demo-optimized -Xmx512m &
export PID=$!
psrecord $PID --plot "$(date +%s)-graalvm-native.png" --max-cpu 2200 --max-memory 900 --include-children &

sleep 2
print "Done waiting for startup..."

print "Executing warmup load"
hey -n=250000 -c=8 http://localhost:8080/hello

print "Executing benchmark load"
hey -n=250000 -c=8 http://localhost:8080/hello

print "Native run done!🎉"
kill $PID
sleep 1
2 changes: 1 addition & 1 deletion bench-native.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ function print() {

print "Starting the native app 🚀"

./target/demo-optimized -Xmx512m &
./target/demo -Xmx512m &
export PID=$!
psrecord $PID --plot "$(date +%s)-graalvm-native.png" --max-cpu 2200 --max-memory 900 --include-children &

Expand Down

0 comments on commit 0a32468

Please sign in to comment.