Skip to content

Commit

Permalink
revert compilation_report changes and do not funnel benchmark codegen…
Browse files Browse the repository at this point in the history
… output into grep
  • Loading branch information
vezenovm committed Dec 13, 2024
1 parent d1807ed commit 1994283
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test_programs/compilation_report.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,17 @@ for dir in ${tests_to_profile[@]}; do

# The default package to run is the supplied list hardcoded at the top of the script
PACKAGE_NAME=$dir
# If a specific package name has been provided use that name
if [ "$#" -eq 2 ]; then
PACKAGE_NAME=$2
# Otherwise default to the current directory as the package we want to run
elif [ "$#" -ne 0 ]; then
if [ "$#" -ne 0 ]; then
PACKAGE_NAME=$(basename $current_dir)
fi

echo $PACKAGE_NAME

COMPILE_TIME=$((time nargo compile --force --silence-warnings --package $PACKAGE_NAME --benchmark-codegen) 2>&1 | grep real | grep -oE '[0-9]+m[0-9]+.[0-9]+s')
# Compile again just for benchmarking purposes
time nargo compile --force --silence-warnings --benchmark-codegen

COMPILE_TIME=$((time nargo compile --force --silence-warnings) 2>&1 | grep real | grep -oE '[0-9]+m[0-9]+.[0-9]+s')
echo -e " {\n \"artifact_name\":\"$PACKAGE_NAME\",\n \"time\":\"$COMPILE_TIME\"" >> $current_dir/compilation_report.json
if (($ITER == $NUM_ARTIFACTS)); then
Expand Down

0 comments on commit 1994283

Please sign in to comment.