[llvm-commits] [test-suite] r50678 - in /test-suite/trunk: Makefile.programs TEST.nightly.Makefile TEST.nightly.report

Devang Patel dpatel at apple.com
Mon May 5 17:02:06 PDT 2008


On May 5, 2008, at 4:57 PM, Chris Lattner wrote:

> On May 5, 2008, at 4:05 PM, Devang Patel wrote:
>> URL: http://llvm.org/viewvc/llvm-project?rev=50678&view=rev
>> Log:
>> Add OPT_BETA support.
>>
>> Now you can do
>>   make TEST=nightly  ENABLE_OPTBETA=1 OPTBETAOPTIONS="-verify"
>> to see whether -std-comiple-opts passes are worth any dime or not.
>
> Cool.  Did you verify that this does not break the nightly tester?
> Adding another column to its output could be bad.

I'll disable the patch that updates report.html for now.

>
>
> -Chris
>
>>
>>
>> This command will do
>>
>> $ llvm-gcc -O0 ...
>> $ llvm-gcc -O0 ...
>> $ llvm-ld ... -o linked.rbc
>> $ opt -std-compile-opts linked.rbc -o linked.bc
>> $ llvm-ld ... linked.bc -o foo.llvm
>> $ llc .. foo.llvm.bc -o foo.llc.s
>> $ gcc foo.llc.s -o foo.llc
>>
>> and
>>
>> $ opt $(OPTBETAOPTIONS) linked.rbc -o linked.optbeta.bc
>> $ llvm-ld .. linked.optbeta.bc -o foo.llvm.optbeta
>> $ llc .. foo.llvm.optbeta.bc -o foo.opt-beta.s
>> $ gcc foo.opt-beta.s -o foo.opt-beta
>>
>>
>>
>> Modified:
>>   test-suite/trunk/Makefile.programs
>>   test-suite/trunk/TEST.nightly.Makefile
>>   test-suite/trunk/TEST.nightly.report
>>
>> Modified: test-suite/trunk/Makefile.programs
>> URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/Makefile.programs?rev=50678&r1=50677&r2=50678&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- test-suite/trunk/Makefile.programs (original)
>> +++ test-suite/trunk/Makefile.programs Mon May  5 18:05:59 2008
>> @@ -44,6 +44,7 @@
>>
>> .PRECIOUS: Output/%.llvm Output/%.native Output/%.llc Output/%.llc.s
>> .PRECIOUS: Output/%.cbe Output/%.cbe.c Output/%.llvm.bc Output/
>> %.linked.bc
>> +.PRECIOUS: Output/%.linked.optbeta.bc Output/%.llvm.optbeta.bc
>>
>> PROGDIR = $(PROJ_SRC_ROOT)
>>
>> @@ -129,6 +130,7 @@
>> JITBETADIFFS  := $(addsuffix .diff-jit-beta, $
>> (PREFIXED_PROGRAMS_TO_TEST))
>> LLCDIFFS  := $(addsuffix .diff-llc, $(PREFIXED_PROGRAMS_TO_TEST))
>> LLCBETADIFFS  := $(addsuffix .diff-llc-beta, $
>> (PREFIXED_PROGRAMS_TO_TEST))
>> +OPTBETADIFFS  := $(addsuffix .diff-opt-beta, $
>> (PREFIXED_PROGRAMS_TO_TEST))
>> CBEDIFFS  := $(addsuffix .diff-cbe, $(PREFIXED_PROGRAMS_TO_TEST))
>>
>> # Profiles for the program.
>> @@ -137,11 +139,11 @@
>>
>> # Build Program outputs:
>> .PRECIOUS: Output/%.out-lli Output/%.out-jit Output/%.out-llc Output/
>> %.out-llc-beta
>> -.PRECIOUS: Output/%.out-nat Output/%.out-cbe
>> +.PRECIOUS: Output/%.out-nat Output/%.out-cbe Output/%.out-opt-beta
>>
>> # Build diffs from the output...
>> -.PRECIOUS: Output/%.diff-lli Output/%.diff-jit
>> -.PRECIOUS: Output/%.diff-llc Output/%.diff-llc-beta Output/%.diff- 
>> cbe
>> +.PRECIOUS: Output/%.diff-lli Output/%.diff-jit Output/%.diff-opt- 
>> beta
>> +.PRECIOUS: Output/%.diff-llc Output/%.diff-llc-beta Output/%.diff- 
>> cbe
>>
>>
>> # Regardless of what other options are specified, build the
>> program's bytecode
>> @@ -259,6 +261,10 @@
>> Output/%.llvm.stripped.bc: Output/%.llvm.bc $(LOPT)
>> 	-$(LOPT) -mstrip $< -o $@ -f
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.linked.optbeta.bc): \
>> +Output/%.linked.optbeta.bc: Output/%.linked.rbc $(LOPT)
>> +	-$(LOPT) $(OPTBETAOPTIONS) -time-passes -info-output-file=$
>> (CURDIR)/$@.info $(STATS)  $< -o $@ -f
>> +
>>
>> ifndef DISABLE_FOR_LLVM_PROGRAMS
>> # Rule to produce final program bytecode file from linked,
>> optimized, bytecode.
>> @@ -281,6 +287,14 @@
>> 	$(MV) -f $@.tmp $@
>> endif
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.llvm.optbeta.bc): \
>> +Output/%.llvm.optbeta.bc: Output/%.linked.optbeta.bc $(LLVMLDPROG)
>> +	-$(LLVMLD) $(STATS) $<  $(EXTRA_LINKTIME_OPT_FLAGS) $
>> (LLVMLD_FLAGS) -lc $(LIBS) -o Output/$*.llvm.optbeta
>> +
>> +$(PROGRAMS_TO_TEST:%=Output/%.llvm.optbeta): \
>> +Output/%.llvm.optbeta: Output/%.linked.optbeta.bc $(LLVMLDPROG)
>> +	-$(LLVMLD) $(STATS) $<  $(LLVMLD_FLAGS) -lc $(LIBS) -o Output/
>> $*.llvm.optbeta
>> +
>> $(PROGRAMS_TO_TEST:%=Output/%.noopt-llvm.bc): \
>> Output/%.noopt-llvm.bc: Output/%.linked.rbc $(LLVMLDPROG)
>> 	-$(LLVMLD) -disable-opt $(STATS) $(LLVMLD_FLAGS) $< -lc $(LIBS) -o
>> Output/$*.noopt-llvm
>> @@ -359,6 +373,10 @@
>> Output/%.llc-beta.s: Output/%.llvm.bc $(LLC)
>> 	-$(LLC) $(LLCFLAGS) -f $(LLCBETAOPTION) $< -o $@
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.opt-beta.s): \
>> +Output/%.opt-beta.s: Output/%.llvm.optbeta.bc $(LLC)
>> +	-$(LLC) $(LLCFLAGS) -f  $< -o $@
>> +
>> # On darwin, pass -force_cpusubtype_ALL to allow all ppc  
>> instructions.
>> ifeq ($(ARCH),PowerPC)
>> LLCASSEMBLERFLAGS = -force_cpusubtype_ALL
>> @@ -378,6 +396,10 @@
>> Output/%.llc-beta: Output/%.llc-beta.s
>> 	-$(LLVMGCCLD) $< -o $@ $(LLCLIBS) $(LLCASSEMBLERFLAGS) $
>> (TARGET_FLAGS) $(LDFLAGS)
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.opt-beta): \
>> +Output/%.opt-beta: Output/%.opt-beta.s
>> +	-$(LLVMGCCLD) $< -o $@ $(LLCLIBS) $(LLCASSEMBLERFLAGS) $
>> (TARGET_FLAGS) $(LDFLAGS)
>> +
>>
>> #
>> # Rules to execute the program
>> @@ -431,6 +453,10 @@
>> Output/%.out-llc-beta: Output/%.llc-beta
>> 	-$(RUNSAFELY) $(STDIN_FILENAME) $@ $< $(RUN_OPTIONS)
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.out-opt-beta): \
>> +Output/%.out-opt-beta: Output/%.opt-beta
>> +	-$(RUNSAFELY) $(STDIN_FILENAME) $@ $< $(RUN_OPTIONS)
>> +
>> $(PROGRAMS_TO_TEST:%=Output/%.out-cbe): \
>> Output/%.out-cbe: Output/%.cbe
>> 	-$(RUNSAFELY) $(STDIN_FILENAME) $@ $< $(RUN_OPTIONS)
>> @@ -491,6 +517,10 @@
>> Output/%.bugpoint-llc-beta: Output/%.llvm.bc $(LBUGPOINT) Output/
>> %.out-nat
>> 	$(LBUGPOINT) $< -run-llc $(BUGPOINT_OPTIONS) $(LLCBETAOPTION) $
>> (BUGPOINT_ARGS)
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.bugpoint-opt-beta): \
>> +Output/%.bugpoint-opt-beta: Output/%.llvm.optbeta.bc $(LBUGPOINT)
>> Output/%.out-nat
>> +	$(LBUGPOINT) $< -run-llc $(BUGPOINT_OPTIONS) $(LLCBETAOPTION) $
>> (BUGPOINT_ARGS)
>> +
>> $(PROGRAMS_TO_TEST:%=Output/%.bugpoint-jit): \
>> Output/%.bugpoint-jit: Output/%.llvm.bc $(LBUGPOINT) Output/%.out-nat
>> 	$(LBUGPOINT) $< -run-jit $(BUGPOINT_OPTIONS) $(BUGPOINT_ARGS)
>> @@ -561,6 +591,10 @@
>> Output/%.diff-llc-beta: Output/%.out-nat Output/%.out-llc-beta
>> 	-$(DIFFPROG) llc-beta $* $(HIDEDIFF)
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.diff-opt-beta): \
>> +Output/%.diff-opt-beta: Output/%.out-nat Output/%.out-opt-beta
>> +	-$(DIFFPROG) opt-beta $* $(HIDEDIFF)
>> +
>> $(PROGRAMS_TO_TEST:%=Output/%.diff-cbe): \
>> Output/%.diff-cbe: Output/%.out-nat Output/%.out-cbe
>> 	-$(DIFFPROG) cbe $* $(HIDEDIFF)
>> @@ -591,6 +625,11 @@
>> 	-rm -f $@
>> 	-cp $< $@
>>
>> +$(PROGRAMS_TO_TEST:%=Output/%.exe-opt-beta): \
>> +Output/%.exe-opt-beta: Output/%.diff-opt-beta
>> +	-rm -f $@
>> +	-cp $< $@
>> +
>> $(PROGRAMS_TO_TEST:%=Output/%.exe-cbe): \
>> Output/%.exe-cbe: Output/%.diff-cbe
>> 	-rm -f $@
>>
>> Modified: test-suite/trunk/TEST.nightly.Makefile
>> URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/TEST.nightly.Makefile?rev=50678&r1=50677&r2=50678&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> = 
>> =====================================================================
>> --- test-suite/trunk/TEST.nightly.Makefile (original)
>> +++ test-suite/trunk/TEST.nightly.Makefile Mon May  5 18:05:59 2008
>> @@ -22,6 +22,9 @@
>> ifdef ENABLE_LLCBETA
>> REPORTS_TO_GEN += llc-beta
>> endif
>> +ifdef ENABLE_OPTBETA
>> +REPORTS_TO_GEN += opt-beta
>> +endif
>> REPORTS_SUFFIX := $(addsuffix .report.txt, $(REPORTS_TO_GEN))
>>
>>
>> @@ -85,7 +88,22 @@
>> 	  echo "TEST-FAIL: llc-beta $(RELDIR)/$*" >> $@;\
>> 	fi
>>
>> -
>> +# OPT experimental tests
>> +$(PROGRAMS_TO_TEST:%=Output/%.nightly.opt-beta.report.txt): \
>> +Output/%.nightly.opt-beta.report.txt: Output/%.llvm.optbeta.bc
>> Output/%.exe-opt-beta $(LLC)
>> +	@echo > $@
>> +	-head -n 100 Output/$*.exe-opt-beta >> $@
>> +	@-if test -f Output/$*.exe-opt-beta; then \
>> +	  echo "TEST-PASS: opt-beta $(RELDIR)/$*" >> $@;\
>> +	  $(LLC) $< $(LLCFLAGS) -o /dev/null -f $(TIMEOPT) >> $@ 2>&1; \
>> +	  printf "TEST-RESULT-opt-beta: " >> $@;\
>> +	  grep "Total Execution Time" $@.info >> $@;\
>> +	  printf "TEST-RESULT-opt-beta-time: " >> $@;\
>> +	  grep "^program" Output/$*.out-opt-beta.time >> $@;\
>> +	  echo >> $@;\
>> +	else  \
>> +	  echo "TEST-FAIL: opt-beta $(RELDIR)/$*" >> $@;\
>> +	fi
>>
>> # CBE tests
>> $(PROGRAMS_TO_TEST:%=Output/%.nightly.cbe.report.txt): \
>>
>> Modified: test-suite/trunk/TEST.nightly.report
>> URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/TEST.nightly.report?rev=50678&r1=50677&r2=50678&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> = 
>> =====================================================================
>> --- test-suite/trunk/TEST.nightly.report (original)
>> +++ test-suite/trunk/TEST.nightly.report Mon May  5 18:05:59 2008
>> @@ -56,6 +56,17 @@
>>  return "-";
>> }
>>
>> +sub OPTOPT_BETARatio {   # OPT/OPT-BETA
>> +  my ($Cols, $Col) = @_;
>> +  my $LLC = $Cols->[$Col-9];
>> +  my $OPT_BETA = $Cols->[$Col-7];
>> +  return "n/allc" if ($LLC eq "*");
>> +  return "n/aopt" if ($OPT_BETA eq "*");
>> +  return "n/a" if ($LLC eq "*" or $OPT_BETA eq "*");
>> +  return sprintf("%3.2f", $LLC/$OPT_BETA) if ($LLC >= 0.1 and
>> $OPT_BETA >= 0.1);
>> +  return "-";
>> +}
>> +
>> # highlight the RATIO columns with green/red.
>> $HilightColumns{14} = 1;
>> $HilightColumns{15} = 1;
>> @@ -74,16 +85,19 @@
>> ["Bytecode" , 'TEST-RESULT-compile: *([0-9]+)'],
>> ["LLC compile" , "TEST-RESULT-llc: .*$WallTimeRE"],
>> ["LLC-BETA compile" , "TEST-RESULT-llc-beta: .*$WallTimeRE"],
>> + ["OPT-BETA compile" , "TEST-RESULT-opt-beta: .*$WallTimeRE"],
>> ["JIT codegen" , "TEST-RESULT-jit-comptime: .*$WallTimeRE"],
>> [],
>> ["GCC"      , 'TEST-RESULT-nat-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> ["CBE"      , 'TEST-RESULT-cbe-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> ["LLC"      , 'TEST-RESULT-llc-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> ["LLC-BETA" , 'TEST-RESULT-llc-beta-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> + ["OPT-BETA" , 'TEST-RESULT-opt-beta-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> ["JIT"      , 'TEST-RESULT-jit-time: program\s*([.0-9m:]+)',
>> \&FormatTime],
>> [],
>> ["GCC/CBE"  , \&GCCCBERatio],
>> ["GCC/LLC"  , \&GCCLLCRatio],
>> ["GCC/LLC-BETA"  , \&GCCLLC_BETARatio],
>> - ["LLC/LLC-BETA"  , \&LLCLLC_BETARatio]
>> + ["LLC/LLC-BETA"  , \&LLCLLC_BETARatio],
>> + ["OPT/OPT-BETA"  , \&OPTOPT_BETARatio]
>> );
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

-
Devang






More information about the llvm-commits mailing list