]> sourceware.org Git - newlib-cygwin.git/commitdiff
arc: Use __ARC_UNALIGNED__ compiler macro
authorClaudiu Zissulescu <claziss@gmail.com>
Tue, 20 Aug 2024 12:10:39 +0000 (15:10 +0300)
committerJeff Johnston <jjohnstn@redhat.com>
Tue, 20 Aug 2024 22:23:06 +0000 (18:23 -0400)
Replace __ARC_ALIGNED_ACCESS__ macro with the compiler defined
macro __ARC_UNALIGNED__ and improve file comments.

Signed-off-by: Claudiu Zissulescu <claziss@gmail.com>
newlib/libc/machine/arc/memcpy-archs.S

index f30dafd4f9ff327d3d84a337d3f1907bbf831f8b..3c477a745f5d2c91cd961e65765b9c6d630d51ea 100644 (file)
 # define ZOLAND                        0xF
 #endif
 
-#ifdef __ARC_ALIGNED_ACCESS__
+
+;;; MEMCPY copy memory regions
+;;; Input arguments:
+;;;   r0 - output memory region
+;;;   r1 - input memory region
+;;;   r2 - size in bytes
+;;; Returns:
+;;;   r0 - pointer to the first byte of the output region
+;;; Clobber:
+;;;   r1, r2, r3, r4, r5, r6, r8r9, r10r11, lp_count
+
+#if !defined (__ARC_UNALIGNED__)
+
+;;; MEMCPY routine for the case when the CPU only accepts ALIGNED
+;;; accesses to memory.
 ENTRY (memcpy)
        prefetch  [r1]          ; Prefetch the read location
        prefetchw [r0]          ; Prefetch the write location
@@ -268,6 +282,8 @@ ENDFUNC (memcpy)
 
 #else
 
+;;; MEMCPY routine which is used by systems with unaligned memory
+;;; accesses.  This is the case for most of ARCHS CPU family.
 ENTRY(memcpy)
        prefetch  [r1]          ; Prefetch the read location
        prefetchw [r0]          ; Prefetch the write location
This page took 0.034039 seconds and 5 git commands to generate.