Exemple #1
0
 private static void FreqGet()//频率刷新
 {
     while (go)
     {
         crtFreq = CpuInformation.ClockSpeed();
         Thread.Sleep(freqInterval);
     }
 }
Exemple #2
0
 private void Form1_Load(object sender, EventArgs e)
 {
     string[] ary = { "Name", "NumberOfCores",
                      "NumberOfLogicalProcessors" };
     ary                 = CpuInformation.InfoSearch(ary);
     CPUName.Text        = ary[0];
     coreLabel.Text      = ary[1];
     logicCores          = int.Parse(ary[2]);
     logicCoreLabel.Text = ary[2];
     ProcessCount        = int.Parse(ary[2]);
     MuityTestbtn.Text   = ProcessCount + "线程测试";
     if (int.Parse(ary[2]) / int.Parse(ary[1]) == 1)
     {
         HTTestbtn.Text    = "不支持超线程";
         HTTestbtn.Enabled = false;
     }
     Brush_Ready();
     crtFreq = CpuInformation.ClockSpeed();
     Chart_Draw();
     timer1.Enabled = true;
     td.Start();
     F_version.Text = RuntimeEnvironment.GetSystemVersion().ToString();
 }