cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

uforob
Journeyman III

Using AMD APP profiler on Linux, problem with input file

I tried to profile my application with "sprofile" program but in this way my application doesn't find an input file. My application named "shallow_water" is in "home/roberto/shallow_water_old_old_version/shallow_water" folder where there is also the input file.

I tried

./sprofile -o "/home/roberto/output.csv" "/home/roberto/shallow_water_old_old_version/shallow_water/shallow_water"

and then

./sprofile -o "/home/roberto/output.csv" -w "/home/roberto/shallow_water_old_old_version/shallow_water" "/home/roberto/shallow_water_old_old_version/shallow_water/shallow_water"

0 Likes
1 Solution
nou
Exemplar

do you open with relative address? because most likely you just need chenge current working directory. so run sprofile with absolute path and you program with relative.

View solution in original post

0 Likes
11 Replies
nou
Exemplar

do you open with relative address? because most likely you just need chenge current working directory. so run sprofile with absolute path and you program with relative.

0 Likes
uforob
Journeyman III

I ran from sprofile folder, as you can see  I wrote ./sprofile and then I tried setting working directory with -w.

I tried now to run sprofile with absolute path in the folder of my application and all worked but I don't understand why the second way in the first message is wrong, in that I set working directory with -w.

0 Likes

It's not really necessary to run sprofile from it's own folder. Does it work if you run sprofile from the folder you usually start your app in?

e.g.: /opt/AMDAPP/tools/AMDAPPProfiler-2.3/x86_64/sprofile -o "/home/roberto/output.csv" ./shallow_water

Thank you, this also works, the way I said that works n my previous message is identical but I used absolute path for the application, too. I didn't think I was already in the folder ...

0 Likes

Oh, true. Must have somehow skipped that part of your post on reading. Sorry for the spam.

0 Likes

I have another problem now, I don't understand how to use -k and -c parameters: using -k all I don't know where output files should be and I don't know how counterfile has to be.

0 Likes

kernel files(cl, il, isa) should go to the same path as your perf counter output file. If no output file is specified, they should go to home directory.

-c takes a path as input

You can create your counter file anywhere you want.

For example:

sprofile -k all -c ~/mycounters.txt myApp appArgs

0 Likes

What have I to write in mycounters.txt? what structure?

0 Likes

The format of the counter file is one counter name per line. An example of the contents of this file is given below.

Wavefronts

ALUInsts

FetchInsts

WriteInsts

ALUBusy

ALUFetchRatio

ALUPacking

FetchSize

CacheHit

FetchUnitBusy

FetchUnitStalled

WriteUnitStalled

FastPath

CompletePath

PathUtilization

LDSFetchInsts

LDSWriteInsts

LDSBankConflict

0 Likes

maybe bug in profiler

0 Likes

Thanks for reporting this issue. We confirmed -w switch doesn't work for Linux version of APP Profiler. It will be fixed in the next release. To workaround the problem, you can add sprofile to your $PATH.

0 Likes