From 306e8ff52bbe948be0ee585e01d47fb13628b031 Mon Sep 17 00:00:00 2001 From: Alex Myczko Date: Mon, 19 Sep 2022 21:25:49 +0200 Subject: [PATCH] Delete benchmark --- ext/benchmark | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100755 ext/benchmark diff --git a/ext/benchmark b/ext/benchmark deleted file mode 100755 index 5d3c198..0000000 --- a/ext/benchmark +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash - -# small CPU/MEM/DSK/NET benchmark for linux/macos -# alex@aiei.ch - -# check if called binaries are available -for a in date memtester bc dd sync printf; do - which $a >/dev/null - if [ ! $? -eq 0 ]; then - echo $a not found - exit 1 - fi -done - -d=date -which gdate >/dev/null && d=$(which gdate) - -# MEMORY 16 MB -echo -n "MEM " -which free >/dev/null && m=$(free -b |grep ^Mem: |awk '{printf "%.0f\n", $2/1024/1024/1024}') -which free >/dev/null || m=$(sysctl -n hw.memsize|awk '{printf "%.0f\n", $1/1024/1024/1024}') -start=$($d +%s.%N) -memtester 16M 1 &>/dev/null -end=$($d +%s.%N) -printf "%.2f %s GB " $(echo $end - $start | bc) $m - -# CPU, single core, (3000 digits of pi) -echo -n "CPU " -arch=$(uname -m) -cores=$(getconf _NPROCESSORS_ONLN) -start=$($d +%s.%N) -/bin/echo "scale=3000;4*a(1)" | bc -l &>/dev/null -end=$($d +%s.%N) -printf "%.2f %s\n" $(echo $end - $start | bc) $cores