diff options
Diffstat (limited to 'gpu')
-rw-r--r-- | gpu/config/gpu_driver_bug_list.cc | 11 | ||||
-rw-r--r-- | gpu/config/gpu_driver_bug_workaround_type.h | 5 |
2 files changed, 16 insertions, 0 deletions
diff --git a/gpu/config/gpu_driver_bug_list.cc b/gpu/config/gpu_driver_bug_list.cc index 68f1b0b..d845c16 100644 --- a/gpu/config/gpu_driver_bug_list.cc +++ b/gpu/config/gpu_driver_bug_list.cc @@ -44,5 +44,16 @@ GpuDriverBugList* GpuDriverBugList::Create() { return list; } +std::string GpuDriverBugWorkaroundTypeToString( + GpuDriverBugWorkaroundType type) { + switch (type) { +#define GPU_OP(type, name) case type: return #name; + GPU_DRIVER_BUG_WORKAROUNDS(GPU_OP) +#undef GPU_OP + default: + return "unknown"; + }; +} + } // namespace gpu diff --git a/gpu/config/gpu_driver_bug_workaround_type.h b/gpu/config/gpu_driver_bug_workaround_type.h index 1d78c97..48a9d6e 100644 --- a/gpu/config/gpu_driver_bug_workaround_type.h +++ b/gpu/config/gpu_driver_bug_workaround_type.h @@ -5,6 +5,8 @@ #ifndef GPU_CONFIG_GPU_DRIVER_BUG_WORKAROUND_TYPE_H_ #define GPU_CONFIG_GPU_DRIVER_BUG_WORKAROUND_TYPE_H_ +#include <string> + #include "gpu/gpu_export.h" #define GPU_DRIVER_BUG_WORKAROUNDS(GPU_OP) \ @@ -65,6 +67,9 @@ enum GPU_EXPORT GpuDriverBugWorkaroundType { NUMBER_OF_GPU_DRIVER_BUG_WORKAROUND_TYPES }; +GPU_EXPORT std::string GpuDriverBugWorkaroundTypeToString( + GpuDriverBugWorkaroundType type); + } // namespace gpu #endif // GPU_CONFIG_GPU_DRIVER_BUG_WORKAROUND_TYPE_H_ |