Re: [PATCH v5 0/2] Modify can_spawn_for_attach

Simon Marchi via Gdb-patches
2022-03-03T15:46:38Z

On 2022-03-02 01:42, Tiezhu Yang wrote:
>
>
> On 03/01/2022 10:12 PM, Simon Marchi wrote:
>>
>>
>> On 2022-02-28 09:36, Simon Marchi via Gdb-patches wrote:
>>> On 2022-02-28 01:59, Tiezhu Yang wrote:
>>>>
>>>>
>>>> On 02/23/2022 10:45 AM, Tiezhu Yang wrote:
>>>>> v5:
>>>>>   -- Use "unsupported" instead of "untested" in patch #1,
>>>>>      suggested by Simon Marchi, thank you.
>>>>>
>>>>> v4:
>>>>>   -- Add patch #1 to print explicit test result for some test.
>>>>>   -- Modify patch #2 suggested by Simon Marchi, thank you.
>>>>>
>>>>> Tiezhu Yang (2):
>>>>>   gdb: testsuite: print explicit test result in can_spawn_for_attach
>>>>>   gdb: testsuite: fix wrong expected result in attach-pie-noexec.exp
>>>>>
>>>>>  gdb/testsuite/lib/gdb.exp | 46 +++++++++++++++++++++++++++++++++++++++-------
>>>>>  1 file changed, 39 insertions(+), 7 deletions(-)
>>>>>
>>>>
>>>> Hi,
>>>>
>>>> I modified the patches as you suggested.
>>>> Any more comments?
>>>> Can I push this patchset to the master?
>>>
>>> Yeah, please go ahead, thanks.
>>>
>>> Simon
>>
>> Actually, this causes the following test failures:
>>
>> FAIL: gdb.base/gdb-caching-proc.exp: can_spawn_for_attach: 0: can spawn for attach (got interactive prompt)
>>
>> Can you please take a look?
>
> OK, I will look into it.

Thanks, gdb-caching-proc.exp now passes for me.

I see this now though (this is on Ubuntu 20.04):

attach 3431435^M
A program is being debugged already. Kill it? (y or n) y^M
Attaching to program: /home/smarchi/build/binutils-gdb/gdb/testsuite/outputs/gdb.base/jit-elf/jit-elf-main, process 3431435^M
Reading symbols from /lib64/ld-linux-x86-64.so.2...^M
Reading symbols from /usr/lib/debug//lib/x86_64-linux-gnu/ld-2.31.so...^M
Unable to read JIT descriptor from remote memory^M
0x00007fafc9384334 in ?? ()^M
(gdb) FAIL: gdb.base/jit-elf.exp: can spawn for attach

Simon