delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1999/08/06/16:26:08

Message-ID: <37AB3F5C.DB89CDD0@softhome.net>
Date: Fri, 06 Aug 1999 22:02:36 +0200
From: Laurynas Biveinis <lauras AT softhome DOT net>
X-Mailer: Mozilla 4.61 [en] (Win98; I)
X-Accept-Language: lt,en
MIME-Version: 1.0
To: djgpp-workers AT delorie DOT com
Subject: Re: CPU ID program, second version
References: <199908051734 DOT TAA19839 AT tyr DOT diku DOT dk>
Reply-To: djgpp-workers AT delorie DOT com

Morten Welinder wrote:
> Sure it can, and some do it.  Unless you are in real mode or ring 0,
> the "popf" instruction will do what the operating environment wants
> it to do.  It will not just move flags from the stack to the flags
> register.
> I have seen cases where the AC flag could not be turned on at all,
> even on a 486+.  Your code would say "386" for any CPU under such
> environments.

Oh my god... But my program has been tested under Win98, NT, DOSEMU
DPMI servers and they are most common. BTW, where did you those cases?
I still think that my code is OK, because those environments are really
rare and if particular environment does not allow to set AC flag, maybe
it has serious reasons for this?

> Regarding the switch and default: you should be prepared for someone
> to go out and buy a new machine in two years.  A spiffy i786 perhaps,
> who knows?

i786 would be good, but I somehow do not want to predict still 
unreleased CPU :)

Laurynas Biveinis

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019