This is the mail archive of the newlib@sources.redhat.com mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] lib/machine/h8300/*.S: Use setarch.h.


Hi,

Attached is a patch to apply Richard Sandiford's idea of setarch.h to
lib/machine/h8300/*.S.

Tested on h8300 port.  OK to apply?

Kazu Hirata

2003-06-23  Kazu Hirata  <kazu@cs.umass.edu>

	* libc/machine/h8300/setarch.h: New.
	* libc/machine/h8300/memcpy.S: Use it.
	* libc/machine/h8300/memset.S: Likewise.
	* libc/machine/h8300/reg_memcpy.S: Likewise.
	* libc/machine/h8300/reg_memset.S: Likewise.
	* libc/machine/h8300/setjmp.S: Likewise.
	* libc/machine/h8300/strcmp.S: Likewise.

*** /dev/null	2003-01-30 05:24:37.000000000 -0500
--- setarch.h	2003-06-23 21:42:30.000000000 -0400
***************
*** 0 ****
--- 1,14 ----
+ #ifdef __H8300H__
+ #ifdef __NORMAL_MODE__
+ 	.h8300hn
+ #else
+ 	.h8300h
+ #endif
+ #endif
+ #ifdef __H8300S__
+ #ifdef __NORMAL_MODE__
+ 	.h8300sn
+ #else
+ 	.h8300s
+ #endif
+ #endif
Index: memcpy.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/memcpy.S,v
retrieving revision 1.2
diff -c -r1.2 memcpy.S
*** memcpy.S	28 May 2003 18:00:17 -0000	1.2
--- memcpy.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,20 ****
! #include "defines.h"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
  
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  	.global _memcpy
  _memcpy:
--- 1,6 ----
! #include "setarch.h"
  
! #include "defines.h"
  
  	.global _memcpy
  _memcpy:
Index: memset.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/memset.S,v
retrieving revision 1.2
diff -c -r1.2 memset.S
*** memset.S	28 May 2003 18:00:17 -0000	1.2
--- memset.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,21 ****
! #include "defines.h"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
! 
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  
  ; A0P pointer to cursor
  ; A1P thing to copy
--- 1,6 ----
! #include "setarch.h"
  
+ #include "defines.h"
  
  ; A0P pointer to cursor
  ; A1P thing to copy
Index: reg_memcpy.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/reg_memcpy.S,v
retrieving revision 1.2
diff -c -r1.2 reg_memcpy.S
*** reg_memcpy.S	28 May 2003 18:00:17 -0000	1.2
--- reg_memcpy.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,21 ****
! #include "defines.h"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
! 
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  
  	; dst A0
  	; src A1
--- 1,6 ----
! #include "setarch.h"
  
+ #include "defines.h"
  
  	; dst A0
  	; src A1
Index: reg_memset.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/reg_memset.S,v
retrieving revision 1.2
diff -c -r1.2 reg_memset.S
*** reg_memset.S	28 May 2003 18:00:17 -0000	1.2
--- reg_memset.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,21 ****
! #include "defines.h"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
! 
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  
  	; dst A0
  	; src A1
--- 1,6 ----
! #include "setarch.h"
  
+ #include "defines.h"
  
  	; dst A0
  	; src A1
Index: setjmp.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/setjmp.S,v
retrieving revision 1.3
diff -c -r1.3 setjmp.S
*** setjmp.S	28 May 2003 18:00:17 -0000	1.3
--- setjmp.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,20 ****
! 	.file "setjmp.S"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
  
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  	.section .text
  	.align	2
--- 1,6 ----
! #include "setarch.h"
  
! 	.file "setjmp.S"
  
  	.section .text
  	.align	2
Index: strcmp.S
===================================================================
RCS file: /cvs/src/src/newlib/libc/machine/h8300/strcmp.S,v
retrieving revision 1.2
diff -c -r1.2 strcmp.S
*** strcmp.S	28 May 2003 18:00:17 -0000	1.2
--- strcmp.S	24 Jun 2003 01:49:07 -0000
***************
*** 1,20 ****
! #include "defines.h"
! 
! #ifdef __H8300H__
! #ifdef __NORMAL_MODE__
! 	.h8300hn
! #else
! 	.h8300h
! #endif
! #endif
  
! #ifdef __H8300S__
! #ifdef __NORMAL_MODE__
! 	.h8300sn
! #else
! 	.h8300s
! #endif
! #endif
  
  	.section .text
  	.align 2
--- 1,6 ----
! #include "setarch.h"
  
! #include "defines.h"
  
  	.section .text
  	.align 2


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]