This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 3/7 v3] Add testcases for ppc64 tracepoint.


Wei-cheng Wang wrote:

> 2015-03-30  Wei-cheng Wang  <cole945@gmail.com>
> 
> 	* gdb.trace/backtrace.exp: Set registers for powerpc*-*-*.
> 	* gdb.trace/collection.exp: Ditto.
> 	* gdb.trace/entry-values.exp: Ditto.
> 	* gdb.trace/mi-trace-frame-collected.exp: Ditto.
> 	* gdb.trace/mi-trace-unavailable.exp: Ditto.
> 	* gdb.trace/pending.exp: Ditto.
> 	* gdb.trace/report.exp: Ditto.
> 	* gdb.trace/trace-break.exp: Ditto.
> 	* gdb.trace/while-dyn.exp: Ditto.
> 	* gdb.trace/change-loc.h: set_point for powerpc.
> 	* gdb.trace/ftrace.c: Ditto
> 	* gdb.trace/pendshr1.c: Ditto.
> 	* gdb.trace/pendshr2.c: Ditto.
> 	* gdb.trace/range-stepping.c: Ditto.
> 	* gdb.trace/trace-break.c: Ditto.
> 	* gdb.trace/trace-mt.c: Ditto.
> 	* gdb.trace/ftrace.exp: Enable testing for powerpc*-*-*.
> 	(test_ftrace_condition) New function for testing bytecode compilation.

Ah, when I said to add new test cases in a separate patch, what I meant was:

- use a separate patch (applied *first*) that adds the *new tests* (to be
  run on existing platforms), i.e. test_ftrace_condition

- as part of the patch that actually adds powerpc support, add all the small
  test case snippets that specifically enable the test cases for powerpc

This is again so that each set in a series is meaningful in itself (and
does not introduce testsuite regressions when applied alone).

> diff --git a/gdb/testsuite/gdb.trace/actions.c b/gdb/testsuite/gdb.trace/actions.c
> index 4b7b887..d8538e4 100644
> --- a/gdb/testsuite/gdb.trace/actions.c
> +++ b/gdb/testsuite/gdb.trace/actions.c
> @@ -46,6 +46,8 @@ static union GDB_UNION_TEST
>  } gdb_union1_test;
>  
>  void gdb_recursion_test (int, int, int, int,  int,  int,  int);
> +typedef void (*gdb_recursion_test_fp) (int, int, int, int,  int,  int,  int);
> +gdb_recursion_test_fp gdb_recursion_test_ptr = gdb_recursion_test;

This is OK, but really needs a comment explaining why it is needed.

> +#elif (defined __PPC64__ || defined __PPC__)

Use __powerpc64__ and __powerpc__ everywhere.

Otherwise looks good.

Thanks,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU/Linux compilers and toolchain
  Ulrich.Weigand@de.ibm.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]