OpenCores
URL https://opencores.org/ocsvn/oms8051mini/oms8051mini/trunk

Subversion Repositories oms8051mini

[/] [oms8051mini/] [trunk/] [verif/] [run/] [run_irun] - Diff between revs 31 and 32

Only display areas with differences | Details | Blame | View Log

Rev 31 Rev 32
#!/bin/csh -f
#!/bin/csh -f
#
#
# test all programs w
# test all programs w
#
#
set COV   = "0"
set COV   = "0"
set failedm = 0;
set failedm = 0;
set failedi = 0;
set failedi = 0;
set failedx = 0;
set failedx = 0;
set all_testsm = 0;
set all_testsm = 0;
set all_testsi = 0;
set all_testsi = 0;
set all_testsx = 0;
set all_testsx = 0;
 
 
set misc_tests=(uart_test_1 spi_test_1 i2cm_test_1)
set misc_tests=(spi_test_1)
set risc_int_tests=(fib divmul sort gcd cast xram i2cm_burst_wrrd)
set risc_int_tests=(uart_lb fib divmul sort gcd cast xram i2cm_burst_wrrd)
 
 
echo " Compiling with cadence tools - irun "
echo " Compiling with cadence tools - irun "
if (${COV} == 0) then
if (${COV} == 0) then
     set VERILOG     = "irun -64bit -sv -elaborate +access+rcw +nospecify +define+SFLASH_SDPUP -V93 -define S75"
     set VERILOG     = "irun -64bit -sv -elaborate +access+rcw +nospecify +define+SFLASH_SDPUP -V93 -define S75"
     set ELAB        = "irun -64bit -R +access+rcw"
     set ELAB        = "irun -64bit -R +access+rcw"
     echo " Compiling with IES without coverage"
     echo " Compiling with IES without coverage"
 else
 else
     set VERILOG     = "irun  -64bit -sv -elaborate +access+rcw +define+SFLASH_SDPUP +nospecify -V93 -define S75 -covfile cov_options.ccf -covoverwrite"
     set VERILOG     = "irun  -64bit -sv -elaborate +access+rcw +define+SFLASH_SDPUP +nospecify -V93 -define S75 -covfile cov_options.ccf -covoverwrite"
     set ELAB        = "irun -64bit -R +access+rcw -covfile cov_options.ccf -covoverwrite"
     set ELAB        = "irun -64bit -R +access+rcw -covfile cov_options.ccf -covoverwrite"
     echo " Compiling with IES with coverage"
     echo " Compiling with IES with coverage"
 endif
 endif
$VERILOG -f filelist_top.f -l ../log/complie.log
$VERILOG -f filelist_top.f -l ../log/complie.log
if ($status != 0) then
if ($status != 0) then
  echo "#### Compile : FAILED"
  echo "#### Compile : FAILED"
  echo ""
  echo ""
  cat ../log/complie.log
  cat ../log/complie.log
  exit
  exit
else
else
  echo "#### Compile : PASSED"
  echo "#### Compile : PASSED"
endif
endif
echo ""
echo ""
echo "###########################################"
echo "###########################################"
echo " Runing test programs "
echo " Runing test programs "
echo "###########################################"
echo "###########################################"
set i = 0;
set i = 0;
        echo "###########################################"
        echo "###########################################"
foreach misc_test ($misc_tests)
foreach misc_test ($misc_tests)
        @ i += 1;
        @ i += 1;
        #echo ""
        #echo ""
        #echo "### Running test ${i}: ${misc_test}"
        #echo "### Running test ${i}: ${misc_test}"
        if (${misc_test} == "uart_test_1") then
        if (${misc_test} == "uart_test_1") then
           \cp ../testcase/dat/uart_lb.dat ./dat/oc8051_xrom.in
           \cp ../testcase/dat/uart_lb.dat ./dat/oc8051_xrom.in
        endif
        endif
        $ELAB +DUMP +${misc_test} +INTERNAL_ROM -l ../log/run.log
        $ELAB +DUMP +${misc_test} +INTERNAL_ROM -l ../log/run.log
        if ($status != 0) then
        if ($status != 0) then
          cat ../log/run.log
          cat ../log/run.log
          exit
          exit
        else if (`tail -100 ../log/run.log | grep PASSED` == "") then
        else if (`tail -100 ../log/run.log | grep PASSED` == "") then
          echo "### test ${i}: ${misc_test} --> FAILED"
          echo "### test ${i}: ${misc_test} --> FAILED"
          @ failedm += 1;
          @ failedm += 1;
          @ all_testsm += 1;
          @ all_testsm += 1;
        else
        else
          echo "### test ${i}: ${misc_test} --> PASSED"
          echo "### test ${i}: ${misc_test} --> PASSED"
          @ all_testsm += 1;
          @ all_testsm += 1;
        endif
        endif
        mv ../log/run.log ../log/${misc_test}.log
        mv ../log/run.log ../log/${misc_test}.log
end
end
    echo "###########################################"
    echo "###########################################"
echo ""
echo ""
echo ""
echo ""
echo "###########################################"
echo "###########################################"
echo "### tesing 8051 programs from internal rom"
echo "### tesing 8051 programs from internal rom"
echo "###########################################"
echo "###########################################"
set i = 0;
set i = 0;
        echo "###########################################"
        echo "###########################################"
foreach risc_int_test ($risc_int_tests)
foreach risc_int_test ($risc_int_tests)
        @ i += 1;
        @ i += 1;
        #echo ""
        #echo ""
        \cp ../testcase/dat/${risc_int_test}.dat ./dat/oc8051_xrom.in
        \cp ../testcase/dat/${risc_int_test}.dat ./dat/oc8051_xrom.in
        $ELAB +DUMP +INTERNAL_ROM -l ../log/run.log
        $ELAB +DUMP +${risc_int_test} +INTERNAL_ROM -l ../log/run.log
        if ($status != 0) then
        if ($status != 0) then
          cat ../log/run.log
          cat ../log/run.log
          exit
          exit
        else if (`tail ../log/run.log | grep PASSED` == "") then
        else if (`tail ../log/run.log | grep PASSED` == "") then
          echo "### test ${i}: ${risc_int_test} --> FAILED"
          echo "### test ${i}: ${risc_int_test} --> FAILED"
          @ failedi += 1;
          @ failedi += 1;
          @ all_testsi += 1;
          @ all_testsi += 1;
        else
        else
          echo "### test ${i}: ${risc_int_test} --> PASSED"
          echo "### test ${i}: ${risc_int_test} --> PASSED"
          @ all_testsi += 1;
          @ all_testsi += 1;
        endif
        endif
        mv ../log/run.log ../log/int_${risc_int_test}.log
        mv ../log/run.log ../log/int_${risc_int_test}.log
end
end
        echo "###########################################"
        echo "###########################################"
set i = 0;
set i = 0;
echo ""
echo ""
echo "###########################################"
echo "###########################################"
echo "###  Test Logs                            "
echo "###  Test Logs                            "
foreach misc_test ($misc_tests)
foreach misc_test ($misc_tests)
          @ i += 1;
          @ i += 1;
   if (`tail ../log/${misc_test}.log | grep PASSED` == "") then
   if (`tail ../log/${misc_test}.log | grep PASSED` == "") then
     echo "   test ${i}: ../log/${misc_test}.log --> FAILED"
     echo "   test ${i}: ../log/${misc_test}.log --> FAILED"
  else
  else
      echo "   test ${i}: ../log/${misc_test}.log --> PASSED"
      echo "   test ${i}: ../log/${misc_test}.log --> PASSED"
  endif
  endif
end
end
foreach risc_int_test ($risc_int_tests)
foreach risc_int_test ($risc_int_tests)
   @ i += 1;
   @ i += 1;
   if (`tail ../log/int_${risc_int_test}.log | grep PASSED` == "") then
   if (`tail ../log/int_${risc_int_test}.log | grep PASSED` == "") then
     echo "   test ${i}: ../log/int_${risc_int_test}.log --> FAILED"
     echo "   test ${i}: ../log/int_${risc_int_test}.log --> FAILED"
   else
   else
      echo "   test ${i}: ../log/int_${risc_int_test}.log --> PASSED"
      echo "   test ${i}: ../log/int_${risc_int_test}.log --> PASSED"
  endif
  endif
end
end
    echo "###########################################"
    echo "###########################################"
echo ""
echo ""
echo "###########################################"
echo "###########################################"
echo "###  Test Summary                          "
echo "###  Test Summary                          "
echo "### "
echo "### "
echo "### Failed $failedm of $all_testsm misc tests"
echo "### Failed $failedm of $all_testsm misc tests"
echo "### Failed $failedi of $all_testsi internal rom tests"
echo "### Failed $failedi of $all_testsi internal rom tests"
echo "###########################################"
echo "###########################################"
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.