Changeset d326411 in rtems


Ignore:
Timestamp:
Jan 6, 2009, 10:52:12 PM (11 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, master
Children:
d041e59
Parents:
95ff1c3
Message:

2009-01-06 Joel Sherrill <joel.sherrill@…>

  • configure.ac: Make runtest an autoconf generated file so we can insert target alias. Also detect more program termination conditions so tests are killed more reliably.
  • runtest.in: New file.
  • runtest: Removed.
Location:
c/src/lib/libbsp/mips/jmr3904/tools
Files:
2 edited
1 moved

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/mips/jmr3904/tools/ChangeLog

    r95ff1c3 rd326411  
     12009-01-06      Joel Sherrill <joel.sherrill@OARcorp.com>
     2
     3        * configure.ac: Make runtest an autoconf generated file so we can
     4        insert target alias. Also detect more program termination conditions
     5        so tests are killed more reliably.
     6        * runtest.in: New file.
     7        * runtest: Removed.
     8
    192008-08-15      Joel Sherrill <joel.sherrill@OARcorp.com>
    210
  • c/src/lib/libbsp/mips/jmr3904/tools/configure.ac

    r95ff1c3 rd326411  
    55AC_PREREQ(2.60)
    66AC_INIT([rtems-c-src-lib-libbsp-mips-jmr3904-tools],[_RTEMS_VERSION],[http://www.rtems.org/bugzilla])
    7 AC_CONFIG_SRCDIR([runtest])
     7AC_CONFIG_SRCDIR([runtest.in])
    88RTEMS_TOP(../../../../../../..)
    99
     
    1515RTEMS_ENV_RTEMSBSP
    1616
     17RTEMS_PATH_KSH
     18
    1719RTEMS_PROJECT_ROOT
    1820RTEMS_TOOLPATHS
    1921
    2022# Explicitly list all Makefiles here
    21 AC_CONFIG_FILES([Makefile])
     23AC_CONFIG_FILES([Makefile
     24runtest])
    2225AC_OUTPUT
  • c/src/lib/libbsp/mips/jmr3904/tools/runtest.in

    r95ff1c3 rd326411  
    1 #!/bin/sh -p
     1#!@KSH@ -p
    22#
    33# Run rtems tests on the powerpc simulator
     
    8686max_run_time=$((5 * 60))
    8787using_print_buffer="yes"
    88 simulator=mipstx39-rtems4.9-run
     88txtarget=`echo @target_alias@ | sed -e 's/mips-/mipstx39-/'`
     89simulator=${txtarget}-run
    8990
    9091while getopts vdl:o:s: OPT
     
    156157            fi
    157158            ;;
    158        *-node2*)
    159            warn "Skipping $tname; 'runtest' runs both nodes when for *-node1"
    160            continue;;
    161        *-node1*)
    162            warn "Running both nodes associated with $tname"
    163            variant=`echo $tname | sed 's/.*-node[12]//' | sed 's/\.exe//'`
    164            tname=`echo $tname | sed 's/-node.*//'`
    165            TEST_TYPE="mp"
     159       *-node*)
     160           warn "Skipping $tname; MP tests not supported"
     161           continue
    166162           ;;
    167163       minimum*|stackchk*|*fatal*|termio*)
     
    170166   esac
    171167
    172    if [ $TEST_TYPE = "mp" ]
    173    then
    174        cpus="1 2"
    175 
    176        logfile1=$logdir/${tname}_1${variant}
    177        logfile2=$logdir/${tname}_2${variant}
    178        infofile1=$logfile1.info
    179        infofile2=$logfile2.info
    180 
    181        rm -f ${logfile1} ${logfile2}
    182 
    183        date=`date`
    184        echo "Starting $tname at $date"
    185 
    186        ${simulator} --board=jmr3904 ${tname}-node1${variant}.exe | \
    187          sed -e 's/
    188 //' -e '/^$/d' > ${logfile1} &
    189 
    190        ${simulator} --board=jmr3904 ${tname}-node2${variant}.exe | \
    191          sed -e 's/
    192 //' -e '/^$/d' > ${logfile2} &
    193 
    194        wait
    195 
    196    fi
    197 
    198168   if [ $TEST_TYPE = "single" ]
    199169   then
     
    210180     #
    211181     #       arrange for more memory (2 Mb)
    212 
    213182     if [ "$device_and_exit" = "yes" ]
    214183     then
     
    218187     # Spin off the simulator in the background
    219188
    220      ${simulator} --board=jmr3904 $tfile </dev/null | \
    221        sed -e 's/
    222 //' -e '/^$/d' > ${logfile} 2>&1 &
     189     ${simulator} --board=jmr3904 $tfile </dev/null > ${logfile} 2>&1 &
    223190     pid=$!
    224191
     
    245212         grep "^mips-core: " ${logfile} >/dev/null
    246213         badAccessExit=$?
    247          if [ $badAccessExit -eq 0 -o $exceptionExit -eq 0 ] ; then
     214         grep "^Warning, resuming with mismatched" ${logfile} >/dev/null
     215         simExceptExit=$?
     216         grep "^assertion" ${logfile} >/dev/null
     217         assertExit=$?
     218         if [ $badAccessExit -eq 0 -o $exceptionExit -eq 0 -o \
     219              $simExceptExit -eq 0 -o $assertExit -eq 0 ] ; then
    248220           kill -9 ${pid} >/dev/null 2>&1
    249221           #cat ${logfile}
     
    286258   if [ "$cpus" = "1" ]
    287259   then
    288         mv ${infofile} $logdir/${tname}.info
    289         mv ${logfile}  $logdir/${tname}
     260     sed -e 's/
     261//' -e '/^$/d' < ${infofile} >$logdir/${tname}.info
     262     sed -e 's/
     263//' -e '/^$/d' < ${logfile}  >$logdir/${tname}
    290264   fi
    291265
Note: See TracChangeset for help on using the changeset viewer.