MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / find

Method find

src/backend/common/FFTPlanCache.hpp:45–56  ·  view source on GitHub ↗

iterates through plan cache from front to back of the cache(queue) A valid shared_ptr of the plan in the cache is returned if found, and empty share_ptr otherwise.

Source from the content-addressed store, hash-verified

43 // A valid shared_ptr of the plan in the cache is returned
44 // if found, and empty share_ptr otherwise.
45 plan_t find(const std::string& key) const {
46 std::shared_ptr<P> res;
47
48 for (unsigned i = 0; i < mCache.size(); ++i) {
49 if (key == mCache[i].first) {
50 res = mCache[i].second;
51 break;
52 }
53 }
54
55 return res;
56 }
57
58 // pushes plan to the front of cache(queue)
59 void push(const std::string key, plan_t plan) {

Callers 15

fft.cppFile · 0.80
allocated_fnFunction · 0.80
user_lock_fnFunction · 0.80
is_user_locked_fnFunction · 0.80
unlock_fnFunction · 0.80
replace_allFunction · 0.80
loadImageTestFunction · 0.80
replace_allFunction · 0.80
platformMapFunction · 0.80
findPlanFunction · 0.80
getKernelFunction · 0.80
findPlanFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected