Details
-
Task
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Fixed
Description
Table_map_iterator in sql_bitmap.h iterates over all bits set in a ulonglong variable.
Current implementation shows that there was an attempt to make it optimized, with prebuilt small offset table, and this gives in my tests about 30% improvement over naïve implementation.
But as I found during my test, using compiler intrinsics such as _builtin_ctzll(GCC,Clang) or _BitScanForward64(MSVC) can speed it up further by 200-300% over the current implementation.
intrinsics map to bsf instructions on Intel processors
Attachments
Activity
Field | Original Value | New Value |
---|---|---|
Priority | Major [ 3 ] | Minor [ 4 ] |
Fix Version/s | 10.5.0 [ 23709 ] | |
Fix Version/s | 10.5 [ 23123 ] | |
Resolution | Fixed [ 1 ] | |
Status | Open [ 1 ] | Closed [ 6 ] |
Workflow | MariaDB v3 [ 97557 ] | MariaDB v4 [ 133996 ] |