From: Mike Frysinger Date: Tue, 22 Mar 2016 19:31:00 +0000 (-0400) Subject: updates X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=dbff64cb4b7530861c2309c794efdd4e0cf47a23;p=ICEs.git updates --- diff --git a/doit b/doit index efbda89..33a5687 100755 --- a/doit +++ b/doit @@ -9,12 +9,13 @@ if ! ./reduce-ice ; then exit 1 fi +if false ; then echo "initial whitespace/preproc filter" cp ${FILE} ${FILE}.unfiltered sed -i \ + -e 's:[[:space:]]*::' \ -e '/^$/d' \ -e '/^#/d' \ - -e 's:[[:space:]]*::' \ ${FILE} if cmp -s ${FILE} ${FILE}.unfiltered ; then rm -f ${FILE}.unfiltered @@ -22,10 +23,18 @@ elif ! ./reduce-ice ; then echo "ERROR: filtered version breaks things !?" exit 1 fi +fi +dir=$(mktemp -d -t reduce-ice.XXXXXX) +cp $FILE $dir/ +ln -s $PWD/reduce-ice $dir/ +pushd $dir for x in ${@:-0 0 1 1 2 2 5 5 10 10} ; do multidelta -level=$x ./reduce-ice $FILE done +popd +cp $dir/$FILE $FILE +rm -rf $dir case $FILE in *.i|*.ii|*.c|*.cxx) Lindent $FILE;; diff --git a/reduce-ice b/reduce-ice index 1e71ac8..328af09 100755 --- a/reduce-ice +++ b/reduce-ice @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # # Run like: # multidelta -level=# ./reduce-ice $FILE @@ -13,4 +13,4 @@ CC=g++-3.4.6 CFLAGS="-ggdb -m32" STRING="internal compiler error.*dwarf2out_finish" -$CC -pipe -c $CFLAGS $FILE 2>&1 | grep "$STRING" +$CC -pipe -c $CFLAGS $FILE -o /dev/null 2>&1 | grep "$STRING"