]> rtime.felk.cvut.cz Git - can-benchmark.git/commitdiff
Test also influence of netdev_budget
authorMichal Sojka <sojkam1@fel.cvut.cz>
Mon, 31 Aug 2009 17:53:47 +0000 (19:53 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Mon, 31 Aug 2009 17:53:47 +0000 (19:53 +0200)
tests/_lib.sh
tests/ethflood64k-w2.sh
tests/ethflood64k.sh
tests/ethload.sh

index 1474741a6c7289aee9dcd555698ab89af752aaea..6100f7edd05500562a36e4dc261795ade8704540 100644 (file)
@@ -79,10 +79,12 @@ prepare_socketcan_virtual() {
 run_tests() {
     tests=${TESTS:-socketcan_hw lincan_hw}
     for tst in $tests; do
 run_tests() {
     tests=${TESTS:-socketcan_hw lincan_hw}
     for tst in $tests; do
+       echo 300 > /proc/sys/net/core/netdev_budget
        boost_irq_prio 50 || true
        prepare_$tst
        echo "----------------------"
        t
        boost_irq_prio 50 || true
        prepare_$tst
        echo "----------------------"
        t
+       echo 300 > /proc/sys/net/core/netdev_budget
     done
 }
 
     done
 }
 
index 0cb2db67bc1ae6e2f03646fc883cf935e03d1f1a..ad7173d4189d646ab0a40a8274c174b4f4f7458e 100755 (executable)
@@ -4,16 +4,21 @@
 
 t() {
     for i in norm boost; do
 
 t() {
     for i in norm boost; do
-       ssh root@${SSH_CONNECTION%% *} 'ping -fs 64000 ${SSH_CONNECTION%% *}' &
-       PID_PING=$!
-       echo 0 1 > $DRIVER-$i-1000.dat
-       if [ $i != "boost" ] || boost_irq_prio 90; then
-           PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
-           vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i -t 1 -d $CAN0 -w 2 -c $COUNT
-           kill $PID_S
-       fi
-       kill $PID_PING
-       sleep 1 # Wait for remote buffers to become empty
+       for budget in 300 1 1000; do
+           echo $budget > /proc/sys/net/core/netdev_budget
+           ssh root@${SSH_CONNECTION%% *} 'ping -fs 64000 ${SSH_CONNECTION%% *}' &
+           PID_PING=$!
+           echo 0 1 > $DRIVER-$i-$budget-1000.dat
+           if [ $budget -eq 300 -o $DRIVER == "socketcan" ]; then
+               if [ $i != "boost" ] || boost_irq_prio 90; then
+                   PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
+                   vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i-$budget -t 1 -d $CAN0 -w 2 -c $COUNT
+                   kill $PID_S
+               fi
+           fi
+           kill $PID_PING
+           sleep 1 # Wait for remote buffers to become empty
+       done
     done
 }
 
     done
 }
 
@@ -25,9 +30,14 @@ set logscale y
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
-plot [0:] "socketcan-norm-1000.dat" with lp lt 1 title "Socketcan",\
-          "lincan-norm-1000.dat" with lp lt 2 title "Lincan",\
-          "socketcan-boost-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
-          "lincan-boost-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio"
+plot [0:] \
+          "socketcan-norm-300-1000.dat" with lp lt 1 title "Socketcan",\
+          "lincan-norm-300-1000.dat" with lp lt 2 title "Lincan",\
+          "socketcan-boost-300-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
+          "lincan-boost-300-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio",\
+          "socketcan-norm-1-1000.dat" with lp lt 1 title "Socketcan netdev\\\\_budget=1",\
+          "socketcan-boost-1-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1",\
+          "socketcan-norm-1000-1000.dat" with lp lt 1 title "Socketcan, netdev\\\\_budget=1000",\
+          "socketcan-boost-1000-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1000"
 EOF
 }
 EOF
 }
index dcf1fe9d7759fac1aa1ae749046390fb431ea724..e6af1634e21a4480064ab1fde217b518a79a9d1a 100755 (executable)
@@ -4,16 +4,21 @@
 
 t() {
     for i in norm boost; do
 
 t() {
     for i in norm boost; do
-       ssh root@${SSH_CONNECTION%% *} 'ping -fs 64000 ${SSH_CONNECTION%% *}' &
-       PID_PING=$!
-       echo 0 1 > $DRIVER-$i-1000.dat
-       if [ $i != "boost" ] || boost_irq_prio 90; then
-           PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
-           vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i -t 1 -d $CAN0 -w 0 -c $COUNT
-           kill $PID_S
-       fi
-       kill $PID_PING
-       sleep 1 # Wait for remote buffers to become empty
+       for budget in 300 1 1000; do
+           echo $budget > /proc/sys/net/core/netdev_budget
+           ssh root@${SSH_CONNECTION%% *} 'ping -fs 64000 ${SSH_CONNECTION%% *}' &
+           PID_PING=$!
+           echo 0 1 > $DRIVER-$i-$budget-1000.dat
+           if [ $budget -eq 300 -o $DRIVER == "socketcan" ]; then
+               if [ $i != "boost" ] || boost_irq_prio 90; then
+                   PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
+                   vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i-$budget -t 1 -d $CAN0 -w 0 -c $COUNT
+                   kill $PID_S
+               fi
+           fi
+           kill $PID_PING
+           sleep 1 # Wait for remote buffers to become empty
+       done
     done
 }
 
     done
 }
 
@@ -25,9 +30,14 @@ set logscale y
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
-plot [0:] "socketcan-norm-1000.dat" with lp lt 1 title "Socketcan",\
-          "lincan-norm-1000.dat" with lp lt 2 title "Lincan",\
-          "socketcan-boost-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
-          "lincan-boost-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio"
+plot [0:] \
+          "socketcan-norm-300-1000.dat" with lp lt 1 title "Socketcan",\
+          "lincan-norm-300-1000.dat" with lp lt 2 title "Lincan",\
+          "socketcan-boost-300-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
+          "lincan-boost-300-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio",\
+          "socketcan-norm-1-1000.dat" with lp lt 1 title "Socketcan netdev\\\\_budget=1",\
+          "socketcan-boost-1-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1",\
+          "socketcan-norm-1000-1000.dat" with lp lt 1 title "Socketcan, netdev\\\\_budget=1000",\
+          "socketcan-boost-1000-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1000"
 EOF
 }
 EOF
 }
index 6f36ba3bcae80b70774e5b59dbd4fe535dc251c5..61e7ce829e9b88515c39c3100dc42436dfd2ff83 100755 (executable)
@@ -4,16 +4,21 @@
 
 t() {
     for i in norm boost; do
 
 t() {
     for i in norm boost; do
-       ssh root@${SSH_CONNECTION%% *} 'find -L /usr/src/linux -type f -exec cat "{}" ";"' > /dev/null &
-       PID_LOAD=$!
-       echo 0 1 > $DRIVER-$i-1000.dat
-       if [ $i != "boost" ] || boost_irq_prio 90; then
-           PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
-           vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i -t 1 -d $CAN0 -w 0 -c $COUNT
-           kill $PID_S
-       fi
-       kill $PID_LOAD
-       sleep 1 # Wait for remote buffers to become empty
+       for budget in 300 1 1000; do
+           echo $budget > /proc/sys/net/core/netdev_budget
+           ssh root@${SSH_CONNECTION%% *} 'find -L /usr/src/linux -type f -exec cat "{}" ";"' > /dev/null &
+           PID_LOAD=$!
+           echo 0 1 > $DRIVER-$i-$budget-1000.dat
+           if [ $budget -eq 300 -o $DRIVER == "socketcan" ]; then
+               if [ $i != "boost" ] || boost_irq_prio 90; then
+                   PID_S=`vca_canping -s 1 -b -R FF:$RTPRIO -d $CAN1`
+                   vca_canping -m 1 -R FF:$RTPRIO -v -g $DRIVER-$i-$budget -t 1 -d $CAN0 -w 0 -c $COUNT
+                   kill $PID_S
+               fi
+           fi
+           kill $PID_LOAD
+           sleep 1 # Wait for remote buffers to become empty
+       done
     done
 }
 
     done
 }
 
@@ -25,9 +30,14 @@ set logscale y
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
 set grid
 set xlabel "Time [ms]"
 set ylabel "Latency profile [messages]"
-plot [0:] "socketcan-norm-1000.dat" with lp lt 1 title "Socketcan",\
-          "lincan-norm-1000.dat" with lp lt 2 title "Lincan",\
-          "socketcan-boost-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
-          "lincan-boost-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio"
+plot [0:] \
+          "socketcan-norm-300-1000.dat" with lp lt 1 title "Socketcan",\
+          "lincan-norm-300-1000.dat" with lp lt 2 title "Lincan",\
+          "socketcan-boost-300-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio",\
+          "lincan-boost-300-1000.dat" with lp lt 2 title "Lincan boosted IRQ prio",\
+          "socketcan-norm-1-1000.dat" with lp lt 1 title "Socketcan netdev\\\\_budget=1",\
+          "socketcan-boost-1-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1",\
+          "socketcan-norm-1000-1000.dat" with lp lt 1 title "Socketcan, netdev\\\\_budget=1000",\
+          "socketcan-boost-1000-1000.dat" with lp lt 1 title "Socketcan boosted IRQ prio, netdev\\\\_budget=1000"
 EOF
 }
 EOF
 }