mgcpp
A C++ Math Library Based on CUDA
eval_cache.hpp
Go to the documentation of this file.
1 #ifndef EVAL_CACHE_HPP
2 #define EVAL_CACHE_HPP
3 
4 #include <functional>
6 
7 namespace mgcpp {
8 
10 
11 void analyze_graph(size_t id, std::function<void()> traverse);
12 
13 static_any evaluate_if_needed(size_t id,
14  bool needs_caching,
15  std::function<void()> traverse,
16  std::function<static_any()> evaluate);
17 
18 } // namespace mgcpp
19 
20 #endif // EVAL_CACHE_HPP
Definition: adapter_base.hpp:12
size_t get_last_run_cache_hits()
static_any evaluate_if_needed(size_t id, bool needs_caching, std::function< void()> traverse, std::function< static_any()> evaluate)
void analyze_graph(size_t id, std::function< void()> traverse)