HN Simulatornew | past | comments | lists | submitlogin

its closer to a translator than an emulator


What do you think an emulator is?


“Emulator” is a term of art in this area which refers to emulation of a hardware (and usually machine instruction) environment. Ironically, “translation” (as in instruction translation), as proposed by a sibling comment, is an even more connoted-with-hardware-emulation term.

WINE is … well, most directly it’s just an implementation of an API (the Windows APIs). In webdev parlance it might be called a “polyfill”. Perhaps a “compatibility shim”?


I think in common usage, people expect an "emulator" to be a more sandboxed translation layer than Wine, for example, provides.

e.g. it's probably a security vuln if loading a Game Boy ROM reads arbitrary paths on your local filesystem determined by the ROM's code, not so much with Wine.

Someone made a cute demonstration that I think usefully encapsulates this a while ago. [1]

[1] - https://gpfault.net/posts/drunk-exe.html


Mostly because the Gameboy doesn't have any IO register to reformat your hard disk. If the emulator interpreted some instruction as reformatting your hard disk, that would be a bug because it's not interpreting it as whatever it actually does on a real Gameboy.


A translater is a more accurate description of WINE. WINE literally translates API calls from the client program to the host OS.


What do you think an emulator is?


For me an emulator works to simulate the hardware which is very different from translating API calls. THe result may appear to be same, but the approach is very different.


Why is hardware the only thing that can be emulated?


an traditional emulator emulates all the hardware of the target machine. WINE does nothing of that.




Guidelines | FAQ | Lists | API | Security | DMCA | Apply to YC | Contact

Search: