IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 14, 2008, 1:42:49 PM (19 years ago)
Author:
eugene
Message:

adding new tests from mark pitts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi/cmd.data/test/periodogram.sh

    r14176 r16056  
    44 test2
    55 test3
     6 memtest1
    67end
    78
     
    100101 end
    101102end
     103
     104# Memory test
     105macro memtest1
     106
     107 local i
     108 local P PI
     109 $PI = 3.14159265359
     110 $P  = 15.0
     111
     112 create x 500 800
     113 set t = 300 * rnd(x) + 500
     114 set f = sin(2*$PI*t/$P)
     115
     116 list word -x "ps -p $PID -o rss"
     117 $startmem = $word:1
     118
     119 for i 0 1000
     120  periodogram t f 2 30 period power
     121 end
     122 
     123 list word -x "ps -p $PID -o rss"
     124 $endmem = $word:1
     125
     126 $PASS = 1
     127
     128 if ($endmem - $startmem > 10)
     129   $PASS = 0
     130   echo "growth: {$endmem-$startmem}"
     131   echo "kB/loop: {($endmem-$startmem)/1000}"
     132 end
     133end
Note: See TracChangeset for help on using the changeset viewer.