This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Testsuite for avr-as
- From: Hans-Peter Nilsson <hp at bitrange dot com>
- To: Erik Christiansen <erik at dd dot nec dot com dot au>
- Cc: binutils at sources dot redhat dot com, "Dmitry K." <dmixm at marine dot febras dot ru>
- Date: Mon, 6 Dec 2004 20:11:45 -0500 (EST)
- Subject: Re: Testsuite for avr-as
- References: <20041207003334.GB732@dd.nec.com.au>
On Tue, 7 Dec 2004, Erik Christiansen wrote:
> G'day,
>
> Unlike other gas implementations, avr-as lacks a formal testsuite. Over
> on the avr-gcc list, a couple of us are seeking to rectify that. Rather
> than go too far with "home-brew" test schemes, we're trying to scrabble
> up the binutils testsuite learning curve.
>
> A bit of poking around in the binutils source distribution shows .s and
> .d files. Is there some doco that we can read, to discover:
>
> a) Preferred method for generating .d files.
Method? Hah! The output of either objdump or readelf
redirected, then inspected for sanity and edited to regexpify
the contents.
> b) Rather than further develop our existing prototype test engines, what
> script does binutils use to bang through the .s/.d pairs?
Something tells me you're not aware how the DejaGNU-based
testsuite (usually) works. Build binutils, then run "make -k
check" and watch DejaGnu load and execute the various .exp files
and run whatever is said there, usually using stuff from the
installed DejaGnu and gas/testsuite/gas/lib. (You can do this
for AVR if you want; some tests are generic.)
My favorite is run_dump_test iterating over .d files. See
gas/testsuite/gas/mmix/mmix.exp.
Sometimes you need to test for proper error message or error
handling. See gas/testsuite/gas/mmix/mmix-err.exp. (No .d,
just source files.)
Sometimes you want to just check that the assembly listing looks
about right. See gas/testsuite/gas/mmix/mmix-list.exp.
Usually the test iterates over ".l" files.
> Oh, a horrible thought: If this is to find its way into the distribution
> one day, then there's likely to be some requirements we should know about.
Good thinking. Copyright assignment *papers* signed from *all*
contributors. (Hopefully Nick Clifton, head binutils maintainer,
will fill in here with proper references.)
brgds, H-P