Tag: valgrind

Valgrind Massif工具输出graphics界面?

我正在使用Valgrind 3.3.1与Massif工具来分析C ++应用程序的堆,我想知道是否有一个graphics工具来检查文本输出文件文件。 感谢您的任何build议。

valgrind如何工作?

有人可以提供Valgrind如何工作的快速顶级解释吗? 一个例子:它是如何知道内存何时分配和释放的?

如何将Valgrind的输出redirect到一个文件?

在使用Valgrind工具时,我需要loggingvalgrind工具生成的详细信息。 我怎么能做到这一点? 我尝试了一些像 valgrind a.out | test 和 valgrind a.out > test 它给出了程序的输出,而不是valgrind内存错误,泄漏信息。 即使我得到这样的程序如果不需要用户交互(即给予input)。 如果程序需要用户input,那么这个东西本身就不能工作。 我怎样才能做到这一点?

优胜美地和Valgrind

你能告诉我如何在优胜美地上安装valgrind吗? 当我尝试安装它时,我得到“检查内核版本…不受支持(14.0.0)configuration:错误:Valgrind工作在达尔文10.x,11.x,12.x和13.x(Mac OS X 10.6 / 7/8/9)“ 没有正式的path或更新,我没有find任何东西(除http://comments.gmane.org/gmane.comp.kde.devel.bugs/1553705 ,但他们没有解决这个问题)。

精确定位“有条件的跳转或移动取决于未初始化的值”(valgrind消息)

所以我一直在从Valgrind那里得到一些神秘的未初始化值的消息,这个坏的价值源于哪里,这是一个相当神秘的事情。 似乎valgrind显示单位化值最终被使用的地方,但不是未初始化值的来源。 ==11366== Conditional jump or move depends on uninitialised value(s) ==11366== at 0x43CAE4F: __printf_fp (in /lib/tls/i686/cmov/libc-2.7.so) ==11366== by 0x43C6563: vfprintf (in /lib/tls/i686/cmov/libc-2.7.so) ==11366== by 0x43EAC03: vsnprintf (in /lib/tls/i686/cmov/libc-2.7.so) ==11366== by 0x42D475B: (within /usr/lib/libstdc++.so.6.0.9) ==11366== by 0x42E2C9B: std::ostreambuf_iterator<char, std::char_traits<char> > std::num_put<char, std::ostreambuf_iterator<char, std::char_traits<char> > >::_M_insert_float<double>(std::ostreambuf_iterator<char, std::char_traits<char> >, std::ios_base&, char, char, double) const (in /usr/lib/libstdc++.so.6.0.9) ==11366== […]

Valgrind无法运行Java Android程序

我正在尝试像Valgring一样启动Java程序(在adb shell中): valgrind am start -a android.intent.action.MAIN -n com.me.myapp/.MainActivity 我越来越: ==2362== Memcheck, a memory error detector ==2362== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al. ==2362== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info ==2362== Command: am ==2362== /system/bin/sh: am: No such file or directory

cpp – valgrind – 大小为8的无效读取

我疯了理解valgrind错误。 我有一个名为matrix的模板类,它有一些重载的操作符等…做一些math运算。 Matrixes在名为ExtendedKalmanFilter的类中使用。 这里是valgrind痕迹: ==3352== Invalid read of size 8 ==3352== at 0x804CC8F: BOViL::math::Matrix<double>::operator*(BOViL::math::Matrix<double> const&) const (Matrix.h:285) ==3352== by 0x8051F91: BOViL::algorithms::ExtendedKalmanFilter::forecastStep(double) (ExtendedKalmanFilter.cpp:48) ==3352== by 0x8051F25: BOViL::algorithms::ExtendedKalmanFilter::stepEKF(BOViL::math::Matrix<double> const&, double) (ExtendedKalmanFilter.cpp:39) ==3352== by 0x804B98F: testSegmentation() (TestSegmentation.cpp:53) ==3352== by 0x805266D: main (main.cpp:16) ==3352== Address 0x6a8b3c0 is 0 bytes after a block of size 48 alloc'd ==3352== at 0x402B454: […]

Valgrind:使用<iostream>,仍然可以使用普通程序访问内存

采取以下简单的程序: #include <iostream> int main() { return 0; } 如果我使用valgrind运行这个,我被告知72,704 bytes in 1 blocks中有72,704 bytes in 1 blocks still reachable 。 关于是否担心可以警告的问题,我们已经进行了广泛的讨论 – 我并不担心这一点。 我只是想知道如何简单地包括一个标准的库头可能会导致一个仍然可及的警告,当没有从该库中的对象被分配在程序本身。 这里是完整的valgrind输出: $ valgrind –leak-check=full –track-origins=yes –show-reachable=yes ./ValgrindTest ==27671== Memcheck, a memory error detector ==27671== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al. ==27671== Using Valgrind-3.10.1 and LibVEX; […]

Valgrind检测到仍然可达泄漏

所有在这个块中提到的函数都是库函数。 我该如何纠正这个内存泄漏? 它列在“ 可到达 ”类别下。 (还有4个,非常相似,但大小不一) 630 bytes in 1 blocks are still reachable in loss record 5 of 5 at 0x4004F1B: calloc (vg_replace_malloc.c:418) by 0x931CD2: _dl_new_object (dl-object.c:52) by 0x92DD36: _dl_map_object_from_fd (dl-load.c:972) by 0x92EFB6: _dl_map_object (dl-load.c:2251) by 0x939F1B: dl_open_worker (dl-open.c:255) by 0x935965: _dl_catch_error (dl-error.c:178) by 0x9399C5: _dl_open (dl-open.c:584) by 0xA64E31: do_dlopen (dl-libc.c:86) by 0x935965: _dl_catch_error […]

有没有一个很好的Valgrind替代Windows?

我正在调查Valgrind,以帮助改进我的C编码/debugging,当我发现它只用于Linux – 我没有其他需要或兴趣将我的操作系统移到Linux,所以我想知道是否有一个同样好的Windows程序。