Re: [GIT PULL] debug build of sparse v4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 18, 2017 at 3:18 PM, Luc Van Oostenryck
<luc.vanoostenryck@xxxxxxxxx> wrote:
> No real objections but I have some doubts about all the debug part.
> I think that people hacking on sparse and who need to debug know
> what they need and want to debug.

Right, this change is to allow a separate debug binary let say "dbg-sparse",
to be execute from "sparse" when needed.

Take the ptrlist ref count checking for example. I image have
sparse --check-ptrlist, which will invoke dbg-sparse to do the
checking. I expect the distro will include dbg-sparse as part
of the sparse package as well.

The end result is that. The user of sparse, not sparse developers,
can invoke sparse with those extra verification (at cost of slow
down sparse) on the custom input source without modify and
recompile sparse.

> For example, the OPT=0 is, IMO, useless as you generally need
> others flags too. Also, when you debug, you generally need to rerun
> things several times, so using extra options on the command line is
> not ideal (a mechanism like local.mk is better suited but local.mk
> itself is not).

In that case, you can just OPT=0 into local.mk and problem solved?
Even if you do that, you still need to provide OPT variable for overwrite
purpose. Append and reset the whole variable is easy.
Partial modify the content of variable from one to another is harder and
annoying.

Can you clarify "but local.mk itself is not".

> Also, what's the real need for dbgbuild/ & debug/ ?
> IMO, it's a big complexification of all the rules with plenty of
> duplicated things for very few, if any, benefits.

Provide extra verification on user input files. Another candidate
of those verification can be, the sorting of ptrlist.
There is function  verify_seq_sorted () verify the list is indeed sorted.
But that function currently is not turn on in sparse. Presumably
it is used in the development phase of the ptr list sorting.
That verification function can be turn on in the debug build for example.

Chris
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux