3

I have a C++ application, running on windows10(AMD Ryzon processor), which I'm in the process of benchmarking and optimizing. Can anyone recommend a performance profiling tool under the AMD Ryzen processor?

tadman
  • 208,517
  • 23
  • 234
  • 262
Mariya
  • 41
  • 6
  • One problem with Windows is that it runs multiple threads, and tasks. Your program may run a couple of iterations, then another program runs for a bit, then another and so on. For a quality performance checking, you'll need to figure out how to get around this. – Thomas Matthews Jun 10 '20 at 15:21
  • Can you run it under a debugger or IDE? Then try [*this*](https://stackoverflow.com/a/378024/23771). – Mike Dunlavey Jun 11 '20 at 12:20
  • @ThomasMatthews It's worse than that due to CPU turbo/throttling, thermal load, and other factors, including ambient room temperature. – tadman Jun 12 '20 at 00:51

1 Answers1

3

There are some profilers from AMD, for example

https://developer.amd.com/amd-uprof/

AMD uProf supports the 64-bit version of the following Operating Systems: ... Microsoft Windows 10 (up to May 2019 Update)

AMD uProf supports following application environment: Languages: C, C++, ...

AMD uProf profiler follows a statistical sampling-based approach to collect profile data to identify the performance bottlenecks in the application. The profile data collection can be triggered by – 6OS timer, core PMC events and IBS. AMD uProf offers user friendly UI to view and analyze the profile data thereby helps to optimize wide variety of applications, drivers, game engines etc.

So, it supports hardware and software events and can do sampling profiling.

There was also AMD CodeAnalyst / CodeXL profilers, but it can be not easy to download it now https://community.amd.com/thread/159836.

Intel VTune commercial profiler may work on AMD chips too, but without full support of hardware events. Software events should work.

osgx
  • 90,338
  • 53
  • 357
  • 513
  • tthank you for answer actually it is not the tool that i look for , i wanna a tool that display the execution time for each function in the code . – Mariya Jun 16 '20 at 08:29
  • Aisha, profiling is usually done as periodic sampling (1000 times per second) and recording where the thread (program) was executed at moment of that sample. To record all execution times for every function every call and return should be instrumented with additional code to record time of entry and exit. This will have huge overhead. Some tools like Intel PIN or valgrind may be used to try to build such measuring for existing code (dynamic recompilation); and compiler instrumentation is needed when code can be recompiled. What is your c++ compiler? (Gcc -pg / gprof with different _mcount?) – osgx Jun 16 '20 at 11:27