70 questions with no answers
1
vote
0
answers
278
views
How to solve problem using gcc -pg on alpine?
I have dockerfile:
FROM alpine:3.18.2
WORKDIR /app
RUN apk add gdb gcc musl-dev make binutils
COPY ./src /app
RUN gcc main.c -pg -o app
But compilation fails with an error:
/usr/lib/gcc/x86_64-alpine-...
1
vote
0
answers
44
views
Filtering callgrind capture based on shared library name
I would like to have a coarse filter for my callgrind output.
If I ask callgrind to capture a run, I want to tell it to prune at a .so level.
For instance, I would like to tell it that it should not ...
0
votes
0
answers
357
views
Undefined symbol "_mcount" when cross-compiling for aarch64
I'm trying to use gprof for a project that runs in a small embedded OS (https://github.com/smartobjectoriented/so3). Compilation for this OS is done using the "aarch64-none-linux-gnu-" ...
1
vote
0
answers
145
views
GNU gprof showing calls in seconds instead of milliseconds
Is there an option i am missing that i couldnt find? i have searched the internets and all the articles show the flat profile in milliseconds without any added option tags, but my gprof outputs the ...
0
votes
0
answers
43
views
unable to understand gprof output
I have captured the gprof profiler output while running a c++ program. I got below logs
I found that there are two functions which are consuming most time ie receiveXappMessages and load() function. I ...
0
votes
0
answers
112
views
gprof's output gmon.out not appearing when cancelling slurm job before its finish
I am profiling a Fortran code with gprof.
I run this code on a cluster, where I request 24 cores from 1 node.
The job is submitted via slurm.
The command to run the code, inside the submission.sh I ...
1
vote
0
answers
72
views
gprof - Top times spent in `std::bad_variant_accesss::~bad_variant_access()`?
I'm trying to measure performance of some code I wrote. I compiled it with g++ with -pg flag, and when after running it I execute grpof, I reliably get std::bad_variant_access::~bad_variant_access() ...
3
votes
0
answers
558
views
Function never called but shown by gprof for C code?
I am having the upper issue and was wondering if this is a bug or I am using gprof wrong?
So as usual I compile my C code with -pg commands, and then after running it I do gprof ./my_program gmon....
0
votes
0
answers
96
views
Using gprof on a multitask ADA source code, I get the analysis of only the main task
I follow all the steps to instrumentalize, run and analyse the obtained output (gmon.out), but the text file obtained shows the analysis of the execution of the main task only.
I've read about similar ...
0
votes
0
answers
176
views
gprof generating only flat profile
I am profiling a fortran code with gprof. The code uses a c pre processor and mpifort wrapper with aocc (AMD compiler) to compile. I am specifying -pg flag for compilation as well as linking. But the ...
1
vote
0
answers
93
views
gprof shows every fonction (even summary) at 0%
I have a well working sort programm which I want to analyse with gprof.
Here is the code. It create random list of integers and sort it. It does the job :
#include <stdlib.h>
#include <stdio....
0
votes
0
answers
105
views
Using gprof and speeding up element-wise array multiplication in C++
I am using gprof as a profiler for my code for the purpose of enhancing efficiency/speed of my code and possibly parallelizing it eventually. I was able to profile the code and found out big portion ...
0
votes
0
answers
3k
views
How to do profiling a C++ project with gprof?
I have a big C++ program in VS code under Ubuntu 18.4, I am using CMake. I need to Know what areas are spending more time and memory space. I am a beginner in coding in Linux and using CMakeLists.txt ...
0
votes
0
answers
303
views
How to run gprof on non-terminating multi-threaded C++ program?
I can't call std::exit from an arbitrary thread (or via a signal handler), because other still-running threads will experience undefined behavior (typically, a segfault).
Normally, to exit the program,...
4
votes
0
answers
1k
views
WSL gprof reporting zero times
I'm trying to use gprof in WSL on Windows 10. I hadn't anticipated any difficulty, because it worked fine last time I used it in an Ubuntu virtual box on Windows 7. Following as before the directives ...