2 Replies Latest reply on Aug 10, 2009 12:27 AM by Emilia123

    Diasble and Enable Cores


      Hi All,
      I want to run my application on ma system with different number of cores enabled and benchmark it. I've a 4-core AMD Opteron. I wanna run it on a single core, then on a two core and finally with all the four cores enabled..... Thx

        • Diasble and Enable Cores

          Hi --

          You mentioned in another post that you are using Windows (version not
          specified) and are using OpenMP with Visual Studio.

          The safest way to do a scalability experiment is to change
          the number of OpenMP threads. You'll need to set an environment
          variable in the "Advanced system settings" of the "System" control
          panel. Create a new (user or system) environment variable named
          "OMP_NUM_THREADS" and give it a value (1, 2, 3, or 4).

          Now, here's a little gotcha. The CodeAnalyst GUI only picks up the
          environment variables when CodeAnalyst launches. So, when you go to
          change the number of threads, you will need to exit CodeAnalyst,
          change the value of the OMP_NUM_THREADS environment variable, then
          launch CodeAnalyst again.

          As a side note, CodeAnalyst is able to launch a BAT file that sets
          environment variables and runs a workload. However, thread profiling
          tracks the process running the BAT file (cmd.exe) instead of the workload.
          Thus, the resulting thread chart is uninteresting. :-( I've passed this usage
          issue on to the team.

          Windows does provide a way to change the number of cores, but I do not
          recommend fiddling with this setting. In all cases,
          this requires a reboot and the confidence to change a system setting.
          The method is different on different versions of Windows. On Vista, there
          is a control panel which controls boot options. Follow Control Panel >
          Administrative Tools > System Configuration and select the Boot tab in
          the System Configuration dialog box. Click the Advanced options... button
          and you will find a way to set the number of processors. On Windows XP,
          you can run the System Configuration Utility by choosing Run... from the
          Start menu and opening msconfig. Select the BOOT.INI tab and click the
          Advanced Options... button. You will see an option to set /NUMPROC, which
          is the number of processors at boot time. In any case, you'll need to
          reboot. If you choose this method, you'll have to accept sole responsibility
          for the results!

          Take care -- pj