IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Dec 11, 2006, 10:15:41 PM (20 years ago)
Author:
eugene
Message:

moved global List into ListOps.c

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi/cmd.basic/test/for.sh

    r10311 r10647  
    88 memtest1
    99 memtest2
     10 memtest2a
    1011 memtest3
    1112end
     
    162163end
    163164
     165# check memleaks with many loop lines
     166macro memtest2a
     167
     168 local i N
     169
     170 list word -x "ps -p $PID -o rss"
     171 $startmem = $word:1
     172
     173 output /dev/null
     174 for i 0 10000
     175  echo "test line in loop"
     176  echo "test line in loop"
     177 end   
     178 output stdout
     179 
     180 list word -x "ps -p $PID -o rss"
     181 $endmem = $word:1
     182
     183 $PASS = 1
     184
     185 if ($endmem - $startmem > 10)
     186   $PASS = 0
     187   echo "growth: {$endmem-$startmem}"
     188   echo "kB/loop: {($endmem-$startmem)/10000}"
     189 end
     190end
     191
     192# check memleaks with many loop lines
     193macro memtest2b
     194
     195 local i N
     196
     197 list word -x "ps -p $PID -o rss"
     198 $startmem = $word:1
     199
     200 output /dev/null
     201 for i 0 1000
     202  exec echo "test line in loop" > /dev/null
     203  exec echo "test line in loop" > /dev/null
     204 end   
     205 output stdout
     206 
     207 list word -x "ps -p $PID -o rss"
     208 $endmem = $word:1
     209
     210 $PASS = 1
     211
     212 if ($endmem - $startmem > 10)
     213   $PASS = 0
     214   echo "growth: {$endmem-$startmem}"
     215   echo "kB/loop: {($endmem-$startmem)/1000}"
     216 end
     217end
     218
    164219# check memleaks on break
    165220macro memtest3
Note: See TracChangeset for help on using the changeset viewer.