Hacker News new | past | comments | ask | show | jobs | submit login

WSL (1) was what the BSD people call a "kernel personality", which allows one kernel to emulate another at the syscall and ABI level.



The fundamental difference is that BSD compat layers are mostly about ABI, and not the functionality itself - because it’s common for all of them.


So WSL1 on Windows is similar to Wine on Linux?


There is a big difference in that WSL1 only needed to implement Linux syscalls, they could use glibc and all other libraries from the Linux distribution that you are running, whereas Wine needs to reimplement all Windows APIs to work with most applications.

Also, Wine is really a program on top of Linux, while personalities are a core feature Windows. At a low level, the Windows kernel is agnostic wrt. the system ABI. Win32 is just one personality of the Windows kernel, just as NT used to have an OS/2 personality to run 16-bit OS/2 programs.


DanielK posted good points already, this is another perspective.

WSL1 shows off a character of the Windows kernel, Environment Subsystems: https://en.wikipedia.org/wiki/File:Windows_2000_architecture... (top right)

When you boot into Windows 10 normally, you are interacting with applications run by one of these subsystems.

WSL1 is now another of these subsystem.

Like wine, you are getting an API that looks just like Linux.

But, unlike wine, that Linux is a first-class citizen as far as the OS is concerned. It would be straightforward for the Windows devs to connect the Linux subsystem across to the Windows security module (see diagram). There is no analogy for that with Wine on Linux.


No, because Wine doesn't emulate NT system calls. It is a Win32 API compatibility layer.


Right.




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

Search: