Path: utzoo!attcan!uunet!samsung!zaphod.mps.ohio-state.edu!unix.cis.pitt.edu!dsinc!netnews.upenn.edu!vax1.cc.lehigh.edu!lehigh.bitnet!KRW1 From: KRW1@Lehigh Newsgroups: comp.lang.pascal Subject: RE: I/O Port weirdness Message-ID: <02109023:21:38KRW1@lehigh.bitnet> Date: 3 Oct 90 04:21:38 GMT Lines: 12 To: lusysnz@VAX1.CC.LEHIGH.EDU X-Envelope-to: lusysnz Use the following inline function instead of the Pascal port array for reading: function inport(x: integer): byte; inline($5a/$eb/$00/$ec); Then instead of p := port[x], use p := inport(x). The problem is that on fast processors, the input may not be returned before the result is used. The inline function includes a short jump which flushes the prefetch queue on 286's and higher, slowing down the processor for the next (in) instruction. -- Kevin