Repository navigation
[3.0] Exanite's Tracking Issue #2586
Copy link
Copy link
Open
Description
Activity
- converted this from a draft issue
on Jun 6, 2026 From OpenCL/XR PR
Khronos vendor suffixes:
-
Reconsider the usage of KhronosImpliedVendor suffixes- Apparently aliased enums are simply replaced when bindings are updated. This means that users will naturally replace usages of those enums to point to their new versions. Eg: EXT to KHR. Issue is, with implied vendors, this also means that users might accidentally use the wrong enum member since the KHR version of the enum member now takes the name of the old EXT enum member. It might be better to forgo prettiness in favor of correctness here.
-
Also tempted to remove KhronosNonExclusiveVendors since I find this behavior to be more incorrect than it is helpful. It also lets me delete a lot of code (yay!). - History note: I believe both of these behaviors were ported from Silk 2. I ported these two behaviors from the INameTrimmer-based implementation to the current name-affix-based implementation.
Platform interop / additional headers:
Most Khronos APIs have additional headers that interop with platform-specific/other Khronos/other graphics APIs.
OpenXR notably will not work without these additional headers, but generating bindings for these headers requires additional work. See this to understand the planned solution: https://discord.com/channels/521092042781229087/587346162802229298/1529139068288503900- Note down what headers are not being scraped for each Khronos API
- Eg: Vulkan:
- header.h
- Eg: Vulkan:
- Add aforementioned headers to each bindings generation process
- Investigate OpenCL empty enums
- Most of these should be populated once the other headers are included
- cl_command_buffer_info_khr
- cl_command_buffer_properties_khr
- cl_command_buffer_state_khr
- cl_command_buffer_update_type_khr
- cl_command_properties_khr
- cl_compiler_mode_altera
- cl_d3d10_device_set_khr
- cl_d3d10_device_source_khr
- cl_d3d11_device_set_khr
- cl_d3d11_device_source_khr
- cl_dx9_device_set_intel
- cl_dx9_device_source_intel
- cl_gl_context_info
- cl_gl_object_type
- cl_gl_texture_info
- cl_layer_properties
- cl_media_adapter_set_khr
- cl_media_adapter_type_khr
- cl_mutable_command_info_khr
- cl_mutable_dispatch_asserts_khr (Flags so by default 1 None member)
- cl_mutable_dispatch_fields_khr (Flags)
- cl_platform_command_buffer_capabilities_khr (flags)
- cl_queue_properties_khr
- cl_semaphore_reimport_properties_khr
- cl_svm_alloc_properties_khr
- cl_svm_capabilities_khr (Flags)
- cl_svm_free_flags_khr (Flags)
- cl_svm_free_properties_khr
- cl_svm_pointer_info_khr
- cl_va_api_device_set_intel
- cl_va_api_device_source_intel
- Also investigate any other empty enums, if there are any. Make sure to check for [Flags] enums as well, since these will not be empty and instead have a single
Nonemember.
Khronos bindings improvements:
- Unconditional usage of
clGetExtensionFunctionAddressForPlatformlimits our OpenCL bindings to OpenCL v1.2.- Don't fix directly. This will be fixed once we track which functions can be loaded using each approach.
- See: https://discord.com/channels/521092042781229087/587346162802229298/1532127670303854632
- See: Vulkan instance functions exposed by device extensions fail to be loaded #2547
- OpenXR/IdentifiedSharedPrefixes: Not sure why
XrPerfSettingsNotificationLevelEXTneeds a prefix override for proper shared prefix identification. I know the type name affects it, but I thought that was a fallback case.- Same issue with
XrStructureTypeandXrSceneMarkerQRCodeSymbolTypeMSFT
- Same issue with
- OpenXR: Consider remapping vector/box/extent/etc types
- See my list here: [3.0] Add OpenCL and OpenXR bindings #2590 (comment)
- Also do the same for the other APIs where relevant
- Decide what to do with names in the format:
1St,2Nd
Config/DI/registration system:
- Ensure mod order for all jobs are consistent
Remaining bindings I plan to work on:
MoltenVK would just be a native build. VMA is not on the tracking issue, but we already discussed that we want this to be in Silk 3 (and I want it for my personal projects as well).
- Generate initial bindings
- Assimp
- SPIRV Reflect
- SPIRV Cross
- SPIRV Tools
- Shaderc
- VMA
- Do a polish pass over the bindings
- Assimp
- SPIRV Reflect
- SPIRV Cross
- SPIRV Tools
- Shaderc
- VMA
- Native builds
- Assimp
- SPIRV Reflect
- SPIRV Cross
- SPIRV Tools
- Shaderc
- VMA
- MoltenVK
- Update docs
- Any mod changes
- Add new bindings to changelog
- Rebase onto
develop/3.0 - Generate using Windows for consistency
- This must include regenerating every existing binding
-
- added a commit that references this issue
on Sep 8, 2026 - added a commit that references this issue
on Oct 10, 2026
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
- StatusShow more project fieldsIn Progress
Exanite's Tracking Issue
This tracks a bunch of miscellaneous tasks that I accumulated while working on Silk 3.
I'm open for anyone to work on these tasks, but please discuss with me in the Silk Discord first.
A task being here on this tracker does not mean it is guaranteed to be completed.
This tracker's primary goal is so that we do not accidentally forget about tasks and that any tasks not completed are intentionally left uncompleted.
In-progress
Tasks in progress will be moved to the corresponding pull request.
Uncategorized
This section contains informal reports, suggestions, or complaints about Silk 3.
I'm logging them here so they don't get forgotten about until I either open a formal issue or address them.
From Aqua:
file libSDL3.sosayslibSDL3.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, with debug_info, not stripped, so definitely because the binary was not strippedFrom Ethereal:
From Nolram (https://discord.com/channels/521092042781229087/607634593201520651/1524213012402147348):
From dfkeenan:
From Curin:
From me (Exanite):
GetPlatformIDs,GetDeviceIDs, and likely more functions do not have singularGetPlatformIDequivalents. This should be handled by our function transformer so I'm guessing the XML metadata is missing. See [3.0] Add OpenCL and OpenXR bindings #2590 (comment).GL<T>whereTis anINativeContextto remove one level ofcallvirt: https://discord.com/channels/521092042781229087/587346162802229298/1541090497185980478From me (Exanite), as part of my OpenCL example program:
Original comments:
Silk.NET/examples/CSharp/OpenCL/Tutorial001.SimpleKernel/Program.cs
Lines 75 to 80 in 021738d
LoadFunction(functionName, libraryNameHint), but I liked how Silk 2 only required the function name.High priority
Generator:
ExtractEnumConstantsdoes not preserve attributes placed on extracted constants (needs verification).Bindings usage:
InlineArrayN<T>types provided by .NET? Should we use them?channels/521092042781229087/1514735149915439274/1519099432442794150
nullptrconstant does not work. It fails to resolve to anything.RegisterHookin both Vk (defined in a manual file) and Vk.DllImport (defined in a generated file).KhronosNonExclusiveVendorcan identify. Eg: For OpenGL, this should be onlyARB.nullptr. Seems like a nice QOL feature.Enums and other integral typedefs:
These have been proving to be consistently annoying to work with...
Vulkan and OpenXR have some special handling so this problem is less problematic, but still exists.
void DrawElements(uint mode, uint count, uint type, void* indices);uint.uintis used instead ofMaybeBool<uint>.Documentation:
nullptr)Maintenance:
<auto-generated/>comment to start of each generated file. This has the effect of disabling IDE/linter/etc checks, which means less noise and performance cost of working in the Silk repo.Medium priority
Bindings:
CLongwhere possible in the bindings.Constant<CLong, EnumHere>, and theoretically it should work.IsProbablyABitmaskfunction based on BuildTool's IsProbablyABitmask for identifying flags enumsQuality:
Sdl.PropGpuDeviceCreateDebugmodeBooleanare technically correct (native name isSDL_PROP_GPU_DEVICE_CREATE_DEBUGMODE_BOOLEAN, soDebugmodeis "one" word), but we could have an audit tool that checks for these non-ideal cases so we can add manual overrides. Worth the effort? Probably not unless we care about perfecting the bindings.Maintenance:
Low priority
CI:
Maintenance:
High level utilities:
IDE / Metadata:
NativeNamefor resolving API profilesNativeNameattributes.StripAttributestoCleanupAttributesand adding an option in its config to optimizeNativeNameattributes.Completed tasks and canceled tasks
Completed
After maintaining this section for a bit, I'll only list tasks not obviously related to a PR. Otherwise, it means that I'm tracking the same task in two places, which can get confusing.
Completed during #2588:
develop/3.0. Might be related to the error I saw half a year ago. If so, likely can be fixed by simply updating CSharpier. CSharpier has updated their Roslyn package since then.Completed during #2591:
--onlyoption from Curin's branch so I don't need to specify--skipfor all but one jobCompleted or planned to be completed during #2590 (not yet merged):
.gen.cs.csfiles during theGenerated Bindings OutputsectionalSourceRewindvandalSourceRewind. ThedinRewindcan be mistaken as a data type suffix, so we add it to theEndingsNotToTrimregex. However, thedvinRewindvalso has the same problem.WordsNotToTrimIntothanEndingsNotToTrim.AddVTablesin the mod MD docs.Completed in dotnet/ClangSharp#699
SDL_MAX_SINT64generation on Linuxpublic const nint SDL_MAX_SINT64 = unchecked(0x7FFFFFFFFFFFFFFF);does not compileCompleted outside of a PR:
DrawElements/etc, check if the pointer to 0 issue present in Silk 2 still exists in Silk 3Not doing
For transparency and for reference, I'll move any tasks I don't plan on doing here.
Figure out how to handle CLA properly. Currently native builds will block CLA due to the use of a bot account.Differentiate between smoke tests and actual tutorials/examples. I would categorize the current SDL/OpenAL "tutorials" in Silk 3 to be smoke tests since they really shouldn't be referenced as sources of best practices.