#include "univ.i"Go to the source code of this file.
Functions | |
| UNIV_INLINE ib_uint64_t | ut_ull_create (ulint high, ulint low) __attribute__((const )) |
| UNIV_INLINE ib_uint64_t | ut_uint64_align_down (ib_uint64_t n, ulint align_no) |
| UNIV_INLINE ib_uint64_t | ut_uint64_align_up (ib_uint64_t n, ulint align_no) |
| UNIV_INLINE void * | ut_align (const void *ptr, ulint align_no) |
| UNIV_INLINE void * | ut_align_down (const void *ptr, ulint align_no) __attribute__((const )) |
| UNIV_INLINE ulint | ut_align_offset (const void *ptr, ulint align_no) __attribute__((const )) |
| UNIV_INLINE ibool | ut_bit_get_nth (ulint a, ulint n) |
| UNIV_INLINE ulint | ut_bit_set_nth (ulint a, ulint n, ibool val) |
| UNIV_INLINE void* ut_align | ( | const void * | ptr, |
| ulint | align_no | ||
| ) |
The following function rounds up a pointer to the nearest aligned address.
| ptr | in: pointer |
Referenced by buf_LRU_file_dump(), buf_LRU_file_restore(), fil_create_new_single_table_tablespace(), fil_extend_space_to_desired_size(), fil_open_single_table_tablespace(), fil_read_flushed_lsn_and_arch_log_no(), fil_reset_too_high_lsns(), log_group_init(), log_init(), os_aio_simulated_handle(), os_file_set_size(), recv_recovery_from_checkpoint_start_func(), recv_sys_init(), and trx_sys_doublewrite_init_or_restore_pages().
| UNIV_INLINE void* ut_align_down | ( | const void * | ptr, |
| ulint | align_no | ||
| ) | const |
The following function rounds down a pointer to the nearest aligned address.
| ptr | in: pointer |
| align_no | in: align by this number |
Referenced by log_close(), and log_write_low().
| UNIV_INLINE ulint ut_align_offset | ( | const void * | ptr, |
| ulint | align_no | ||
| ) | const |
The following function computes the offset of a pointer from the nearest aligned address.
| ptr | in: pointer |
| align_no | in: align by this number |
| UNIV_INLINE ibool ut_bit_get_nth | ( | ulint | a, |
| ulint | n | ||
| ) |
Gets the nth bit of a ulint.
| a | in: ulint |
| UNIV_INLINE ulint ut_bit_set_nth | ( | ulint | a, |
| ulint | n, | ||
| ibool | val | ||
| ) |
Sets the nth bit of a ulint.
| a | in: ulint |
| n | in: nth bit requested |
| UNIV_INLINE ib_uint64_t ut_uint64_align_down | ( | ib_uint64_t | n, |
| ulint | align_no | ||
| ) |
Rounds a 64-bit integer downward to a multiple of a power of 2.
| n | in: number to be rounded |
Referenced by log_write_up_to(), and recv_recovery_from_checkpoint_start_func().
| UNIV_INLINE ib_uint64_t ut_uint64_align_up | ( | ib_uint64_t | n, |
| ulint | align_no | ||
| ) |
Rounds ib_uint64_t upward to a multiple of a power of 2.
| n | in: number to be rounded |
Referenced by dict_boot(), recv_reset_logs(), and trx_sys_init_at_db_start().
| UNIV_INLINE ib_uint64_t ut_ull_create | ( | ulint | high, |
| ulint | low | ||
| ) | const |
Creates a 64-bit integer out of two 32-bit integers.
| high | in: high-order 32 bits |
| low | in: low-order 32 bits |