babl-ws / babl

Low-latency WebSocket Server
https://babl.ws
Apache License 2.0
68 stars 22 forks source link

Fix split lock issue on MappedSessionStatistics #136

Closed tonytamwk closed 3 months ago

tonytamwk commented 3 months ago

Run the following program on a CPU with split lock detection feature lscpu | grep split_loc and see the dmesg

    public static void main(String[] args) {
        MappedSessionStatistics stats = new MappedSessionStatistics();
        stats.messageSent(); // dmesg: [  180.886150] x86/split lock detection: #AC: java/10167 took a split_lock trap at address: 0x3ff2624d
        System.out.println(stats.messagesSent());
    }

https://docs.kernel.org/arch/x86/buslock.html