public static void ExecuteAll()
{
foreach (int i in new[] { 1, 2, 6 })
{
int i1 = i;
RunParallel(() => TestAlloc(string.Format("Alloc with {0} threads", i1)), i1);
}
TestIncrement();
TestUncontented();
TestInterlocked("Uncontended interlocked");
RunParallel(() => TestInterlocked(string.Format("Interlocked with {0} threads", 2)), 2);
foreach ( int i in new[] { 1, 2, 6})
{
int i1 = i;
RunParallel( () => TestInterlocked( string.Format( "Interlocked with {0} threads", i1 ) ), i1 );
}
RunParallel(TestContendedEnter, 2);
TestSetEvent();
TestWaitEvent();
TestCreateEvent();
TestSleep0();
}