Skip to content

Commit

Permalink
Enable offline cache by default on Vulkan and OpenGL
Browse files Browse the repository at this point in the history
  • Loading branch information
PGZXB committed Oct 6, 2022
1 parent ed12813 commit b41b6c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions taichi/runtime/program_impls/opengl/opengl_program.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,7 @@ const std::unique_ptr<gfx::CacheManager>
using Mgr = gfx::CacheManager;
Mgr::Params params;
params.arch = config->arch;
params.mode =
offline_cache::enabled_wip_offline_cache(config->offline_cache)
? Mgr::MemAndDiskCache
: Mgr::MemCache;
params.mode = config->offline_cache ? Mgr::MemAndDiskCache : Mgr::MemCache;
params.cache_path = config->offline_cache_file_path;
params.runtime = runtime_.get();
params.target_device = std::move(target_device);
Expand Down
5 changes: 1 addition & 4 deletions taichi/runtime/program_impls/vulkan/vulkan_program.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,7 @@ const std::unique_ptr<gfx::CacheManager>
using Mgr = gfx::CacheManager;
Mgr::Params params;
params.arch = config->arch;
params.mode =
offline_cache::enabled_wip_offline_cache(config->offline_cache)
? Mgr::MemAndDiskCache
: Mgr::MemCache;
params.mode = config->offline_cache ? Mgr::MemAndDiskCache : Mgr::MemCache;
params.cache_path = config->offline_cache_file_path;
params.runtime = vulkan_runtime_.get();
params.target_device = std::move(target_device);
Expand Down

0 comments on commit b41b6c9

Please sign in to comment.