mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 00:58:05 +02:00
clover: Move platform extensions definitions to clover/platform.cpp
Reviewed-by: Francisco Jerez <currojerez@riseup.net> Reviewed-by: Aaron Watry <awatry@gmail.com>
This commit is contained in:
parent
b033620abf
commit
8f9b4a2be6
3 changed files with 9 additions and 2 deletions
|
|
@ -51,7 +51,7 @@ clover::GetPlatformInfo(cl_platform_id d_platform, cl_platform_info param,
|
|||
size_t size, void *r_buf, size_t *r_size) try {
|
||||
property_buffer buf { r_buf, size, r_size };
|
||||
|
||||
obj(d_platform);
|
||||
auto &platform = obj(d_platform);
|
||||
|
||||
switch (param) {
|
||||
case CL_PLATFORM_PROFILE:
|
||||
|
|
@ -74,7 +74,7 @@ clover::GetPlatformInfo(cl_platform_id d_platform, cl_platform_info param,
|
|||
break;
|
||||
|
||||
case CL_PLATFORM_EXTENSIONS:
|
||||
buf.as_string() = "cl_khr_icd";
|
||||
buf.as_string() = platform.supported_extensions();
|
||||
break;
|
||||
|
||||
case CL_PLATFORM_ICD_SUFFIX_KHR:
|
||||
|
|
|
|||
|
|
@ -39,3 +39,8 @@ platform::platform() : adaptor_range(evals(), devs) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
std::string
|
||||
platform::supported_extensions() const {
|
||||
return "cl_khr_icd";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,6 +40,8 @@ namespace clover {
|
|||
platform &
|
||||
operator=(const platform &platform) = delete;
|
||||
|
||||
std::string supported_extensions() const;
|
||||
|
||||
protected:
|
||||
std::vector<intrusive_ref<device>> devs;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue