public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* 16bit adressing architecture
@ 2003-07-16 22:31 Jan Zizka
  2003-07-17 15:53 ` Nick Clifton
  0 siblings, 1 reply; 3+ messages in thread
From: Jan Zizka @ 2003-07-16 22:31 UTC (permalink / raw)
  To: binutils

Hi,

I'm working on binutils port for Motorola's DSP56800 family, its
getting pretty mature, but during implementation of a testsuit I
have found that some general testcases are failing. Simple
reason is that DSP56800 byte is 16bit wide and I've build evething
around that assumption. So the object file is correct etc. But
for example align and struct test fail:

../as-new   -o dump.o /home/honzik/dsp56800/binutils/gas/testsuite/gas/all/struct.s
/home/honzik/dsp56800/binutils/gas/testsuite/../../binutils/nm-new  --extern-only dump.o > dump.out
regexp_diff match failure
regexp "^0+02 A w2$"
line   "00000001 A w2"
regexp_diff match failure
regexp "^0+04 A w3$"
line   "00000002 A w3"
FAIL: struct
../as-new   -o dump.o /home/honzik/dsp56800/binutils/gas/testsuite/gas/all/align.s
/home/honzik/dsp56800/binutils/gas/testsuite/../../binutils/objdump  -s -j .text dump.o > dump.out
regexp_diff match failure
regexp "^ 0010 ffffffff 05050505 ff090a0a 0a0a0a0a  ................$"
line   " 0008 ffffffff 05050505 ff090a0a 0a0a0a0a  ................"
regexp_diff match failure
regexp "^ 0020 ff00ff01 ff020202 ffff0303 04040404  ................$"
line   " 0010 ff00ff01 ff020202 ffff0303 04040404  ................"
regexp_diff match failure
regexp "^ 0030 ffffffff 05050505 ff090a0a 0a0a0a0a  ................$"
line   " 0018 ffffffff 05050505 ff090a0a 0a0a0a0a  ................"
FAIL: align

But you can see that generated code is correct for 16bit bytes.

Now the question is: should I change my port so that gas would think 
it's 8bit byte addressable, or should the tests be made somewhat more
general to cover correctly architectures with different byte sizes?

I would like to note that BFD has a notion of different byte sizes.

Any comments and suggestions welcome!

Jan

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: 16bit adressing architecture
  2003-07-16 22:31 16bit adressing architecture Jan Zizka
@ 2003-07-17 15:53 ` Nick Clifton
  2003-07-17 17:22   ` Jan Zizka
  0 siblings, 1 reply; 3+ messages in thread
From: Nick Clifton @ 2003-07-17 15:53 UTC (permalink / raw)
  To: Jan Zizka; +Cc: binutils

Hi Jan,

> I'm working on binutils port for Motorola's DSP56800 family, its
> getting pretty mature, but during implementation of a testsuit I
> have found that some general testcases are failing. Simple
> reason is that DSP56800 byte is 16bit wide and I've build evething
> around that assumption. So the object file is correct etc. But
> for example align and struct test fail:

> Now the question is: should I change my port so that gas would think 
> it's 8bit byte addressable, or should the tests be made somewhat more
> general to cover correctly architectures with different byte sizes?

I think that you should fix the tests.  Your gas port is behaving
correctly, it is the tests which are incorrect in their assumption of
the size of a byte.  I would try, if possible, to add alternative
versions of the expected output scripts that match 16bit bytes, and
then have the test driver scripts (*.exp) select the correct expected
output based on the architecture's byte size.

Cheers
        Nick
        

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: 16bit adressing architecture
  2003-07-17 15:53 ` Nick Clifton
@ 2003-07-17 17:22   ` Jan Zizka
  0 siblings, 0 replies; 3+ messages in thread
From: Jan Zizka @ 2003-07-17 17:22 UTC (permalink / raw)
  To: Nick Clifton; +Cc: binutils

Hi Nick,

> I think that you should fix the tests.  Your gas port is behaving
> correctly, it is the tests which are incorrect in their assumption of
> the size of a byte.  I would try, if possible, to add alternative
> versions of the expected output scripts that match 16bit bytes, and
> then have the test driver scripts (*.exp) select the correct expected
> output based on the architecture's byte size.

yes that was what I thought was the correct thing :), but I had to ask
since I was not sure if I didn't miss anything. I'll make those
changes and post them with my port when it will be ready. BTW thanks
for pointers about implementation ;)

Jan

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-07-17 17:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-16 22:31 16bit adressing architecture Jan Zizka
2003-07-17 15:53 ` Nick Clifton
2003-07-17 17:22   ` Jan Zizka

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).