* read.c (s_set): Remove unused local ptr.
authorIan Lance Taylor <ian@airs.com>
Thu, 10 Aug 1995 04:44:59 +0000 (04:44 +0000)
committerIan Lance Taylor <ian@airs.com>
Thu, 10 Aug 1995 04:44:59 +0000 (04:44 +0000)
(hex_float): Check target_big_endian.
(equals): Remove unused local p.
* config/tc-a29k.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-h8500.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-hppa.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-i860.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-m68k.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-m88k.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-tahoe.h (TARGET_BYTES_BIG_ENDIAN): Define.
* config/tc-sh.c (little): Set target_big_endian.
(md_begin): Likewise.
(md_parse_option): Likewise.
(build_relax): Check target_big_endian rather than shl.
(build_Mytes, md_atof): Likewise.
(md_convert_frag, md_apply_fix): Likewise.
(md_number_to_chars): Likewise.

gas/ChangeLog
gas/config/tc-a29k.h
gas/config/tc-h8500.h
gas/config/tc-m88k.h
gas/config/tc-tahoe.h
gas/read.c

index ccdf546d008a57c15dcee459ec1e2dfcc646ff14..0db30c755b7d0b41f2a2695efa39b1c61aac3603 100644 (file)
@@ -1,3 +1,23 @@
+Thu Aug 10 00:38:11 1995  Ian Lance Taylor  <ian@cygnus.com>
+
+       * read.c (s_set): Remove unused local ptr.
+       (hex_float): Check target_big_endian.
+       (equals): Remove unused local p.
+       * config/tc-a29k.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-h8500.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-hppa.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-i860.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-m68k.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-m88k.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-tahoe.h (TARGET_BYTES_BIG_ENDIAN): Define.
+       * config/tc-sh.c (little): Set target_big_endian.
+       (md_begin): Likewise.
+       (md_parse_option): Likewise.
+       (build_relax): Check target_big_endian rather than shl.
+       (build_Mytes, md_atof): Likewise.
+       (md_convert_frag, md_apply_fix): Likewise.
+       (md_number_to_chars): Likewise.
+       
 Wed Aug  9 10:51:48 1995  Ian Lance Taylor  <ian@cygnus.com>
 
        * config/tc-m68k.c (m68k_abspcadd): New static variable.
index 7701a61710741128c1435b3656cdda64705c8df6..5f4f2b2f96ad66bc4c8aed7ce8a544c9b1e60c41 100644 (file)
@@ -19,6 +19,8 @@ the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307
 
 #define TC_A29K
 
+#define TARGET_BYTES_BIG_ENDIAN        1
+
 #define tc_headers_hook(a)             ;       /* not used */
 #define tc_headers_hook(a)             ;       /* not used */
 #define tc_crawl_symbol_chain(a)       ;       /* not used */
index 5644a1bf0077d3d6c21494163e38057b3b89f5ba..db241f07c5dfd9602f051ce8da79039fb422a21e 100644 (file)
@@ -20,6 +20,9 @@
 
 
 #define TC_H8500
+
+#define TARGET_BYTES_BIG_ENDIAN 1
+
 /* This macro translates between an internal fix and an coff reloc type */
 #define TC_COFF_FIX2RTYPE(fixP) tc_coff_fix2rtype(fixP)
 
index 9508b49ccf954cc975e6a5bbde095e1ceae6a5aa..ac8289e9ab9a71db87831f28034c8bc8fcfa1463 100644 (file)
@@ -22,6 +22,8 @@ the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307
 
 #define TC_M88K
 
+#define TARGET_BYTES_BIG_ENDIAN 1
+
 #ifdef M88KCOFF
 #define COFF_MAGIC MC88OMAGIC
 #define BFD_ARCH bfd_arch_m88k
index 87cdf65e57c181312be1d8ea37a82e2f658fac66..be8a5bea8e244ef427227f157d734dfdd451f558 100644 (file)
@@ -20,6 +20,8 @@
 
 #define TC_TAHOE 1
 
+#define TARGET_BYTES_BIG_ENDIAN 1
+
 #define NO_LISTING
 
 #define tc_headers_hook(a)             {;}     /* don't need it. */
index 47847ccf62c6ad29dafe1684506e1f4ce3a1c9df..e1f1a077a0c0f846712f0674035446df65bf9666 100644 (file)
@@ -1680,7 +1680,6 @@ s_set (ignore)
       /* Turn '. = mumble' into a .org mumble */
       register segT segment;
       expressionS exp;
-      register char *ptr;
 
       segment = get_known_segmented_expression (&exp);
 
@@ -2662,11 +2661,20 @@ hex_float (float_type, bytes)
          d += hex_value (*input_line_pointer);
          ++input_line_pointer;
        }
-      bytes[i++] = d;
+      if (target_big_endian)
+       bytes[i] = d;
+      else
+       bytes[length - i - 1] = d;
+      ++i;
     }
 
   if (i < length)
-    memset (bytes + i, 0, length - i);
+    {
+      if (target_big_endian)
+       memset (bytes + i, 0, length - i);
+      else
+       memset (bytes, 0, length - i);
+    }
 
   return length;
 }
@@ -3148,7 +3156,6 @@ equals (sym_name)
       /* Turn '. = mumble' into a .org mumble */
       register segT segment;
       expressionS exp;
-      register char *p;
 
       segment = get_known_segmented_expression (&exp);
       if (!need_pass_2)