This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] new test for separate debug info


> Ya! Now what would be nice is a similar gdbserver sniff test :-)


Er.... I have absolutely no idea what that sentence means :)

short answer:


gdb/testsuite/gdb.base/gdbserver.exp

long answer:

There are two ways of testing stuff like separate debug info and gdb-server:

- as part of full and separate dejagnu test run
eg: make check RUNTESTFLAGS=--target_board=gdbserver

- as a small focused functional / unit test
eg: make check RUNTESTFLAGS=gdbserver.exp

Both are correct as both offer distinct advantages and disadvantages (mind you I should note that I've witnessed argument disputing this :-). The former provides better coverage, but with no realistic expectation that the average GDB developer will ever run it; while the later ensures that that specific functionality is always working, but lacks broad coverage.

A gdbserver.exp unit test would significantly improve the odds of gdbserver working with a standard GDB. It would also make possible the writing of gdbserver specific tests that explore edge cases missed by the more standard tests (the attach / detach behavior for instance). Also, in support of this, even though separate debug info bit rot and broke within months of its initial commit, the breakage wasn't noticed for several further months (when the unit test was added).

Andrew



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]