diff options
author | 2010-06-30 19:04:51 +0000 | |
---|---|---|
committer | 2010-06-30 19:04:51 +0000 | |
commit | a25b5fd65f2416523dd7701cec7664e859497700 (patch) | |
tree | dc692336fc015e064382383f41b4cff266fc1bd1 | |
parent | Print MPLS label as decimal and not hex. All other places we print MPLS (diff) | |
download | wireguard-openbsd-a25b5fd65f2416523dd7701cec7664e859497700.tar.xz wireguard-openbsd-a25b5fd65f2416523dd7701cec7664e859497700.zip |
Use __attribute__ ((aligned (16)), to make sure the FPU state is aligned
on a 128-bit boundary like we do on amd64. The padding within the struct
made sure the state was properly aligned *within* the struct, but since the
alignment restriction on the struct itself was only 64-bit, the required
alignment was not guaranteed. We just got lucky.
ok oga@, guenther@
-rw-r--r-- | lib/libpthread/arch/i386/uthread_machdep.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libpthread/arch/i386/uthread_machdep.h b/lib/libpthread/arch/i386/uthread_machdep.h index 58b1425a75c..becb026755f 100644 --- a/lib/libpthread/arch/i386/uthread_machdep.h +++ b/lib/libpthread/arch/i386/uthread_machdep.h @@ -1,10 +1,10 @@ -/* $OpenBSD: uthread_machdep.h,v 1.9 2004/02/21 22:55:20 deraadt Exp $ */ +/* $OpenBSD: uthread_machdep.h,v 1.10 2010/06/30 19:04:51 kettenis Exp $ */ /* David Leonard, <d@csee.uq.edu.au>. Public domain. */ #include <machine/npx.h> struct _machdep_state { int esp; - int pad[3]; - union savefpu fpreg; /* must be 128-bit aligned */ + /* must be 128-bit aligned */ + union savefpu fpreg __attribute__ ((aligned (16))); }; |