- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The generated result is the following:
This is a report on the same run/data as the GUI, but the GUI is clearly doing something extra to get its numbers.
Humphrey
The run command the GUI is using is as follows:
vtune -collect hotspots -knob sampling-mode=hw -knob enable-stack-collection=true -knob stack-size=4096 --app-working-dir=/home/hb478/repos/are-we-fast-yet/benchmarks/Java/src -- atest_graalvm_home/bin/java -Djdk.graal.LIRGTSlowDown=false -Djdk.graal.GTMarkBasicBlocks=true -Djdk.graal.LIRBlockSlowdownFileName=BlockSlowdown1.json -XX:+UseJVMCICompiler -XX:+UseJVMCINativeLibrary -XX:-TieredCompilation '-XX:CompileCommand=dontinline,*::*' -Djdk.graal.TrivialInliningSize=0 -XX:-BackgroundCompilation Harness Queens 500 5000
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you try with 2025.0?
In 2025.0, VTune GUI now includes the ability to generate report commands from the grid views below. For example, you can set grouping and sorting for the data you want to see:
vtune -report exec-query -rep-knob row-by="/Module/Function/FunctionRange/ParentCallStack" -sort-desc "CPU Time:Self" -rep-knob column-by="ViewpointGUIandCLIColumns" -r <result_dir>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for your reply. I was running VTune 2024, but I have since updated it to 2025. I tried rerunning everything, but the command I use still produces different times than the data provided by the GUI.
I tried using the command you provided:
vtune -report exec-query -rep-knob row-by="/Module/Function/FunctionRange/ParentCallStack" -sort-desc "CPU Time:Self" -rep-knob column-by="ViewpointGUIandCLIColumns" -r <result_dir>
his works, but in my case, I want to see the assembler by block for a method and the associated time for each instruction or block—the same data available in the GUI.
Any help with command for this?
Many thanks
Humphrey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Have you checked the assembly code for the source you specify below?
-source-object function=Queens::getRowColumn
I use a similar command line to get assembly information, it looks it works.
vtune -report hotspots -r ./r000hs -source-object function=multiply1 -group-by=basic-block,address -column=block,"CPU Time:Effective Time:Self",Assembly
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for the suggestion. I tried adding source lines to the filter, and as you can see, the source lines don't match the GUI view, and many of them are labeled as [Unknown]:
This is clearly a strange problem because both the GUI and the command-line actions are looking at the same data, but they have different data numbers.
I have since tried playing around with lots of options to get this to work. Strangely, I have found that if I run VTune against a Java program that does not contain extra debug information (so I don't compile with -g), VTune no longer has source code references, but all of the timings for the assembler match on both the command-line version and the GUI.
This seems very strange, but at the moment, that's all I need. However, this does seem to be a bug relating to how VTune connects the assembler/source to the debug information.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You mean the cmd report works when profiling a program w/o debug information, right? Your program is developed by Java? Could you share the compilation command line without debug information? Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So if I compile my program with javac MyProgram.java, no debugging information is included in the .class file, and VTune cannot find the source for the program, whether I use the GUI or command-line report.
However, the command-line assembly report is accurate and matches exactly the same information that the GUI reports.
If I compile my program with javac -g MyProgram.java, which includes debugging information in the .class file, the GUI can see the source and accurately report where CPU time is spent in the assembler. However, the command-line report does not seem to "see" this information, and the timings are inaccurate. This issue is what I'm describing in the first post of this thread.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks reporting the issue, we need to do a deeper investigation. Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I would suggest to try to use ‘source-search-dir’ option in cli and provide path to source files, maybe just cli vtune cannot find path to sources.
https://www.intel.com/content/www/us/en/docs/vtune-profiler/user-guide/2024-1/source-search-dir.html
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page