diff options
author | CNugteren <web@cedricnugteren.nl> | 2015-10-28 21:19:59 +0100 |
---|---|---|
committer | CNugteren <web@cedricnugteren.nl> | 2015-10-28 21:19:59 +0100 |
commit | c0d469718afef353ce7e091c1bfd6fc3d210a240 (patch) | |
tree | a258298200f211ef40bc09718d81611f84fe0867 /src/tuning/xgemv.cc | |
parent | bb4e78f7371f6c1ab56692d25ea06ae32634d8c1 (diff) |
Now sets local memory size in xgemv tuner properly
Diffstat (limited to 'src/tuning/xgemv.cc')
-rw-r--r-- | src/tuning/xgemv.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/tuning/xgemv.cc b/src/tuning/xgemv.cc index 675f0bf9..60c73d76 100644 --- a/src/tuning/xgemv.cc +++ b/src/tuning/xgemv.cc @@ -72,7 +72,10 @@ class TuneXgemv { tuner.AddConstraint(id, MultipleOfX, {"WPT"+std::to_string(V), "VW"+std::to_string(V)}); } } - static void SetLocalMemorySize(cltune::Tuner &, const size_t, const Arguments<T> &) { } + static void SetLocalMemorySize(cltune::Tuner &tuner, const size_t id, const Arguments<T> &args) { + auto LocalMemorySize = [args] (std::vector<size_t> v) { return v[0]*GetBytes(args.precision); }; + tuner.SetLocalMemoryUsage(id, LocalMemorySize, {"WGS"+std::to_string(V)}); + } // Sets the base thread configuration static std::vector<size_t> GlobalSize(const Arguments<T> &args) { return {args.m}; } |