home *** CD-ROM | disk | FTP | other *** search
- Path: soap.news.pipex.net!pipex!usenet
- From: m.hendry@dial.pipex.com (Mathew Hendry)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: 680X0 -> PPC translator?
- Date: Wed, 28 Feb 96 04:48:12
- Organization: Private node.
- Distribution: world
- Message-ID: <19960228.43D838.45DF@an173.du.pipex.com>
- References: <4fstt2$old@newsstand.cit.cornell.edu> <PETERM.96Feb19135541@tui.maths.irl.cri.nz> <4glch6$rle@ra.nrl.navy.mil> <1190.6631T892T581@und.ida.liu.se> <4gvg0v$j2j@newsstand.cit.cornell.edu> <4h0dum$lb0@werple.net.au>
- NNTP-Posting-Host: an173.du.pipex.com
- X-Newsreader: TIN [AMIGA 1.3 950726BETA PL0]
-
- Chris Hames (bytey@werple.net.au) wrote:
- : fkrj@crux4.cit.cornell.edu (Benjamin Kenobi) writes:
- :
- : >On the amiga, don't we have separate "hunks" for code and data?
- :
- : Yes but code hunks can contain data and data hunks can contain code. You
- : need a much more strict executable format if you want to static translate to
- : another processor for all cases (without an unlimited machine).
-
- In which case you need an emulation engine as well as a static translator. I
- believe DEC have a solution along these lines - it is a combination x86
- translator / emulator for Windows NT running on Alphas. It claims 70% of
- native Alpha performance for translated WinNT x86 executables - i.e. a
- translated x86 executable runs at 70% of the speed of that same application
- compiled for and running on an Alpha. An analog of this for PPC Amigas would
- be a godsend.
-
- Handling instructions and data misplaced in hunks would be difficult to
- handle, though, and I am not sure how strict Windows NT is about such
- faults - i.e. does it allow them _at all_?
-
- I can think of one possible method to deal with the problem which might be
- reasonably efficient in execution, but would require use of the MMU to
- operate.
-
- The executable would be a fat binary format, containing the translated code
- and data hunks and also the untranslated hunks in their original, or perhaps a
- slightly altered, form.
-
- Thus pretranslated instruction execution can proceed as normal, using the
- translated instruction and data hunks, _until_ an attempt is made to access
- _data_ in a code hunk (such accesses could be detected using the MMU). When
- this occurs the original code hunk must be referred to, since the translated
- code will be effectively impossible to reverse-translate into data.
-
- A similar procedure could be used to handle code executed from within a data
- hunk, although this may not be necessary if the translated data hunks are only
- marginally different from the originals. A cache of translated versions of
- this misplaced code would probably speed things up substantially.
-
- The above description is obviously overly simplistic, and extra layers of
- support would have to be built-in to provide access to OS calls and other
- shared routines and data, but am I on the right track here?
-
- -- Mat.
-