You have made it to the last part of the series. In part 2 we wrote a coroutine-based program that loads and parses a list of OBJ files using coroutines and
io_uring. The program still has a big disadvantage: its CPU-bound. Parsing of OBJ files, the most costly part of the algorithm, is performed sequentially on a single thread.
In the first part of the series we learned about io_uring by writing a program that reads and parses hundreds of OBJ files from disk. In this second part of the series we will rewrite that program of by making use of C++20 coroutines.
As part of my job I have to deal with quite heavy I/O loads. Multiple times I’ve jumped into a fighting ring facing challenges that demand me to perform thousands of I/O operations in the most efficient way possible. And I haven’t always won. This has directed my attention to more powerful weapons, weapons like io_uring. io_uring is a new asynchronous I/O API in the Linux kernel which offers efficiency and scalability never seen before. With coroutines accepted into the c++20 standard and matured enough implementations at my disposal, I had all I need to forge the ultimate weapon, or at the very least an irresistible hobby project.
I’ve created my very first YouTube video: Lua tutorial for absolute beginners.
Life is nothing but an endless stream of challenges. The past is made out of fought battles and the future never fails to offer new ones. But, as Marcus Aurelius once said, never let the future disturb you. You will meet it, if you have to, with the same weapons of reason which today arm you against the present.