We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2785

Summary: Enable Win32 threading backend on WinRT, if and when underlying APIs are available
Product: SDL Reporter: David Ludwig <dll>
Component: threadAssignee: David Ludwig <dll>
Status: RESOLVED FIXED QA Contact: David Ludwig <dll>
Severity: normal    
Priority: P2 CC: dll
Version: HG 2.0   
Hardware: x86   
OS: Other   

Description David Ludwig 2014-11-15 17:12:51 UTC
Microsoft has enabled several, previously-unavailable thread-creation and management APIs for recent WinRT apis, specifically for Windows 8.1 and Windows Phone 8.1.  These APIs had previously been made private (for WinRT apps).

Such API calls include, potentially among others:
- CreateThread (docs at http://msdn.microsoft.com/en-US/library/windows/apps/ms682453.aspx )
- SetThreadPriority (this appears to not be functional on Windows Phone 8.1, however, according to MSDN docs at http://msdn.microsoft.com/en-US/library/windows/apps/ms686277.aspx )

Such a move should reduce the amount of custom code needed to get the WinRT port of SDL running, and in some cases, may enable thread-priority changing, which was previously unavailable in SDL/WinRT.

Be sure to check and see if these API additions require particular versions of MSVC.  For example, the Win32 Sleep function was also made available for Windows 8.1 and Windows Phone 8.1, but only as of Visual C++ Update 4.
Comment 1 David Ludwig 2015-12-25 09:15:10 UTC
Fixed via https://hg.libsdl.org/SDL/rev/84285c1d8ca4