Skip to content

Instantly share code, notes, and snippets.

public static class CodeTimer
{
public static void Initialize()
{
Process.GetCurrentProcess().PriorityClass = ProcessPriorityClass.High;
Thread.CurrentThread.Priority = ThreadPriority.Highest;
Time("", 1, () => { });
}
public static void Time(string name, int iteration, Action action)
/******************************************************************************
Module: Wintellect.cs
Notices: Copyright (c) 2008-2009 Jeffrey Richter
******************************************************************************/
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Runtime.InteropServices;
@zhangz
zhangz / ExceptionTest.cs
Created June 18, 2011 13:55
ExceptionTest
class ExceptionTest
{
long maxLevel = 20;
static void Main(string[] args)
{
ExceptionTest test = new ExceptionTest();
int count = 10000;
Stopwatch sw = new Stopwatch();
sw.Start();