Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/13/84; site intelca.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!oliveb!hplabs!intelca!kds From: kds@intelca.UUCP (Ken Shoemaker) Newsgroups: net.micro.pc Subject: Re: Re: Clock Interrupt Screw-Up? Message-ID: <116@intelca.UUCP> Date: Tue, 8-Oct-85 00:21:09 EDT Article-I.D.: intelca.116 Posted: Tue Oct 8 00:21:09 1985 Date-Received: Sat, 12-Oct-85 19:06:36 EDT References: <822@gitpyr.UUCP> <201@mips.UUCP> Organization: Intel, Santa Clara, Ca. Lines: 49 > Without seeing the code, this is purely a guess ... > > Sounds alot like you've been bitten by the "multiple prefixes on a string-op" > feature of the 8086/8. Let's say, for example, you code: > > rep movs ES:byte ptr[DI],CS:[SI] > > to move a string. "rep" is a prefix to the "movs" instruction, but so is > the "CS:" seg-reg override byte. As long as there's no interruption, this > works just fine. If a rupt occurs in the middle of the move though, watch > out! > > ......................... > > Anyway, if you find any such beasties, just stick a "cli/sti" pair around > the offender, and maybe send a "Thank you" note to those wonderful folk who > brought you segmentation in the first place :-). Hope this helps. > > BTW, anyone know if this stunning example of architectural innovation is still > with us in the 286? > > /kim > > "Anything free is worth what you pay for it." -- Lazarus Long > > -- > > UUCP: {decvax,ucbvax,ihnp4}!decwrl!mips!kim > DDD: 415-960-1200 > USPS: MIPS Computer Systems Inc, 1330 Charleston Rd, Mt View, CA 94043 Actually, the "normal" order of prefixes puts the repeat prefix before the segment override prefix, so that what happens then is that you don't move enough words or whatever. In this case, the fix is even easier: you just check the cx register after the string move and loop if it isn't zero. I agree that this isn't the best of all possible worlds, and this little feature isn't also featured on the 186 or the 286: they iret you to the first prefix, so the string move picks up correctly where it left off. What this has to do with segmentation, I'll never know... -- ...and I'm sure it wouldn't interest anybody outside of a small circle of friends... Ken Shoemaker, Microprocessor Design for a large, Silicon Valley firm {pur-ee,hplabs,amd,scgvaxd,dual,qantel}!intelca!kds ---the above views are personal. They may not represent those of the employer of its submitter.