Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site gitpyr.UUCP
Path: utzoo!watmath!clyde!cbosgd!gatech!gitpyr!kpk
From: kpk@gitpyr.UUCP (Kevin P. Kleinfelter)
Newsgroups: net.micro.pc
Subject: Clock Interrupt Screw-Up?
Message-ID: <822@gitpyr.UUCP>
Date: Wed, 25-Sep-85 22:28:11 EDT
Article-I.D.: gitpyr.822
Posted: Wed Sep 25 22:28:11 1985
Date-Received: Fri, 27-Sep-85 03:48:50 EDT
Organization: Georgia Institute of Technology
Lines: 25

I have a section of assembler code which exhibits an interesting anomaly:

  The code works just fine when interrupts are disabled.  However, when
interrupts are enabled the code produces the wrong results.  There is
nothing time-critical in the code -- it merely converts an ASCII encoded
number into a binary value, and back to ASCII, and then prints the result.
The result is always correct when interrupts are disabled, but about
1 in 20 times it is wrong when interrupts are enabled.  The wrong value
appears to be a random value, and appears on a random basis.  The only
interrupt which should be occuring is the clock (timer) interrupt.

Questions:
  Has anyone encountered similar behavior?
  Does the 8088 ALWAYS push and pop the flags correctly    int/rti?
  Are there any known bugs in MSDOS 2.1 's clock interrupt routine?


(The code is rather lengthy or I would post it).

Any suggestions, similar experiences, answers would be appreciated.



DISCLAIMER OF RESPONSIBILITY:
  My employer thinks I am responsible.  I am not.