MCPcopy Create free account
hub / github.com/apache/impala / CreatePageLoop

Method CreatePageLoop

be/src/runtime/bufferpool/buffer-pool-test.cc:1166–1180  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1164}
1165
1166void BufferPoolTest::CreatePageLoop(BufferPool* pool, TmpFileGroup* file_group,
1167 ReservationTracker* parent_tracker, int num_ops) {
1168 BufferPool::ClientHandle client;
1169 ASSERT_OK(pool->RegisterClient("test client", file_group, parent_tracker, NULL,
1170 TEST_BUFFER_LEN, NewProfile(), &client));
1171 ASSERT_TRUE(client.IncreaseReservation(TEST_BUFFER_LEN));
1172 for (int i = 0; i < num_ops; ++i) {
1173 BufferPool::PageHandle handle;
1174 ASSERT_OK(pool->CreatePage(&client, TEST_BUFFER_LEN, &handle));
1175 pool->Unpin(&client, &handle);
1176 ASSERT_OK(pool->Pin(&client, &handle));
1177 pool->DestroyPage(&client, &handle);
1178 }
1179 pool->DeregisterClient(&client);
1180}
1181
1182/// Test that DCHECK fires when trying to unpin a page with spilling disabled.
1183TEST_F(BufferPoolTest, SpillingDisabledDcheck) {

Callers

nothing calls this directly

Calls 7

CreatePageMethod · 0.80
DestroyPageMethod · 0.80
DeregisterClientMethod · 0.80
RegisterClientMethod · 0.45
IncreaseReservationMethod · 0.45
UnpinMethod · 0.45
PinMethod · 0.45

Tested by

no test coverage detected