This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: ping: [testsuite patch] for: [PATCH] [PR corefiles/17808] i386: Fix internal error when prstatus in core file is too big
- From: Yao Qi <qiyaoltc at gmail dot com>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: Yao Qi <qiyaoltc at gmail dot com>, Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org, Andreas Arnez <arnez at linux dot vnet dot ibm dot com>
- Date: Thu, 16 Jul 2015 15:15:00 +0100
- Subject: Re: ping: [testsuite patch] for: [PATCH] [PR corefiles/17808] i386: Fix internal error when prstatus in core file is too big
- Authentication-results: sourceware.org; auth=none
- References: <874ms18cyz dot fsf at br87z6lw dot de dot ibm dot com> <20150108164327 dot GA29029 at host2 dot jankratochvil dot net> <20150205073758 dot GA25305 at host1 dot jankratochvil dot net> <54D33C45 dot 4010706 at redhat dot com> <20150214151231 dot GA29106 at host1 dot jankratochvil dot net> <54E33A8D dot 80504 at redhat dot com> <20150217165629 dot GA24936 at host1 dot jankratochvil dot net> <55A4CDD1 dot 6060907 at gmail dot com> <20150714180748 dot GA13461 at host1 dot jankratochvil dot net> <86fv4pjt4m dot fsf at gmail dot com> <20150715165849 dot GA12070 at host1 dot jankratochvil dot net>
Jan Kratochvil <jan.kratochvil@redhat.com> writes:
> I think the comments above are useful to understand why it does not behave as
> sanely as one would expect (=the real world case for loading kdump i386 kernel
> core files).
>
> So to add another part of the comment?
> # The output therefore does not matter much, just we should not get
> # GDB internal error.
It looks good to me.
>
> Although this whole feature is becoming marginal as i386 kernels in enterprise
> usage (=kdump) have AFAIK mostly disappeared.
>
>
>> > -gdb_test "core-file ${corefile}" "\r\nwarning: Unexpected size of
>> > section `\\.reg/6901' in core file\\.\r\n.*Core was generated by
>> > \[^\r\n\]*'\\.\r\nProgram terminated with signal SIGSEGV,
>> > Segmentation fault\\.\r\n.*" "core-file"
>> > +gdb_test "core-file ${corefile}" ".*" "core-file"
>>
>> >
>> > gdb_test "x/i $address" "\r\n\[ \t\]*$address:\[ \t\]*hlt\[
>> > \t\]*" ".text is readable"
>>
>> We also need comment here to explain the purpose this "x/i $address" test.
>
> Such a comment?
> # Test readability of a core file segment memory.
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?
--
Yao (éå)