MDEV-12353 suggests one idea for improving InnoDB crash recovery speed: Read the to-be-recovered pages sorted by page number. Currently, recv_apply_hashed_log_recs() picks a ‘random’ page number from recv_sys->addr_hash and then reads a number of pages around that number.
The most straightforward way to achieve this would seem to be to replace the hash table with an ordered data structure, such as std::map, which would automatically be iterated in an ordered fashion.
While we are at it, we should merge the
MDEV-12699 mlog_init_t to the same data structure.