From kde-bugs-dist Mon Apr 30 20:29:01 2018 From: Tom Hughes Date: Mon, 30 Apr 2018 20:29:01 +0000 To: kde-bugs-dist Subject: [valgrind] [Bug 392855] valgrind reports 1 additional allocation and 1024 additional bytes allocated Message-Id: X-MARC-Message: https://marc.info/?l=kde-bugs-dist&m=152512015229402 https://bugs.kde.org/show_bug.cgi?id=3D392855 Tom Hughes changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution|--- |INVALID --- Comment #4 from Tom Hughes --- All that's happened in the second case is that gcc has optimised out the wh= ole thing as the nonsense that it is - it just puts 5 straight in the argument register and passes it to printf. That's what happens when you compile with optimisation. So in the first case what you are seeing is your malloc, and in the second = your malloc never happens but something else (likely the dynamic linker or C lib= rary run time) does do a 1024 byte malloc. --=20 You are receiving this mail because: You are watching all bug changes.=