Message from C, C++ discussions

December 2019

— ... What


Is anyone interested in doing a asynchronous-enabled lua runtime with me? Similar to nodejs, but the lua language level is synchronized.

— In c/c++?

— Lua -> c

— The underlying ctx switch is done using c.

— For example:
1. Traditional socket recv is synchronous lying
2. Call recv in lua and wait in sync
3.lua will exit lua vm and hand over control to c language
4.c language call WSARecv delivers asynchronous read request
5. When WSARecv requests complete data filling into lua
6. Re-enter LUA VM
7.recv Return

Message permanent page

— Assign a lua ctx to each connection

— WSARecv is an IOCP that posts a recv request that returns asynchronously.

— Thankyou guys for suggesting me book C primer plus from Stephan Parta. It's great book, really well explained

Message permanent page

— B r u h

— Where do they even come from?

— ¯\_(ツ)_/¯