Lines Matching refs:allocatorId
25 C2Allocator* createAllocator(C2Allocator::id_t allocatorId) { in createAllocator() argument
26 ALOGV("%s(allocatorId=%d)", __func__, allocatorId); in createAllocator()
31 ALOGD("%s(): Create C2Allocator (id=%u) from VendorAllocatorLoader", __func__, allocatorId); in createAllocator()
32 return sAllocatorLoader->createAllocator(allocatorId); in createAllocator()
35 ALOGI("%s(): Fallback to create C2AllocatorGralloc(id=%u)", __func__, allocatorId); in createAllocator()
36 return new C2AllocatorGralloc(allocatorId, true); in createAllocator()
39 std::shared_ptr<C2Allocator> fetchAllocator(C2Allocator::id_t allocatorId) { in fetchAllocator() argument
40 ALOGV("%s(allocatorId=%d)", __func__, allocatorId); in fetchAllocator()
47 auto iter = sCacheAllocators.find(allocatorId); in fetchAllocator()
55 allocator.reset(createAllocator(allocatorId)); in fetchAllocator()
56 sCacheAllocators[allocatorId] = allocator; in fetchAllocator()
60 C2BlockPool* createBlockPool(C2Allocator::id_t allocatorId, C2BlockPool::local_id_t poolId) { in createBlockPool() argument
61 ALOGV("%s(allocatorId=%d, poolId=%" PRIu64 ")", __func__, allocatorId, poolId); in createBlockPool()
63 std::shared_ptr<C2Allocator> allocator = fetchAllocator(allocatorId); in createBlockPool()
65 ALOGE("%s(): Failed to create allocator id=%u", __func__, allocatorId); in createBlockPool()
69 switch (allocatorId) { in createBlockPool()
83 ALOGE("%s(): Unknown allocator id=%u", __func__, allocatorId); in createBlockPool()
90 extern "C" ::C2BlockPool* CreateBlockPool(::C2Allocator::id_t allocatorId, in CreateBlockPool() argument
92 ALOGV("%s(allocatorId=%d, poolId=%" PRIu64 ")", __func__, allocatorId, poolId); in CreateBlockPool()
93 return ::android::createBlockPool(allocatorId, poolId); in CreateBlockPool()
96 extern "C" ::C2Allocator* CreateAllocator(::C2Allocator::id_t allocatorId, ::c2_status_t* status) { in CreateAllocator() argument
97 ALOGV("%s(allocatorId=%d)", __func__, allocatorId); in CreateAllocator()
99 ::C2Allocator* res = ::android::createAllocator(allocatorId); in CreateAllocator()