20 #include <glog/logging.h>
39 <<
" prefetching " <<
get_meta().
name_ <<
" from=" << from <<
", to=" << to;
64 for (uint8_t i = 1; i < level; ++i) {
74 page_range.
begin_ + i * interval,
75 page_range.
begin_ + (i + 1U) * interval);
88 reinterpret_cast<Page**>(&child)));
101 reinterpret_cast<Page**>(&child)));
ErrorCode find_or_read_a_snapshot_page(storage::SnapshotPagePointer page_id, storage::Page **out)
Find the given page in snapshot cache, reading it if not found.
const ArrayMetadata & get_meta() const
ErrorCode install_a_volatile_page(storage::DualPagePointer *pointer, storage::Page **installed_page)
Installs a volatile page to the given dual pointer as a copy of the snapshot page.
Represents a pointer to another page (usually a child page).
Root package of FOEDUS (Fast Optimistic Engine for Data Unification Services).
Represents one thread running on one NUMA core.
uint64_t ArrayOffset
The only key type in array storage.
ThreadId get_thread_id() const
Represents one data page in Array Storage.
ErrorCode get_root_page(thread::Thread *context, bool for_write, ArrayPage **out) __attribute__((always_inline))
ArrayOffset begin_
Inclusive beginning of the offset range.
VolatilePagePointer volatile_pointer_
const DualPagePointer & get_interior_record(uint16_t record) const __attribute__((always_inline))
const ArrayRange & get_array_range() const
ErrorCode prefetch_pages(thread::Thread *context, bool install_volatile, bool cache_snapshot, ArrayOffset from, ArrayOffset to)
defined in array_storage_prefetch.cpp
ArrayOffset end_
Exclusive end of the offset range.
ArrayStorageControlBlock *const control_block_
uint64_t stop()
Take another current time tick.
void prefetch_page_l2(const void *page)
Prefetch a page to L2/L3 cache.
bool overlaps(const ArrayRange &other) const
Returns if there is any overlap with the other range.
SnapshotPagePointer snapshot_pointer_
P * resolve_cast(storage::VolatilePagePointer ptr) const
resolve() plus reinterpret_cast
double elapsed_us() const
Represents an offset range in an array storage.
#define CHECK_ERROR_CODE(x)
This macro calls x and checks its returned error code.
uint16_t get_records_in_leaf() const __attribute__((always_inline))
LookupRouteFinder route_finder_
const uint16_t kInteriorFanout
Max number of entries in an interior page of array storage.
#define ASSERT_ND(x)
A warning-free wrapper macro of assert() that has no performance effect in release mode even when 'x'...
A high-resolution stop watch.
ErrorCode
Enum of error codes defined in error_code.xmacro.
ErrorCode prefetch_pages_recurse(thread::Thread *context, bool install_volatile, bool cache_snapshot, ArrayOffset from, ArrayOffset to, ArrayPage *page)
uint8_t get_level() const