Re: [PATCH] simplify-rtx.c: start adding selftests (v2)

2016-07-29 Thread Jeff Law
On 07/19/2016 09:46 AM, David Malcolm wrote: It almost seems like the iteration space has to be dependent on what you're testing. Ie, some tests you want to iterate over the standard integer modes. Other tests you might reasonably include FP modes. CC modes I think should be forbidden for the

Re: [PATCH] simplify-rtx.c: start adding selftests (v2)

2016-07-19 Thread David Malcolm
On Wed, 2016-07-13 at 13:38 -0600, Jeff Law wrote: > On 07/06/2016 01:30 PM, David Malcolm wrote: > > > > > > This might be a bit confusing when more tests are added, since > > > pointer equality is only useful in certain specific cases (e.g. > > > when you know you're dealing with CONST_INTs or p

Re: [PATCH] simplify-rtx.c: start adding selftests (v2)

2016-07-13 Thread Jeff Law
On 07/06/2016 01:30 PM, David Malcolm wrote: This might be a bit confusing when more tests are added, since pointer equality is only useful in certain specific cases (e.g. when you know you're dealing with CONST_INTs or pseudo registers). How about making ASSERT_RTX_EQ check for rtx_equal_p equa

Re: [PATCH] simplify-rtx.c: start adding selftests

2016-07-03 Thread Richard Sandiford
David Malcolm writes: > This patch starts adding selftests to simplify-rtx.c, to ensure that > RTL expressions are simplified as we expect. > > It adds a new ASSERT_RTX_EQ macro that checks for pointer equality > of two rtx values. If they're non-equal, it aborts, printing both > expressions. Th