Messages in this thread Patch in this message | | | Date | Mon, 14 Dec 1998 01:05:56 +0000 | From | Jamie Lokier <> | Subject | [PATCH] 2.1.131/i386: Fix miscellaneous code alignments |
| |
Linus,
Here is a patch to fix some alignments on i386.
1. The FPU emulator looks like it has some alignments in power-of-two form, from the old a.out days. These are all have `.align 2' for data that should by 4 byte aligned. I've updated the alignments. (Not all the FPU emulator alignments are like this though).
2. I've changed getuser.S and putuser.S to use the same alignment as other assembly routines. The patch is obvious.
Enjoy, -- Jamie
--- linux/arch/i386/math-emu/div_Xsig.S.devel2 Thu Oct 5 14:30:43 1995 +++ linux/arch/i386/math-emu/div_Xsig.S Mon Dec 14 00:18:29 1998 @@ -55,7 +55,7 @@ Local storage in a static area: Accumulator: FPU_accum_3:FPU_accum_2:FPU_accum_1:FPU_accum_0 */ - .align 2,0 + .align 4,0 FPU_accum_3: .long 0 FPU_accum_2: --- linux/arch/i386/math-emu/reg_round.S.devel2 Fri Jan 23 21:33:31 1998 +++ linux/arch/i386/math-emu/reg_round.S Mon Dec 14 00:18:59 1998 @@ -95,7 +95,7 @@ /* Not re-entrant, so we can gain speed by putting local storage in a static area: */ .data - .align 2,0 + .align 4,0 FPU_bits_lost: .byte 0 FPU_denormal: --- linux/arch/i386/math-emu/reg_u_div.S.devel2 Fri Jan 23 21:33:31 1998 +++ linux/arch/i386/math-emu/reg_u_div.S Mon Dec 14 00:19:22 1998 @@ -52,7 +52,7 @@ Result: FPU_accum_3:FPU_accum_2:FPU_accum_1:FPU_accum_0 Overflow flag: ovfl_flag */ - .align 2,0 + .align 4,0 FPU_accum_3: .long 0 FPU_accum_2: --- linux/arch/i386/lib/getuser.S.devel2 Fri Jan 23 23:04:02 1998 +++ linux/arch/i386/lib/getuser.S Mon Dec 14 00:29:35 1998 @@ -9,6 +9,8 @@ * return value. */ +#include <linux/linkage.h> + /* * __get_user_X * @@ -24,7 +26,7 @@ addr_limit = 12 .text -.align 4 + ALIGN .globl __get_user_1 __get_user_1: movl %esp,%edx @@ -35,7 +37,7 @@ xorl %eax,%eax ret -.align 4 + ALIGN .globl __get_user_2 __get_user_2: addl $1,%eax @@ -48,7 +50,7 @@ xorl %eax,%eax ret -.align 4 + ALIGN .globl __get_user_4 __get_user_4: addl $3,%eax --- linux/arch/i386/lib/putuser.S.devel2 Fri Jan 23 23:04:02 1998 +++ linux/arch/i386/lib/putuser.S Mon Dec 14 00:30:08 1998 @@ -7,6 +7,8 @@ * to make them more efficient. */ +#include <linux/linkage.h> + /* * __put_user_X * @@ -23,7 +25,7 @@ addr_limit = 12 .text -.align 4 + ALIGN .globl __put_user_1 __put_user_1: movl %esp,%ecx @@ -34,7 +36,7 @@ xorl %eax,%eax ret -.align 4 + ALIGN .globl __put_user_2 __put_user_2: addl $1,%eax @@ -47,7 +49,7 @@ xorl %eax,%eax ret -.align 4 + ALIGN .globl __put_user_4 __put_user_4: addl $3,%eax - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |