Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-25029

Reduce dict_sys mutex contention for read-only workload

    XMLWordPrintable

Details

    Description

      • Currently, during read-only workload with high contention (say 1024 threads)
        dict_sys mutex contention rises as a top-contention (as reported by performance schema).
      • read-only workload ideally shouldn't have anything to do with dict_sys mutex
        but optimizer needs stats and to read stat dict_sys mutex is taken.
      • dict_sys is global mutex even though optimizer may request stat for a said table only.
      • this contention is heavily visible when operating with higher scalability and especially
        with more numa nodes things get worse.
      wait/synch/mutex/innodb/dict_sys_mutex 24670208.7616 50001391

      <60 secs ro workload> ...

      wait/synch/mutex/innodb/dict_sys_mutex 36223993.1059 95602955

      -------------------------

      How to solve it?

      • Probably check how dict_sys mutex could be relaxed for concurrent access.
      • Marko suggested a better solution. Starting 10.6 there is table->lock_mutex.
        Given table level mutex it could help reduce the contention.

      --------------------------------------------

      Very early POC has show improvement in sysbench-ro workload qps by 5-7%.
      The approach also helps support the numa-scalability goal.

      Attachments

        Issue Links

          Activity

            People

              marko Marko Mäkelä
              krunalbauskar Krunal Bauskar
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.