mirror of
https://github.com/MariaDB/server.git
synced 2026-05-06 23:25:34 +02:00
remove fishy reinterpret_cast from buf_page_is_zeroes()
In my micro-benchmarks memcmp(4196) 3 times faster than old implementation. Also, it's generally better to use as less reinterpret_casts<> as possible. buf_is_zeroes(): renamed from buf_page_is_zeroes() and argument changed to span<> for convenience. st_::span<T>::const_iterator: fixed page_zip-verify_checksum(): make argument byte* instead of void*
This commit is contained in:
parent
2bde065525
commit
884d22f288
7 changed files with 43 additions and 39 deletions
|
|
@ -507,7 +507,7 @@ page_zip_calc_checksum(
|
|||
@param data ROW_FORMAT=COMPRESSED page
|
||||
@param size size of the page, in bytes
|
||||
@return whether the stored checksum matches innodb_checksum_algorithm */
|
||||
bool page_zip_verify_checksum(const void *data, size_t size);
|
||||
bool page_zip_verify_checksum(const byte *data, size_t size);
|
||||
|
||||
#ifndef UNIV_INNOCHECKSUM
|
||||
/**********************************************************************//**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue