4 ms·
Posix mmap is generally working, because that's easily mapped to a core API in Unicorn. I exposed the qemu mem_map_ptr API for mapping files as well, but I have
by lunixbochs 11y ago
Posix mmap is generally working, because that's easily mapped to a core API in Unicorn. I exposed the qemu mem_map_ptr API for mapping files as well, but I haven't integrated it yet (I emulate file mmap for now by copying the file into guest memory).
Signals are a pretty high priority, but are currently unimplemented. Usercorn has a trampoline mode that allows stopping the CPU, executing a section of code, and returning to the previous location when it's done. I can use this for signal dispatch. sigaction/signal syscalls will just register the address to call.
fork/clone/threads in general are not yet implemented, but the groundwork is mostly there - I'm mainly worried about memory synchronization, and might need to add APIs to Unicorn for this. Unicorn supports running an arbitrary number of CPUs in parallel in the same process, so I'm actually planning on making both forked processes and threads run in the same host process, and do a sort of PID namespace/transparent layer.
This will make stuff like emulating IPC or a process ptracing another process much easier to control, and I won't need an external process like wineserver to negotiate stuff the native system doesn't know how to do.