[test-suite] r243400 - Add CC_Hash to simple report, containing a hash of the binary.

Adam Nemet anemet at apple.com
Tue Jul 28 15:48:17 PDT 2015


I am afraid I am not much help in this area.  Chris should be back from vacation next week, hopefully he has some ideas on the Darwin bits.

Perhaps in the meantime you just want to make this step a no-op for Darwin.

Adam

> On Jul 28, 2015, at 2:21 PM, Kristof Beyls <kristof.beyls at arm.com> wrote:
> 
> 
> Ouch.
> 
> Yes, please revert. I'm afraid I don't easily have access to Darwin
> platforms, so do appreciate a bit of help on how this can be done
> on Darwin. Maybe on Darwin, tools don't generate sections with
> unique data per build (like recording the compiler revision in the
> .comment section), so the stripping isn't necessary on Darwin?
> If some sections do contain meta-data like that, I'm hoping some
> of the options supported by Darwin's version of strip allows to
> remove specific sections? Or maybe there's another tool that can
> do it?
> 
> Thanks,
> 
> Kristof
> 
>> -----Original Message-----
>> From: Adam Nemet [mailto:anemet at apple.com]
>> Sent: 28 July 2015 21:19
>> To: Kristof Beyls; Chris Matthews
>> Cc: LLVM Commits
>> Subject: Re: [test-suite] r243400 - Add CC_Hash to simple report,
>> containing a hash of the binary.
>> 
>> Hi Kristof,
>> 
>> Unfortunately, this is causing our LNT jobs to die because Darwin’s
>> strip does not support —remove-section:
>> 
>> error:
>> /Applications/Xcode.app/Contents/Developer/Toolchains/OSX10.10.xctoolcha
>> in/usr/bin/strip: unrecognized option: --remove-section=.comment
>> Usage:
>> /Applications/Xcode.app/Contents/Developer/Toolchains/OSX10.10.xctoolcha
>> in/usr/bin/strip [-AnuSXx] [-] [-d filename] [-s filename] [-R filename]
>> [-o output] file [...]
>> 
>> I will revert this shortly until we figure out a different way to do
>> this.
>> 
>> Adam
>> 
>>> On Jul 28, 2015, at 2:57 AM, Kristof Beyls <kristof.beyls at arm.com>
>> wrote:
>>> 
>>> Author: kbeyls
>>> Date: Tue Jul 28 04:57:39 2015
>>> New Revision: 243400
>>> 
>>> URL: http://llvm.org/viewvc/llvm-project?rev=243400&view=rev
>>> Log:
>>> Add CC_Hash to simple report, containing a hash of the binary.
>>> 
>>> 
>>> Modified:
>>>   test-suite/trunk/Makefile.programs
>>>   test-suite/trunk/TEST.simple.Makefile
>>>   test-suite/trunk/TEST.simple.report
>>> 
>>> Modified: test-suite/trunk/Makefile.programs
>>> URL:
>>> http://llvm.org/viewvc/llvm-project/test-suite/trunk/Makefile.programs
>>> ?rev=243400&r1=243399&r2=243400&view=diff
>>> ======================================================================
>>> ========
>>> --- test-suite/trunk/Makefile.programs (original)
>>> +++ test-suite/trunk/Makefile.programs Tue Jul 28 04:57:39 2015
>>> @@ -545,6 +545,12 @@ ifdef PROGRAM_OUTPUT_FILTER
>>> 	$(PROGRAM_OUTPUT_FILTER) $@
>>> endif
>>> 
>>> +$(PROGRAMS_TO_TEST:%=Output/%.simple-hash): \
>>> +Output/%.simple-hash: Output/%.simple
>>> +	cp $< $@; \
>>> +	strip --remove-section=.comment --remove-section='.note*' $@; \
>>> +	$(PROGDIR)/HashProgramOutput.sh $@
>>> +
>>> $(PROGRAMS_TO_TEST:%=Output/%.out-lli): \
>>> Output/%.out-lli: Output/%.llvm.bc $(LLI)
>>> 	$(RUNSAFELY) $(STDIN_FILENAME) $@ $(LLI)
>>> -info-output-file=$(CURDIR)/$@.info $(STATS) $(LLI_OPTS) $<
>>> $(RUN_OPTIONS)
>>> 
>>> Modified: test-suite/trunk/TEST.simple.Makefile
>>> URL:
>>> http://llvm.org/viewvc/llvm-project/test-suite/trunk/TEST.simple.Makef
>>> ile?rev=243400&r1=243399&r2=243400&view=diff
>>> ======================================================================
>>> ========
>>> --- test-suite/trunk/TEST.simple.Makefile (original)
>>> +++ test-suite/trunk/TEST.simple.Makefile Tue Jul 28 04:57:39 2015
>>> @@ -19,11 +19,12 @@ REPORTS_SUFFIX := $(addsuffix .report.tx
>>> #	-grep "^program" Output/$*.simple.compile.time >> $@
>>> 
>>> $(PROGRAMS_TO_TEST:%=Output/%.simple.compile.report.txt): \
>>> -Output/%.simple.compile.report.txt: Output/%.out-simple
>>> +Output/%.simple.compile.report.txt: Output/%.out-simple
>>> +Output/%.simple-hash
>>> 	@echo > $@
>>> 	@-if test -f Output/$*.simple; then \
>>> 	  echo "TEST-PASS: compile $(RELDIR)/$*" >> $@; \
>>> 	  echo "TEST-RESULT-compile-success: pass" >> $@;\
>>> +	  echo "TEST-RESULT-compile-hash: `cat Output/$*.simple-hash`" >>
>>> +$@;\
>>> 	else \
>>> 	  echo "TEST-FAIL: compile $(RELDIR)/$*" >> $@; \
>>> 	fi
>>> 
>>> Modified: test-suite/trunk/TEST.simple.report
>>> URL:
>>> http://llvm.org/viewvc/llvm-project/test-suite/trunk/TEST.simple.repor
>>> t?rev=243400&r1=243399&r2=243400&view=diff
>>> ======================================================================
>>> ========
>>> --- test-suite/trunk/TEST.simple.report (original)
>>> +++ test-suite/trunk/TEST.simple.report Tue Jul 28 04:57:39 2015
>>> @@ -26,6 +26,7 @@ sub FormatTime {
>>> ["CC"       , 'TEST-RESULT-compile-success: (pass|fail|xfail)'],
>>> ["CC_Time"  , 'TEST-RESULT-compile-time: user\s*([.0-9m:]+)',
>>> \&FormatTime],  ["CC_Real_Time", 'TEST-RESULT-compile-real-time:
>>> real\s*([.0-9m:]+)', \&FormatTime],
>>> + ["CC_Hash",      'TEST-RESULT-compile-hash: (.*)'],
>>> ["Exec"     , 'TEST-RESULT-exec-success: (pass|fail|xfail)'],
>>> ["Exec_Time", 'TEST-RESULT-exec-time: user\s*([.0-9m:]+)',
>>> \&FormatTime],  ["Exec_Real_Time", 'TEST-RESULT-exec-real-time:
>>> real\s*([.0-9m:]+)', \&FormatTime],
>>> 
>>> 
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> 
> 
> 





More information about the llvm-commits mailing list