diff options
| author | Aargh Rai <aargh.rai+git@gmail.com> | 2026-07-07 14:30:21 +0530 |
|---|---|---|
| committer | Aargh Rai <aargh.rai+git@gmail.com> | 2026-07-07 14:30:21 +0530 |
| commit | 965bf81879b22a25fd9b0d17ce6defd3d51c6173 (patch) | |
| tree | eeadd04afb52e950a3345c7fa4bc51d94446a658 /src/ipc.h | |
| parent | 3c540db464f4034d0a393b076c79a26851f68f47 (diff) | |
engine can now send updates to uci
Diffstat (limited to 'src/ipc.h')
| -rw-r--r-- | src/ipc.h | 15 |
1 files changed, 12 insertions, 3 deletions
@@ -1,14 +1,14 @@ #ifndef IPC_H #define IPC_H +// NOT TRUE IPC: I REALISED I AM STUPID AND COULD HAVE JUST USED THREADS + #include <stdlib.h> #include <sys/mman.h> #include "fen.h" #include "uci/state.h" -void* create_shared_memory(size_t size); - typedef struct { struct uci_move *moves; int count; @@ -16,6 +16,8 @@ typedef struct { } comm_moves; struct engine_message { + int ready; + int depth; int seldepth; int multipv; @@ -30,9 +32,16 @@ struct engine_message { struct engine_message *next; }; +typedef struct { + struct engine_message **data; + int count; +} engine_messages; + enum { MESSAGE_FILLED, MESSAGE_READ, MESSAGE_PROCESSED }; typedef struct { - struct engine_message engine_message; + engine_messages *engine_messages; + + uci_state state; int uci_message_ready; struct fen_load from_position; |
