Re: ping: [testsuite patch] for: [PATCH] [PR corefiles/17808] i386: Fix internal error when prstatus in core file is too big

Jan Kratochvil
2015-07-16T14:37:58Z

On Thu, 16 Jul 2015 16:15:00 +0200, Yao Qi wrote:
> Sorry, I should be more clear. Let me ask in another way, why do we
> need "x/i $address" test? Without the patch fixing PR 17808, GDB should
> crash on loading core-file, and we tested that. Why do we do this test
> and test whether ".text" is readable or not?

Because this testcase comes from a different bug from 2009:
https://bugzilla.redhat.com/show_bug.cgi?id=457187
http://pkgs.fedoraproject.org/cgit/gdb.git/commit/?id=94cd124608bf0dd359cb48a710800d72c21b30c3

That bug has been fixed in the meantime but the same testcase was reproducing
this new different bug - internal error regression - so I submitted it.

We can remove the "x/i $address" test but it was useful for the previous bug
from 2009 as that time the internal error regression did not happen, just the
core file was not recognized (which would not be detected by the proposed
ignoring of the "core-file" command output) and so the core file was not
available. That can be tested by the "x/i $address" test.

But we could be upstreaming much more Fedora testcases which I do not plan to.
Fedora contains many testcases - 49
grep '^#=' gdb.spec|sed 's/[:+].*//'|sort|uniq -c
49 #=fedoratest
for various bugs already fixed upstream. But given there isn't enough work
resources to upstream even Fedora fixes (hacks) I have never much attempted to
upstream all the testcases there.
http://pkgs.fedoraproject.org/cgit/gdb.git/tree/
(Some/few of the testcases are also a different form of the upstreamed variant
of the same testcase kept to be really sure no regressions are needlessly
missed in Fedora/RHEL.)

Jan