Skip to main content
  1. About
  2. Stack Internal
The 2026 Annual Developer Survey is live— take the Survey today!

Question list filters

Filter by
Sorted by
Tagged with
Filter by Employee ID
Score of 3 3 votes
1 answer 1 answer
173 views 173 views

How to make two structs to share the same data in C

I am developing the push swap problem, where I need to work with two stacks. One of the tasks my program needs to do is to keep track of the number of operations of each type, there are 11 of them ...
Durian Sosa's user avatar
  • 133 reputation score 133
Score of 0 0 votes
1 answer 1 answer
185 views 185 views

'valgrind --tool=massif' crashes with SIGTRAP inside `pthread_cond_timedwait` on RHEL 9/glibc 2.34

We're running a multithreaded C application under valgrind --tool=massif on RHEL 9 (glibc 2.34 and Valgrind 3.22.0) and seeing a crash with SIGTRAP inside pthread_cond_timedwait. The process dies ...
Yaakov Goldsmith's user avatar
  • 27 reputation score 27
Score of 3 3 votes
1 answer 1 answer
199 views 199 views

Conditional jump or move depends on uninitialised value(s) with php_pcre_match_impl

I'm creating a simple function in PHP-C extension, I'm using PHP 8.3 from source, enable opcache and pcre.jit. I set ZEND_DONT_UNLOAD_MODULES is 1 and USE_ZEND_ALLOC is 0 for the Valgrind Inside my ...
Son Le's user avatar
  • 454 reputation score 454
Score of 4 4 votes
2 answers 2 answers
155 views 155 views

Valgrind addresses vs Printf addresses in C

I create this simple C code to produce a buffer overflow: #include <stdio.h> #include <stdlib.h> void main(void) { int i=0; char *buffer=NULL; ...
Hakachukai's user avatar
  • 140 reputation score 140
Score of 2 2 votes
1 answer 1 answer
102 views 102 views

Find out why program is slow processing files from network share using Valgrind

I have an open source C/C++ program on Linux amd64 that processes a PDF input file and that I did not write by myself. So I'm not familiar with its code. Processing a PDF file read from local disk ...
MrSnrub's user avatar
  • 1,273 reputation score 1273
Score of 0 0 votes
0 answers 0 answers
87 views 87 views

Confused by Valgrind Massif output - appears memory allocated under "free"

I'm attempting to use Massif to profile heap usage of an application. I'm running with the --pages-as-heap=true option and am confused by some output I'm seeing. Specifically I'm seeing allocation by ...
Kevin's user avatar
  • 549 reputation score 549
Score of 9 9 votes
1 answer 1 answer
377 views 377 views

Valgrind (Helgrind) is showing data race with atomic

In the following program, I want to print the output as 0102030405... so on The 0 should be printed from one thread, odd values should be printed from second thread and even values from third thread....
SandeshK3112's user avatar
  • 117 reputation score 117
Score of 0 0 votes
1 answer 1 answer
74 views 74 views

How to get valgrind to print final tool stats for rustc

Perhaps someone knows why Valgrind tools fail to print final stats when applied to rustc ? E.g. lackey works fine with C programs: $ valgrind -q --tool=lackey --basic-counts=yes whoami yugr ==3668989==...
yugr's user avatar
  • 22.9k reputation score 22896
Score of 2 2 votes
1 answer 1 answer
151 views 151 views

Still reachable valgrind report when execve fails

I am building a shell as part of a school assignment, a limited version of bash. The whole program seems to function alright without any kind on leaks, but when I send invalid/nonexistent commands ...
Rache Bartmoss's user avatar
  • 49 reputation score 49
Score of 1 1 vote
1 answer 1 answer
114 views 114 views

CS50 Speller Valgrind error: Jump or move depends on uninitialized value(s)

I am currently completing the introductory CS course CS50 only and got stuck on the problem "speller" from problem set 5. In this problem, one is given a set of prewritten .c-files, ...
S. Meister's user avatar
  • 11 reputation score 11
Score of 1 1 vote
1 answer 1 answer
44 views 44 views

Is there's an easy way to give valgrind client the illusion of (plausible) real time

If I run a program under valgrind that also keeps track of time, is there a way to make it get plausible results given the amount of code it has executed. What I'm planning to do is to run GStreamer ...
skyking's user avatar
  • 14.7k reputation score 14692
Score of 3 3 votes
2 answers 2 answers
142 views 142 views

Custom free function doesn't release memory completely, Valgrind reports 'still reachable'

I've been following an article that walks through implementing primitive versions of malloc and free. After finishing the allocator, I wanted to test it using Valgrind, so I added the following lines ...
younessBct's user avatar
  • 51 reputation score 51
Score of 1 1 vote
2 answers 2 answers
59 views 59 views

Is it recommended to run valgrind on a binary generated using multiple processors

I have a binary which was generated using 10 threads i.e. I used GNU make command make -j10 to generate my binary. If I run valgrind on the generated binary, will the valgrind result be reliable. ...
user146290's user avatar
  • 111 reputation score 111
Score of 1 1 vote
2 answers 2 answers
83 views 83 views

How to run valgrind for apache cgi module?

My CGI application written in C has memory corruption. I would like to attach valgrind while running the application. How do I do that? As apache is invoking the cgi module, I dont have an option to ...
Gilson PJ's user avatar
  • 3,620 reputation score 3620
Score of 7 7 votes
2 answers 2 answers
280 views 280 views

C++ embedded TCL interpreter possible memory leaks

I have code which embeds a tcl interpreter in my c++ program. When running with valgrind it shows a bunch of possible memory leaks from the TCL interpreter. I am using Tcl_DeleteInterp(interp); to ...
Zachary Ellis's user avatar
  • 91 reputation score 91

15 30 50 per page
1
2 3 4 5
283
Morty Proxy This is a proxified and sanitized view of the page, visit original site.