Thread overview
[D-runtime] Thread.yield() and SwitchToThread() on Windows
May 04, 2012
Sean Kelly
May 05, 2012
Jonathan M Davis
May 04, 2012
Hi,

Is there any particular reason Thread.yield() does not use SwitchToThread()
on Windows?

Regards,
Alex


May 04, 2012
On May 4, 2012, at 1:34 AM, Alex Rønne Petersen wrote:

> Hi,
> 
> Is there any particular reason Thread.yield() does not use SwitchToThread() on Windows?

Historical reasons I'd guess.  This routine is only available on WinXP and later.

_______________________________________________
D-runtime mailing list
D-runtime@puremagic.com
http://lists.puremagic.com/mailman/listinfo/d-runtime

May 05, 2012
Do we support anything older than XP still?

If we don't, we should use this function.

Regards,
Alex

On Fri, May 4, 2012 at 8:59 PM, Sean Kelly <sean@invisibleduck.org> wrote:

> On May 4, 2012, at 1:34 AM, Alex Rønne Petersen wrote:
>
> > Hi,
> >
> > Is there any particular reason Thread.yield() does not use
> SwitchToThread() on Windows?
>
> Historical reasons I'd guess.  This routine is only available on WinXP and later.
>
> _______________________________________________
> D-runtime mailing list
> D-runtime@puremagic.com
> http://lists.puremagic.com/mailman/listinfo/d-runtime
>


May 04, 2012
On Saturday, May 05, 2012 02:09:20 Alex Rønne Petersen wrote:
> Do we support anything older than XP still?
> 
> If we don't, we should use this function.

We don't have an official version of Windows that we support, but at present, Phobos works with Win2K, and Walter tends to be of the opinion that we should support everything. However, we _did_ recently remov support for Windows 9x, because it had to be handled specially and made maintenance harder. But the same argument does not really exist for Win2k, and actually, this is the first time that I've ever heard of a function which was added in XP. All the stuff that I've seen seems to have been added in either Win2K or Vista.

I don't know how reasonable it is or isn't to drop support for Win2K, but we do effectively support it right now even if we don't have an official policy on which versions of Windows we support.

- Jonathan M Davis
_______________________________________________
D-runtime mailing list
D-runtime@puremagic.com
http://lists.puremagic.com/mailman/listinfo/d-runtime