[PATCH]: Allow GAS mcore port to accept .8byte pseudo op
Nick Clifton
nickc@redhat.com
Thu Jan 11 08:58:00 GMT 2007
More information about the Binutils mailing list
Thu Jan 11 08:58:00 GMT 2007
- Previous message (by thread): Get the version of binutils?
- Next message (by thread): [PATCH]: Use the alternative version of the lns-common-1 test for the MCore port
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi Guys, I recently discovered that the MCore port of GAS does not accept the .8byte directive due to a limitation in the way that it had coded the md_number_to_chars() function. Since we now have perfectly usable versions of this function in write.c I have applied the patch below to make use of them. Cheers Nick gas/ChangeLog 2007-01-11 Nick Clifton <nickc@redhat.com> * config/tc-mcore.c (md_number_to_chars): Use number_to_chars_{big|little}endian. Index: gas/config/tc-mcore.c =================================================================== RCS file: /cvs/src/src/gas/config/tc-mcore.c,v retrieving revision 1.41 diff -c -3 -p -r1.41 tc-mcore.c *** gas/config/tc-mcore.c 7 Jun 2006 11:27:57 -0000 1.41 --- gas/config/tc-mcore.c 11 Jan 2007 08:53:22 -0000 *************** md_estimate_size_before_relax (fragS * f *** 2170,2193 **** void md_number_to_chars (char * ptr, valueT use, int nbytes) { ! if (! target_big_endian) ! switch (nbytes) ! { ! case 4: ptr[3] = (use >> 24) & 0xff; /* Fall through. */ ! case 3: ptr[2] = (use >> 16) & 0xff; /* Fall through. */ ! case 2: ptr[1] = (use >> 8) & 0xff; /* Fall through. */ ! case 1: ptr[0] = (use >> 0) & 0xff; break; ! default: abort (); ! } else ! switch (nbytes) ! { ! case 4: *ptr++ = (use >> 24) & 0xff; /* Fall through. */ ! case 3: *ptr++ = (use >> 16) & 0xff; /* Fall through. */ ! case 2: *ptr++ = (use >> 8) & 0xff; /* Fall through. */ ! case 1: *ptr++ = (use >> 0) & 0xff; break; ! default: abort (); ! } } /* Round up a section size to the appropriate boundary. */ --- 2170,2179 ---- void md_number_to_chars (char * ptr, valueT use, int nbytes) { ! if (target_big_endian) ! number_to_chars_bigendian (ptr, use, nbytes); else ! number_to_chars_littleendian (ptr, use, nbytes); } /* Round up a section size to the appropriate boundary. */
- Previous message (by thread): Get the version of binutils?
- Next message (by thread): [PATCH]: Use the alternative version of the lns-common-1 test for the MCore port
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list