Port-sparc archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Anyone have working pre-v8 machines?
>> v7/post-v7 can be tested by trying to use a hardware multiplication
>> instruction; if it causes an illegal instruction error, it's v7 (...
>> unless the OS traps and emulates it but I don't think NetBSD or any
>> Sun OSes do that), otherwise it's v8 or newer.
Well, looking at NetBSD/sparc 1.4T trap.c, I see
case T_ILLINST:
case T_UNIMPLFLUSH:
if ((n = emulinstr(pc, tf)) == 0) {
ADVANCE;
break;
}
trapsignal(p, n, 0); /* XXX code?? */
break;
and then emulinst(), in emul.c, handles only certain instructions; I
haven't worked out exactly which ones, but it does call something
called muldiv(), which is commented
/*
* We check for {S,U}{MUL,DIV}{,cc}
*
* [c = condition code, s = sign]
* Mul = 0c101s
* Div = 0c111s
*/
and it looks to me as though it _tries_ to handle multiplication. So I
suspect NetBSD might well handle it.
I certainly could build a kernel that doesn't, though, or I could print
something when that code runs, or some such.
/~\ The ASCII Mouse
\ / Ribbon Campaign
X Against HTML mouse%rodents-montreal.org@localhost
/ \ Email! 7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B
Home |
Main Index |
Thread Index |
Old Index