• Max Kellermann's avatar
    MDEV-34973: innobase/lock0lock: add `noexcept` · 813123e3
    Max Kellermann authored
    MariaDB is compiled with C++ exceptions enabled, and that disallows
    some optimizations (e.g. the stack must always be unwinding-safe).  By
    adding `noexcept` to functions that are guaranteed to never throw,
    some of these optimizations can be regained.  Low-level locking
    functions that are called often are a good candidate for this.
    
    This shrinks the executable a bit (tested with GCC 14 on aarch64):
    
        text	  data	   bss	   dec	   hex	filename
     24448910	2436488	9473185	36358583	22ac9b7	build/release/sql/mariadbd
     24448622	2436488	9473537	36358647	22ac9f7	build/release/sql/mariadbd
    813123e3
transactional_lock_guard.h 4.81 KB