Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

innobase/{lock0lock,dict0dict}: add noexcept to lock/unlock methods #3531

Merged
merged 3 commits into from
Oct 1, 2024

Commits on Sep 23, 2024

  1. MDEV-34973: innobase/lock0lock: add noexcept

    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
    MaxKellermann committed Sep 23, 2024
    Configuration menu
    Copy the full SHA
    cc62b47 View commit details
    Browse the repository at this point in the history
  2. MDEV-34973: innobase/dict0dict: add noexcept to lock/unlock methods

    Another chance for cutting back overhead due to C++ exceptions being
    enabled; the `dict_sys_t` class is a good candidate because its
    locking methods are called frequently.
    
    Binary size reduction this time:
    
        text	  data	   bss	   dec	   hex	filename
     24448622	2436488	9473537	36358647	22ac9f7	build/release/sql/mariadbd
     24448474	2436488	9473601	36358563	22ac9a3	build/release/sql/mariadbd
    MaxKellermann committed Sep 23, 2024
    Configuration menu
    Copy the full SHA
    3da2f8c View commit details
    Browse the repository at this point in the history

Commits on Oct 1, 2024

  1. Configuration menu
    Copy the full SHA
    1a26511 View commit details
    Browse the repository at this point in the history