Mail Archives: djgpp/2009/05/13/23:15:57
On Tue, 5 May 2009, Eli Zaretskii wrote:
> > From: Rugxulo <rugxulo AT gmail DOT com>
> > Date: Mon, 4 May 2009 22:08:44 -0700 (PDT)
> >
> > > Yes, and then test a lot on old machines which I don't even know where
> > > to find.
> >
> > What old machines in particular? Just cpu revisions or OSes or both??
>
> That depends on the method you use for detecting the CPU. If you use
> no privileged instructions, there should be no reason to test under
> different OSes, I think. Otherwise, yes.
This may not be relevant to a specific situation, but
generally speaking, bugs can occur in any any instruction,
privileged or otherwise. For example, the F00F and FDIV
CPU bugs[1] require no privileges[2] to trigger. Also,
normally unprivileged instructions such as floating point
can be programmed to generate exceptions, although that is
normally only done on CPUs lacking a math co-processor or
FPU [3], such as the 486SX and most 386 (SX, DX, or null
suffix) systems.
-aw
[1] I think I do have machines, or at least CPUs, affected
by either of those two bugs. If anyone has a need to
test code under these conditions I might look into it.
[2] LOCK is unprivileged on modern CPUs, but privileged on
some older x86 generations; however, that's not relevant
in the case of F00F, which occurs in the Pentium,
P. Overdrive and P. MMX and processors.
[3] In those cases, the exceptions allow the invocation of
an emulator to process the missing FP instructions).
I've had to load one for DJGPP apps on occasions.
- Raw text -