Changeset 170e181 in mainline


Ignore:
Timestamp:
2014-04-21T11:57:39Z (10 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
787510d
Parents:
630b9d35
Message:

Allow compiler pruning for random builds

File:
1 edited

Legend:

Unmodified
Added
Removed
  • contrib/tools/random_check.sh

    r630b9d35 r170e181  
    3131LOOPS="$1"
    3232PARALLELISM="$2"
     33COMPILERS="$3"
    3334[ -z "$LOOPS" ] && LOOPS=1
    3435[ -z "$PARALLELISM" ] && PARALLELISM=1
     36# By default, skip icc and native GCC
     37[ -z "$COMPILERS" ] && COMPILERS="gcc_cross gcc_helenos clang"
    3538
    3639
     
    6972COUNTER=0
    7073FAILED=0
     74SKIPPED=0
    7175while [ $COUNTER -lt $LOOPS ]; do
    7276        COUNTER=$(( $COUNTER + 1 ))
    73         echo "Try #$COUNTER ($FAILED failures):" >&2
     77        echo "Try #$COUNTER (F$FAILED/S$SKIPPED):" >&2
    7478        (
    7579                run_clean
    7680                run_random_config
     81                CC=`sed -n 's#^COMPILER = \(.*\)#\1#p' <Makefile.config`
     82                if ! echo " $COMPILERS " | grep -q " $CC "; then
     83                        echo "  Skipping this one (compiler is $CC)." >&2
     84                        exit 2
     85                fi
    7786                run_make
    7887                exit $?
    7988        ) >random_run_$COUNTER.log
    80         if [ $? -ne 0 ]; then
     89        RC=$?
     90        if [ $RC -eq 2 ]; then
     91                SKIPPED=$(( $SKIPPED + 1 ))
     92        elif [ $RC -ne 0 ]; then
    8193                tail -n 10 random_run_$COUNTER.log | sed 's#.*#    | &#'
    82                 FAILED=$(( FAILED + 1 ))
     94                FAILED=$(( $FAILED + 1 ))
    8395        fi
    8496        cp Makefile.config random_run_$COUNTER.Makefile.config
     
    8698done
    8799
    88 echo "Out of $LOOPS tries, $FAILED configurations failed to compile." >&2
     100echo "Out of $LOOPS tries, $SKIPPED were skipped and $FAILED configurations failed to compile." >&2
Note: See TracChangeset for help on using the changeset viewer.