[Bug tdep/24104] amd64_push_arguments assert running C++ version of gdb.base/infcall-nested-structs

vries at gcc dot gnu.org sourceware-bugzilla@sourceware.org
Fri Oct 11 08:49:00 GMT 2019


https://sourceware.org/bugzilla/show_bug.cgi?id=24104

--- Comment #3 from Tom de Vries <vries at gcc dot gnu.org> ---
A more minimal version:

...
$ cat test3.c
typedef long tl;

struct s
{
  struct { } es1;
  tl f;
};

struct s ref = {
  {},
  'f'
};

int
check (struct s arg)
{
  return arg.f == 'f';
}

int
main (void)
{
  return check (ref);
}
...

$ g++ test3.c -g && ( ./a.out; echo $? ) && gdb a.out -batch -ex start -ex "p
check (ref)"
1
Temporary breakpoint 1 at 0x4004f7: file test3.c, line 23.

Temporary breakpoint 1, main () at test3.c:23
23        return check (ref);
src/gdb/amd64-tdep.c:966: internal-error: CORE_ADDR
amd64_push_arguments(regcache*, int, value**, CORE_ADDR,
function_call_return_method): Assertion `!"Unexpected register class."' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
...

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Gdb-prs mailing list