4 ms·
There is a performance penalty when accessing APIs over WinMD and that is acceptable when you're only using them sparingly. I'd be curious how using Win32 APIs
by jarjoura 6y ago
There is a performance penalty when accessing APIs over WinMD and that is acceptable when you're only using them sparingly.
I'd be curious how using Win32 APIs over WinMD performs instead of using PInvoke or FFI.
Edit: Here is the actual project if anyone is interested in following along. https://github.com/microsoft/win32metadata/ https://github.com/microsoft/win32metadata/
- WalterGR 6y ago> There is a performance penalty when accessing APIs over WinMD Specifically when using WinMD? Why? Or do you mean vs. calling the APIs directly via C code, or vs. using in-language techniques such as P/Invoke?
- int_19h 6y agoIt only uses WinMD as the format for metadata input for code generation. The output for C# is still a bunch of P/Invoke declarations (using Roslyn source generators). By the way, .NET is also retiring the ability to use WinMD directly via runtime projection, in favor of code generation: https://github.com/microsoft/CsWinRT https://github.com/microsoft/CsWinRT