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

reduce lock_sys.wait_mutex contention by using spinloop construct

    XMLWordPrintable

Details

    Description

      reduce lock_sys.wait_mutex contention by using spinloop construct

      • wait_mutex plays an important role when the workload involves conflicting transactions.
      • On a heavily contented system with increasing scalability
          quite possible that the majority of the transactions may have to wait
          before acquiring resources.
      • This causes a lot of contention of wait_mutex but most of this
          the contention is short-lived that tend to suggest the use of spin loop
          to avoid giving up compute core that in turn will involve os-scheduler  with additional latency.
      • Idea has shown promising results with performance improving up to 70-100% for write workload.

      Attachments

        1. custom spin vs pthread spin.png
          97 kB
          Krunal Bauskar
        2. MDEV-26779-1.pdf
          22 kB
          Axel Schwenke
        3. MDEV-26779-2.pdf
          15 kB
          Axel Schwenke
        4. MDEV-26779-3.pdf
          16 kB
          Axel Schwenke
        5. patch (custom spin) and patch (pthread spin).png
          16 kB
          Krunal Bauskar
        6. sysbench.pdf
          22 kB
          Axel Schwenke
        7. update-index (512 threads) x86 custom spin vs pthread spin loop.png
          65 kB
          Krunal Bauskar
        8. update-index (uniform) - baseline vs patched - arm.png
          39 kB
          Krunal Bauskar
        9. update-index (uniform) - baseline vs patched - x86.png
          39 kB
          Krunal Bauskar
        10. update-index (zipfian) - baseline vs patched - arm.png
          43 kB
          Krunal Bauskar
        11. update-index (zipfian) - baseline vs patched - x86.png
          43 kB
          Krunal Bauskar
        12. update-index (zipfian) - inline, update-index (zipfian) - noniline, update-non-index (zipfian) - inline and update-non-index (zipfian) - noninline.png
          20 kB
          Krunal Bauskar
        13. update-non-index (uniform) - baseline vs patched - arm.png
          43 kB
          Krunal Bauskar
        14. update-non-index (uniform) - baseline vs patched - x86.png
          63 kB
          Krunal Bauskar
        15. update-non-index (zipfian) - baseline vs patched - arm.png
          46 kB
          Krunal Bauskar
        16. update-non-index (zipfian) - baseline vs patched - x86.png
          43 kB
          Krunal Bauskar
        17. x86-wait-mutex-run.png
          95 kB
          Krunal Bauskar

        Issue Links

          Activity

            People

              marko Marko Mäkelä
              krunalbauskar Krunal Bauskar
              Votes:
              0 Vote for this issue
              Watchers:
              7 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.