lkml.org 
[lkml]   [1996]   [Sep]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [off-topic] Fully virtualisable CPUs
Date
> Yeah it would run slow the first few times a process ran, but it would
> leave a long trail of compiled piecelets, and without too much
> difficulty that could be cached on disk along with the executable so
> that next time the executable was run the loader would load the
> cache'd interpreted reassembled progress. In this way, one could even
> boot a new version of Linux in a Linux window, or FreeBSD, or NT, or
> Windows '95, or ... CP/M :) or Solaris 'x86 ... Heck I can do this
> myself. Anybody have references on:
>
> * x86 instruction set

Intels Pentium and PPro manuals are on their web site. They seem to be
complete enough for your task.

What you are describing by the way is how things like the Executor Mac
emulator do to get fast Mac emulation on a Linux box. Before you leap boldly
into action remember some little 'catches'

1. You have to play with mmap and mprotect as well since there are
side effects you have to emulate (page table dirty bits for example), and
some memory writes eg to the page tables affect the emulator however they
are done by the process you are running.

2. Self modifying code

3. Even worse, code that looks at itself to see if it needs to self
modify this time.

It is doable Im sure but it is also a big job.

Alan


\
 
 \ /
  Last update: 2005-03-22 13:38    [W:0.079 / U:3.940 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site