🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.arch
Article #21954

PUSH on i8088/i80x86

#21954
From: Tom Davis
Date: Fri, 05 Jan 1990 13:31
16 lines
1049 bytes
In debugging some vendor code (:-) I came across what appears to be a subtle
difference between the i8088 and i80x86.  Without an i80x86 manual handy, I
wondered if someone could verify my claim...

On the i8088, a "PUSH SP" decrements SP before pushing it onto the stack.  On
the i80x86, SP is pushed onto the stack before it is decremented (somehow).
Therefore, on the i8088 the following code does not work as expected:

  PUSH SP
  POP  SP

(SP ends up "off by two bytes".)
-------
Tom Davis                 | The above statement shall be construed,
Network Software Services | interpreted, and governed by me alone.
Michigan State University | EMail: davistd@ibm.cl.msu.edu
Technical Details
Message-ID: <182DAVISTD@MSU>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!samsung!zaphod.mps.ohio-state.edu!usc!wuarchive!psuvax1!psuvm!msu.bitnet!davistd

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!samsung!zaphod.mps.ohio-state.edu!usc!wuarchive!psuvax1!psuvm!msu.bitnet!davistd
From: DAVISTD@MSU.BITNET (Tom Davis)
Newsgroups: comp.arch
Subject: PUSH on i8088/i80x86
Message-ID: <182DAVISTD@MSU>
Date: 5 Jan 90 13:31:02 GMT
Organization: Michigan State University
Lines: 14