mirror of
https://github.com/luau-lang/luau.git
synced 2025-05-04 10:33:46 +01:00
Debug WIP: Updated cachegrind script
This commit is contained in:
parent
dc54c9547a
commit
72a5cd19df
1 changed files with 4 additions and 5 deletions
|
@ -22,7 +22,6 @@ now_ms() {
|
|||
}
|
||||
|
||||
# Run cachegrind on a given benchmark and echo the results.
|
||||
PYTHON_VERSION=$($1 --version | tr -d '\n')
|
||||
ITERATION_COUNT=$4
|
||||
START_TIME=$(now_ms)
|
||||
|
||||
|
@ -93,11 +92,11 @@ for i in "${!TOTALS_ARRAY[@]}"; do
|
|||
|
||||
if [[ $OPS_PER_SEC =~ ^[+-]?[0-9]*$ ]]
|
||||
then # $OPS_PER_SEC is integer
|
||||
printf "%s#%s x %.0f %s ±%s (%d runs sampled)(%s)\n" \
|
||||
"$3" "$EVENT_NAME" "$OPS_PER_SEC" "$UNIT" "$STD_DEV" "$RUNS" "$PYTHON_VERSION"
|
||||
printf "%s#%s x %.0f %s ±%s (%d runs sampled)\n" \
|
||||
"$3" "$EVENT_NAME" "$OPS_PER_SEC" "$UNIT" "$STD_DEV" "$RUNS"
|
||||
else # $OPS_PER_SEC is float
|
||||
printf "%s#%s x %.10f %s ±%s (%d runs sampled)(%s)\n" \
|
||||
"$3" "$EVENT_NAME" "$OPS_PER_SEC" "$UNIT" "$STD_DEV" "$RUNS" "$PYTHON_VERSION"
|
||||
printf "%s#%s x %.10f %s ±%s (%d runs sampled)\n" \
|
||||
"$3" "$EVENT_NAME" "$OPS_PER_SEC" "$UNIT" "$STD_DEV" "$RUNS"
|
||||
fi
|
||||
|
||||
done
|
||||
|
|
Loading…
Add table
Reference in a new issue