Il giorno lun 19 nov 2018 alle ore 16:53 David Faure <fa...@kde.org> ha scritto:
>
> When using vgdb (e.g. `valgrind --vgdb-error=0 myprog`)
> and there's a valgrind warning for an uninitialized read, on a line like
>     if (a || b)
>
> The question that happens then is, of course, was it a or b that was
> uninitialized. If one uses vgdb to print the values of a and b, it won't
> necessarily be obvious (e.g. two bools, both happen to show as "false", with
> only one actually uninitialized). This makes me wonder, wouldn't it be
> possible for vgdb to output a warning when doing "print a" or "print b" from
> gdb and the value is marked as uninitialized?
>
> If I understand the architecture correctly, this should be possible to
> implement, right?

I do not want to estimate how feasible would be to implement this feature.
Patches are welcome, of course.

But you can use an existing feature:
http://valgrind.org/docs/manual/mc-manual.html#mc-manual.machine
http://valgrind.org/docs/manual/mc-manual.html#mc-manual.monitor-commands

This will give you what (I think) you want.
I.


_______________________________________________
Valgrind-users mailing list
Valgrind-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to