Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.6, 10.11, 11.4, 11.8, 12.3
-
AMD64 and IA-32, with and without TSX-NI a.k.a. Restricted Transactional Memory (RTM)
-
Related to performance
Description
MDEV-26769 introduced hardware memory transactions for InnoDB, to allow lock elision in some cases. On POWER and s390x, the related HTM feature is always available.
To my understanding, the rtm ISA extension (xsave, xend, xabort), also known as TSX-NI, is only implemented in some high-end models of Intel® processors. Therefore, on IA-32 and AMD64, we initialize the global variable have_transactional_memory and check it in various places at runtime.
The call sites are identified by the macros TRANSACTIONAL_TARGET and TRANSACTIONAL_INLINE.
It would be useful to implement a dispatch by function pointers, so that there would be fewer conditional branches.
The target_clones function attribute that is available in recent versions of GCC and Clang may incur some limitations based on this report.
MDEV-37147 is conceptually related, in the way that we would want ISA variant specific clones of some functions, just targeting a different ISA.
Attachments
Issue Links
- relates to
-
MDEV-26769 InnoDB internal latches do not support hardware lock elision
-
- Closed
-
-
MDEV-37147 ARMv8 -moutline-atomics is suboptimal
-
- Open
-
-
MDEV-38671 SET GLOBAL innodb_buffer_pool_size cannot be increased by default
-
- Closed
-