Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/lib/libkern/arch/m68k Keep stack longword aligned.



details:   https://anonhg.NetBSD.org/src/rev/c346b3b5d0a7
branches:  trunk
changeset: 788695:c346b3b5d0a7
user:      matt <matt%NetBSD.org@localhost>
date:      Thu Jul 18 12:42:24 2013 +0000

description:
Keep stack longword aligned.
Use longword ops for %d2.

diffstat:

 sys/lib/libkern/arch/m68k/scanc.S |  12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diffs (30 lines):

diff -r 2df6825044a7 -r c346b3b5d0a7 sys/lib/libkern/arch/m68k/scanc.S
--- a/sys/lib/libkern/arch/m68k/scanc.S Thu Jul 18 12:40:42 2013 +0000
+++ b/sys/lib/libkern/arch/m68k/scanc.S Thu Jul 18 12:42:24 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: scanc.S,v 1.7 2013/07/18 12:40:42 matt Exp $   */
+/*     $NetBSD: scanc.S,v 1.8 2013/07/18 12:42:24 matt Exp $   */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -49,15 +49,15 @@
        movl    8(%sp),%a0      | start of scan
        movl    12(%sp),%a1     | table to compare with
        movb    19(%sp),%d1     | and mask to use
-       movw    %d2,-(%sp)      | need a scratch register
-       clrw    %d2             | clear it out
+       movl    %d2,-(%sp)      | need a scratch register
+       clrl    %d2             | clear it out
        subqw   #1,%d0          | adjust for dbra
 Lscloop:
        movb    (%a0)+,%d2      | get character
-       movb    (%a1,%d2:w),%d2 | get table entry
-       andb    %d1,%d2         | mask it
+       movb    (%a1,%d2),%d2   | get table entry
+       andl    %d1,%d2         | mask it
        dbne    %d0,Lscloop     | keep going til no more or non-zero
        addqw   #1,%d0          | overshot by one
-       movw    (%sp)+,%d2      | restore scratch
+       movl    (%sp)+,%d2      | restore scratch
 Lscdone:
        rts



Home | Main Index | Thread Index | Old Index