eis/shm
Huamonarch 9bb810d9ed Replace broken ColdMutex with dual-layer ShmSpinLock + std::mutex
The old ColdMutex (interprocess_mutex) was in process-local anonymous
namespace storage, so each process had its own copy — no actual
cross-process exclusion. Even if moved to SHM, interprocess_mutex is
not robust: a crash while holding the lock would deadlock on restart.

New design:
- ShmSpinLock: atomic<pid_t> in shared memory, kill(pid,0) detects
  dead owners (ESRCH → takeover), crash-safe by construction
- std::mutex: process-local, handles intra-process thread contention
  without burning CPU on the SHM spinlock
- DualLock: locks local first, then shm; unlocks in reverse

9 lock sites in MapRuleStat upgraded to std::lock_guard<DualLock>.
2026-05-13 10:21:55 +08:00
..
RuleStatShm.h Replace broken ColdMutex with dual-layer ShmSpinLock + std::mutex 2026-05-13 10:21:55 +08:00
RuleStatShm.hbk Initial commit: EIS C++ project with multi-process code 2026-05-09 11:23:45 +08:00
SerializeMap.h Initial commit: EIS C++ project with multi-process code 2026-05-09 11:23:45 +08:00
shm_header.h Initial commit: EIS C++ project with multi-process code 2026-05-09 11:23:45 +08:00
shmdir.sh Initial commit: EIS C++ project with multi-process code 2026-05-09 11:23:45 +08:00
SingletonTemp.hpp Initial commit: EIS C++ project with multi-process code 2026-05-09 11:23:45 +08:00
TaskData.h Fix: add default constructor to TaskRecord for map operator[] 2026-05-13 09:27:29 +08:00