Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/x86/x86 Add more KASSERTs, see if they help PR/53383.
details: https://anonhg.NetBSD.org/src/rev/88495dd74a67
branches: trunk
changeset: 319999:88495dd74a67
user: maxv <maxv%NetBSD.org@localhost>
date: Mon Jun 18 20:20:27 2018 +0000
description:
Add more KASSERTs, see if they help PR/53383.
diffstat:
sys/arch/x86/x86/fpu.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (43 lines):
diff -r 16c929fd79dc -r 88495dd74a67 sys/arch/x86/x86/fpu.c
--- a/sys/arch/x86/x86/fpu.c Mon Jun 18 18:33:31 2018 +0000
+++ b/sys/arch/x86/x86/fpu.c Mon Jun 18 20:20:27 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: fpu.c,v 1.37 2018/06/17 06:03:40 maxv Exp $ */
+/* $NetBSD: fpu.c,v 1.38 2018/06/18 20:20:27 maxv Exp $ */
/*
* Copyright (c) 2008 The NetBSD Foundation, Inc. All
@@ -96,7 +96,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: fpu.c,v 1.37 2018/06/17 06:03:40 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: fpu.c,v 1.38 2018/06/18 20:20:27 maxv Exp $");
#include "opt_multiprocessor.h"
@@ -628,6 +628,7 @@
fpusave_lwp(l, false);
fpu_save = process_fpframe(l);
pcb = lwp_getpcb(l);
+ KASSERT(pcb->pcb_fpcpu == NULL);
if (i386_use_fxsave) {
memset(&fpu_save->sv_xmm, 0, x86_fpu_save_size);
@@ -654,6 +655,7 @@
* CPU.
*/
if (x86_fpu_eager) {
+ KASSERT(l == curlwp);
fpu_eagerswitch(NULL, l);
}
}
@@ -693,6 +695,8 @@
if (extra > 0)
memcpy(pcb2 + 1, pcb1 + 1, extra);
+
+ KASSERT(pcb2->pcb_fpcpu == NULL);
}
/* -------------------------------------------------------------------------- */
Home |
Main Index |
Thread Index |
Old Index