Date: Sun, 21 Jul 2013 12:47:34 +0000 (UTC) From: Andrew Turner <andrew@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r253518 - head/lib/libc/arm/gen Message-ID: <201307211247.r6LClYvj016960@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: andrew Date: Sun Jul 21 12:47:33 2013 New Revision: 253518 URL: http://svnweb.freebsd.org/changeset/base/253518 Log: Teach siglongjmp about the VFP version of the setjmp buffer. This fixes a bug where a call to sigsetjmp followed by siglongjmp may fail when run on a machine with VFP enabled. Modified: head/lib/libc/arm/gen/sigsetjmp.S Modified: head/lib/libc/arm/gen/sigsetjmp.S ============================================================================== --- head/lib/libc/arm/gen/sigsetjmp.S Sun Jul 21 11:59:41 2013 (r253517) +++ head/lib/libc/arm/gen/sigsetjmp.S Sun Jul 21 12:47:33 2013 (r253518) @@ -57,8 +57,10 @@ ENTRY(sigsetjmp) WEAK_ALIAS(__siglongjmp, siglongjmp) ENTRY(siglongjmp) - ldr r2, .L_setjmp_magic - ldr r3, [r0] - teq r2, r3 + ldr r2, .L_setjmp_magic /* load magic */ + ldr r3, [r0] /* get magic from jmp_buf */ + bic r3, r3, #(_JB_MAGIC__SETJMP ^ _JB_MAGIC__SETJMP_VFP) + /* ignore VFP-ness of magic */ + teq r2, r3 /* magic correct? */ beq PIC_SYM(_C_LABEL(_longjmp), PLT) b PIC_SYM(_C_LABEL(longjmp), PLT)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201307211247.r6LClYvj016960>