Add types for fields from cl_motion_estimation_desc_intel#1261
Add types for fields from cl_motion_estimation_desc_intel#1261SunSerega wants to merge 1 commit intoKhronosGroup:mainfrom
cl_motion_estimation_desc_intel#1261Conversation
Separated part of this to KhronosGroup#1261
Separated part of this to KhronosGroup#1261
I'm a little nervous about these changes. We probably should have done this from day one.... but we didn't.... and now this extension is more or less in maintenance (we don't support it on our latest GPUs), so I'm hesitant to make any changes unless we absolutely need to. Is there something fundamentally broken using I do see that the values assigned to these |
This makes a big difference in high-level languages. Besides the default; being unable to set values to the wrong field - it allows generating a lot of convenient methods and operators. But the main thing that's bugging me is: That's a human-readable construct - but not a machine-readable one. If you think this is such an old extension that it should be ignored as a whole - we could mark that instead. I think it's less junky than what is currently in the Personally, I think it's still the best course of action to create the types in XML and not touch the extension specs. They would be describing the exact same memory layout, but XML would be doing it in a way that I argue is better for XML consumers. |
The relevant enum values are already grouped in the
<require>tags.I think it's better to allocate separate types for each such group, so it's possible for higher-lvl (than C) languages to enforce assigning the right values to fields of this struct.
Creating as a draft because the spec also needs to reflect this.
@bashbaug, this was a part of #926; what do you generally think about this change?
Any suggestions on how spec text should be handled?
I think it's not worth incrementing the version here since it wouldn't change the implementations in any way - it's purely an interface change.
P.S. If we agree on this,
cl_mem_ext_host_ptrwould also need a similar change. I'll hold off creating that PR for now.