From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 10 08:12:10 2012 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 93CA03CC for ; Mon, 10 Dec 2012 08:12:10 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: from mail-lb0-f182.google.com (mail-lb0-f182.google.com [209.85.217.182]) by mx1.freebsd.org (Postfix) with ESMTP id 124658FC0C for ; Mon, 10 Dec 2012 08:12:09 +0000 (UTC) Received: by mail-lb0-f182.google.com with SMTP id go10so2297270lbb.13 for ; Mon, 10 Dec 2012 00:12:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=opYEARHgf4Z/Ya/s4ku2tAiAYCN8nlrnLaQnSJIZBaQ=; b=PEsqBk4J1Ljx2kuiGEfFl/lmSOZAyGWBowFaz0Cj+6gIYfK1aK8N8Zh8CcWeBsCzDe Tl0XeR4JYjGYbOfTta5yw4TnqYjj1mZNUE31FysudsnY/TSRi2PcwnHOo3bN5kQP8A2y +cny+on05P4eQ01Ogb/tQ//l8ntQyNlvqd+vyKJfgGd/aoVK064Xrty4e9oa7wE8eCP2 oKT39zBWjYzqKMv1LLULNQoAl6su5AdXsjW5MdZyvmwG12NFShO9k3VMyticwkUKXtFD TJero3mpURNTCxrz6sh5ytRzLQuKaBPPeEC8BE7o+oR7g2c/ki/zG5ziV4jfwJYFK75U +W+Q== MIME-Version: 1.0 Received: by 10.112.101.232 with SMTP id fj8mr5359029lbb.83.1355127128568; Mon, 10 Dec 2012 00:12:08 -0800 (PST) Received: by 10.112.61.33 with HTTP; Mon, 10 Dec 2012 00:12:08 -0800 (PST) In-Reply-To: References: Date: Mon, 10 Dec 2012 03:12:08 -0500 Message-ID: Subject: Re: using FreeBSD to create a completely new OS From: Zaphod Beeblebrox To: Aryeh Friedman Content-Type: text/plain; charset=ISO-8859-1 Cc: FreeBSD Mailing List X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Dec 2012 08:12:10 -0000 On Mon, Dec 10, 2012 at 2:56 AM, Aryeh Friedman wrote: > On Mon, Dec 10, 2012 at 2:38 AM, Zaphod Beeblebrox wrote: > I know (about the list not being google) and have seen the formats for > MBR's (even wrote a few by hand) the question was how to extract it > from the virtual HDD (see above).... namely is I have a prototype MBR > that should be made I want to check if it was actually written to the > virtual HDD correctly The simplest thing I can think of is to attach said virtual disk to a FreeBSD guest and use dd. Sure ... I'm pretty sure the virtual disk you're using is documented, but follow the path of least resistance. > From my initial research there is almost nothing that depends on > actual ASM except for a very small number of things that create the > environment needed to run the equiv of the JVM (no garbage collection > at this level) natively on an x86. My guess the total amount of ASM > needed is less then a thousand instructions (99% are macro's mostly > for performance reasons). The other 1% is just to get the protected > mode and the native JVM loaded and started. If you mean swtch.s here, I suppose you're interpreting what I said rightly. > Note when I say JVM I actually mean a collection of VM's that model > real HW (not some abstract HW like the sun JVM does) and if the VM > just happens to be identical to the native HW then it skips the > emulation part of the VM (i.e. direct execution on the actual HW). > The first such VM I am planning is x86 (64-bit). Namely if your > running on a PC then it runs natively but on anything else it runs on > a VM identical to a PC. Note that this pretty much makes java pretty much worthless. I say that carefully as the seemingly "good" thing that makes the extra effort in java "worth it" is the guarantee against the halting problem that makes the security madness possible. If your "vm" is i386, you can't offer that guarantee. The JVM is very specially crafted for this purpose.