Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Dec 2003 22:53:31 +0100 (CET)
From:      Mikulas Patocka <mikulas@artax.karlin.mff.cuni.cz>
To:        freebsd-hackers@freebsd.org
Cc:        freebsd-smp@freebsd.org
Subject:   Re: Hyperthreading crashes
Message-ID:  <Pine.LNX.4.58.0312132251560.16811@artax.karlin.mff.cuni.cz>
In-Reply-To: <Pine.LNX.4.58.0312132022340.8994@artax.karlin.mff.cuni.cz>
References:  <Pine.LNX.4.58.0312132022340.8994@artax.karlin.mff.cuni.cz>

next in thread | previous in thread | raw e-mail | index | archive | help
> Hi
>
> I use FreeBSD-4.9-RC1 on a machine with hyperthreading (it seems that
> hyperthreading support was ripped out of final 4.9 release --- why?)
>
> I get random SIGBUSes when compiling (once I got SIGSEGV too). When I
> compile only with make -j 1, I get no errors. Is it known problem with
> FreeBSD? Or does it mean that the machine is bad?
>
> How can I find what's the reason for particular SIGBUS signal --- what did
> the program wrong?

I found that it is caused by bogus aligment exceptions, when i modified
the kernel this way, it works (and programs don't crash):

Does anybody have a clue why this happens?

--- ../sys-49/i386/i386/trap.c  Thu Feb 27 19:09:59 2003
+++ i386/i386/trap.c    Sat Dec 13 22:33:48 2003
@@ -290,6 +290,11 @@
        type = frame.tf_trapno;
        code = frame.tf_err;

+       if (type == T_ALIGNFLT) {
+               printf("Bogus alignment check exception!\n");
+               return;
+       }
+
        if (in_vm86call) {
                if (frame.tf_eflags & PSL_VM &&
                    (type == T_PROTFLT || type == T_STKFLT)) {

Mikulas


Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.4.58.0312132251560.16811>