Improved OpenCL profile generation, don't create unnecessary (equal to main profile) profiles.
This commit is contained in:
parent
1d03b942a5
commit
7db7b3727d
6 changed files with 193 additions and 99 deletions
|
@ -49,11 +49,19 @@ public:
|
|||
inline const T &get(const Algorithm &algo, bool strict = false) const { return get(profileName(algo, strict)); }
|
||||
inline void disable(const Algorithm &algo) { m_disabled.insert(algo); }
|
||||
|
||||
inline void move(const char *profile, T &&threads)
|
||||
inline size_t move(const char *profile, T &&threads)
|
||||
{
|
||||
if (has(profile)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
const size_t count = threads.count();
|
||||
|
||||
if (!threads.isEmpty()) {
|
||||
m_profiles.insert({ profile, std::move(threads) });
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
||||
|
||||
const T &get(const String &profileName) const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue