Live data from Hacker News

V86 – An x86-compatible CPU and hardware emulator

github.com

51–58 of 58 posts

Re: V86 – An x86-compatible CPU and hardware emulator

#51

Slightly off-topic, but back in the day "V86" (or "VM86") used to refer to the 80386 CPU's inbult 8086 hardware virtualization mechanism: https://en.wikipedia.org/wiki/Virtual_8086_mode

One of the things that AMD broke in x86-64, and after that, both AMD and Intel decided to develop a new virtualisation mechanism completely incompatible both with V86 and each other (VT-x, AMD-V)... I think V86 mode was definitely far less appreciated than it should've been.

On the other hand, I couldn't get a working command prompt in the Win98 demo, so it seems V86 does not emulate V86 quite right. ;-)

Re: V86 – An x86-compatible CPU and hardware emulator

#52
post #43

Earlier quoted context omitted.

Frozen in carbonite? Just a guess.

Yup, FF simply froze ...

Thanks! I checked out urban dictionary and got the impression that perhaps you had expressed your love to your computer and it didn't return it in kind... same thing I guess.

Re: V86 – An x86-compatible CPU and hardware emulator

#55

Earlier quoted context omitted.

> How much work would be required ... Can't speak to his NIC emulation (unless he borrowed it from jor1k), but otherwise it'd take roughly a flight from PDX to CHS for the NIC, plus another 2-3 hours for a dead simple virtual switch, plus a few days of watching the switch crash in various odd ways while HN, Reddit, and Slashdot beat it up. Edit: If anyone is keen to experiment around with v86, jor1k, or a similar pro…

Bro, How much time does it need to replicate a project like V86? I have close to 6 years in C++. I work for intel/amd but not on emulation, I do HW design. I want to know if this can be completed in 4-6 months doing work on the night only.. TIA.

No clue how far you'd get, but I'd think you could come up with something interesting in that time frame. It's a lot more approachable than you might think.

I'm not well acquainted with Copy, so I don't know how long the bulk of the work took him. I'd suggest pinging him or Sebastian Macke (the guy behind jor1k) if you'd like to know more.

My understanding was that Sebastian chose OpenRISC in part because of the simplicity of the instruction set. I got the impression that this made the task a bit more approachable than x86 emulation, and gave him more hope for achieving a good emulation speed. And, in fact, it's quite snappy considering what it is. However I think he had to put a fair amount of effort into gcc and glibc debugging to really get it off the ground, and I know that he used to put a bunch of time into tuning the cores for each new version of asm.js, though I'm not sure how in flux it is these days.

Re: V86 – An x86-compatible CPU and hardware emulator

#56
post #34

Earlier quoted context omitted.

But they're not internet connected, are they? I tried `ping 8.8.8.8` from each of them without any luck.

I pinged successfully from the linux 3 machine. You need to run a command first though, it says so two lines above where the shell begins

Oops, I missed those lines! All working now. Thanks.

Re: V86 – An x86-compatible CPU and hardware emulator

#58

Earlier quoted context omitted.

> How much work would be required ... Can't speak to his NIC emulation (unless he borrowed it from jor1k), but otherwise it'd take roughly a flight from PDX to CHS for the NIC, plus another 2-3 hours for a dead simple virtual switch, plus a few days of watching the switch crash in various odd ways while HN, Reddit, and Slashdot beat it up. Edit: If anyone is keen to experiment around with v86, jor1k, or a similar pro…

Bro, How much time does it need to replicate a project like V86? I have close to 6 years in C++. I work for intel/amd but not on emulation, I do HW design. I want to know if this can be completed in 4-6 months doing work on the night only.. TIA.

Just take a look at the link to the third talk I gave a few days ago about jor1k.

https://github.com/s-macke/jor1k/wiki/Technical-details

This talk give a few details about time frames and what someone has to do to emulate such a machine. If it is just about booting Linux you can do it in around 2000 lines (first commit of jor1k) if you take an easy architecture such as OpenRISC. Take a look at slide no. 10 and you might get an idea about the complexity of the other architectures. Slight 15 and 16 give you an idea why OpenRISC can be emulated much faster than any other architecture. A downside of such an non-mainstream CPU is less support. Indeed as Benjamin said, at least 50% of the time went into bugfixing and enhancing the toolchain. In the end the MIPS architecture might be optimal for a fast emulation and a well maintained toolchain.

Post reply on HN