From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f891f,14f3fa9fb2c63b2d X-Google-Attributes: gidf891f,public X-Google-Thread: fb4a0,14f3fa9fb2c63b2d X-Google-Attributes: gidfb4a0,public X-Google-Thread: fc89c,14f3fa9fb2c63b2d X-Google-Attributes: gidfc89c,public X-Google-Thread: 109fba,14f3fa9fb2c63b2d X-Google-Attributes: gid109fba,public X-Google-Thread: 103376,14f3fa9fb2c63b2d X-Google-Attributes: gid103376,public X-Google-Thread: 102b75,14f3fa9fb2c63b2d X-Google-Attributes: gid102b75,public X-Google-Thread: f678f,14f3fa9fb2c63b2d X-Google-Attributes: gidf678f,public X-Google-Thread: 10cc59,14f3fa9fb2c63b2d X-Google-Attributes: gid10cc59,public X-Google-ArrivalTime: 1993-12-17 09:59:57 PST Xref: gmd.de comp.lang.misc:5294 comp.lang.ada:8901 comp.lang.pascal:17748 comp.lang.c++:40828 comp.unix.programmer:10983 comp.arch:18225 comp.unix.osf.misc:849 comp.unix.unixware:809 comp.lang.dylan:1585 comp.lang.eiffel:2126 comp.lang.lisp:5080 Newsgroups: comp.lang.misc,comp.lang.ada,comp.lang.pascal,comp.lang.c++,comp.unix.programmer,comp.arch,comp.unix.osf.misc,comp.unix.unixware,comp.lang.dylan,comp.lang.eiffel,comp.lang.lisp Path: gmd.de!newsserver.jvnc.net!howland.reston.ans.net!cs.utexas.edu!geraldo.cc.utexas.edu!portal.austin.ibm.com!awdprime.austin.ibm.com!yoder From: yoder@austin.ibm.com () Subject: Re: translation of x86 binary to native Sender: news@austin.ibm.com (News id) Message-ID: Date: Fri, 17 Dec 1993 14:07:18 GMT References: <2eq6u8$2m1@hydrogen.smallworld.co.uk> Organization: IBM Austin X-Newsreader: TIN [version 1.1 PL8] Followup-To: comp.lang.misc,comp.lang.ada,comp.lang.pascal,comp.lang.c++,comp.unix.programmer,comp.arch,comp.unix.osf.misc,comp.unix.unixware,comp.lang.dylan,comp.lang.eiffel,comp.lang.lisp Arthur Chance (arthur@Smallworld.co.uk) wrote: : In article , yoder@austin.ibm.com () writes: : > Dave Yost (Dave@Yost.COM) wrote: : > : A while back, I thought I heard of one x86 emulation vendor : > : who, instead of interpreting x86 code, translated it on the : > : fly to native machine code, which they would then run instead. : > : Yet, it seems that SoftPC is king, and they only interpret. : > : What's the deal? : > : > I'm pretty sure that SoftPC translates to native machine code : > and then runs it (as opposed to interpreting x86 code an instruction : > at a time). IBM's PCSIM for AIX also follows this method. : Unless it's been changed, SoftPC interprets x86 code. I've seen a remark : from someone in Insignia saying the hardest part of writing SoftPC was : emulating the hardware bugs - it really is intended to be bug for bug : compatible with the genuine hardware (PC AT, I think, but I haven't looked : at SoftPC for some years now, so they may have "upgraded the processor"). Whether or not SoftPC is bug for bug compatible with the genuine hardware has nothing to do with the method of emulation-- translation vs. interpretation. I think of _interpretation_ as through the cycle of fetching an instruction, decoding it, and emulating the function on the native machine. This is repeated for each instruction. I would consider _translation_ as being done in blocks-- decode an entire block of x86 instructions and generate a corresponding block of code on the native machine that emulates the x86 block. Then execute the block of native instructions. The advantage here is that the block can be saved and next time it can simply be executed-- no decoding, etc. needs to done. Of course if instruction modification takes place the block must be 'purged' and re-translated. I don't know the workings of SoftPC by personal experience so I'm not positive how they do it. Stuart