On 02.08.16 08:40:59, Dann Frazier wrote:

> I ran this test on our 2.0 silicon - which I *thought* was supposed to
> be ARMv8.1 - but it passes there.
> Can you confirm if that should be the case?

With newer firmware (e.g. 1.23.6 from Jul 22 2016) this no longer
happens for 2.0 systems. You can reproduce it with older firmware (e.g.
1.21.3), see here:

good:

 (gdb) break main
 Breakpoint 1 at 0x4005c8: file main.c, line 5.
 (gdb) run
 Starting program: /root/test/main 
 
 Breakpoint 1, main () at main.c:5
 5              printf("Hello world.\n");

bad:

 (gdb) break main
 Breakpoint 1 at 0x4005c8: file main.c, line 5.
 (gdb) run
 Starting program: /root/test/main 
 warning: Unable to determine the number of hardware watchpoints available.
 warning: Unable to determine the number of hardware breakpoints available.
 
 Breakpoint 1, main () at main.c:5
 5              printf("Hello world.\n");

-Robert

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to gdb in Ubuntu.
https://bugs.launchpad.net/bugs/1608948

Title:
  support hw watchpoints/breakpoints on ARMv8.{1,2}

Status in gdb package in Ubuntu:
  New
Status in gdb source package in Xenial:
  New

Bug description:
  [Impact]
  gdb reports no hw watchpoint/breakpoint support on ARMv8.1

  [Test Case]
  Test.c:
  int main(void)
  {
    int a;
    a = 0;
    a++;
    return a!=1;
  }
  ----- CUT ----
  gcc -g test.c -o testprog
  apinski@apinski-ss1:~/binutils-gdb$ ./tools/bin/gdb -q a.out
  Reading symbols from a.out...done.
  (gdb) start
  Temporary breakpoint 1 at 0x40050c: file t.c, line 4.
  Starting program: /home/apinski/binutils-gdb/a.out

  Temporary breakpoint 1, main () at t.c:4
  4         a = 0;
  (gdb) hb 5
  Hardware assisted breakpoint 2 at 0x400510: file t.c, line 5.
  (gdb) c
  Continuing.

  Breakpoint 2, main () at t.c:5
  5         a++;
  (gdb)

  This fails on ARMv8.1 platforms w/o the patch.

  [Regression Risk]
  Patch is a clean cherry pick from upstream that just adds code to detect 8.1 
& 8.2 chip debug types.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdb/+bug/1608948/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to