[Bug tree-optimization/63464] compare one character to many: faster

2015-01-16 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #16 from Jakub Jelinek jakub at gcc dot gnu.org --- So, I had a brief look at the #c14 issues. --- gcc/match.pd.jj2015-01-05 13:07:14.0 +0100 +++ gcc/match.pd2015-01-16 16:27:08.053817209 +0100 @@ -614,6 +614,16 @@

[Bug tree-optimization/63464] compare one character to many: faster

2015-01-16 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #17 from Jakub Jelinek jakub at gcc dot gnu.org --- Or try to deal with this in combine. We have: (insn 91 90 92 18 (parallel [ (set (reg:DI 149 [ D.1943 ]) (and:DI (reg:DI 147 [ D.1943 ])

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-17 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #13 from Jakub Jelinek jakub at gcc dot gnu.org --- Author: jakub Date: Fri Oct 17 10:54:54 2014 New Revision: 216393 URL: https://gcc.gnu.org/viewcvs?rev=216393root=gccview=rev Log: PR tree-optimization/63464 * gimple.h

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-17 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 Jakub Jelinek jakub at gcc dot gnu.org changed: What|Removed |Added CC||uros at gcc dot

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-17 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #15 from Uroš Bizjak ubizjak at gmail dot com --- (In reply to Jakub Jelinek from comment #14) So, supposedly there is something we want to match-and-simplify, perhaps also something we want to simplify at the RTL level, and check

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-15 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #12 from Jakub Jelinek jakub at gcc dot gnu.org --- Created attachment 33724 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33724action=edit gcc5-pr63464.patch Untested patch.

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-14 Thread rguenther at suse dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #11 from rguenther at suse dot de rguenther at suse dot de --- On Mon, 13 Oct 2014, jakub at gcc dot gnu.org wrote: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #9 from Jakub Jelinek jakub at gcc dot gnu.org ---

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-13 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #9 from Jakub Jelinek jakub at gcc dot gnu.org --- Created attachment 33697 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33697action=edit gcc5-pr63464.patch WIP patch. What is missing: 1) the optimize_range_tests_to_bit_test

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-13 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #10 from Jakub Jelinek jakub at gcc dot gnu.org --- Created attachment 33698 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33698action=edit bittest.c Testcase I've been playing with.

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-10 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #8 from Jakub Jelinek jakub at gcc dot gnu.org --- Author: jakub Date: Fri Oct 10 12:15:30 2014 New Revision: 216072 URL: https://gcc.gnu.org/viewcvs?rev=216072root=gccview=rev Log: PR tree-optimization/63464 *

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-07 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org --- Created attachment 33658 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33658action=edit gcc5-pr63464.patch Updated patch for the switchconv, this time checking rtx costs. As

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-07 Thread rguenther at suse dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #5 from rguenther at suse dot de rguenther at suse dot de --- On Tue, 7 Oct 2014, jakub at gcc dot gnu.org wrote: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org ---

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-07 Thread glisse at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #6 from Marc Glisse glisse at gcc dot gnu.org --- (In reply to Jakub Jelinek from comment #1) We have this optimization implemented for switches, Thanks, that's indeed the most natural place for it, although I hadn't thought of

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-07 Thread glisse at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #7 from Marc Glisse glisse at gcc dot gnu.org --- The SLP version is slightly slower than the bit test in this case (at least on my old desktop), but it can more easily handle testing for characters that are not within 64 of each

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-06 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 Jakub Jelinek jakub at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |NEW Last

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-06 Thread rguenther at suse dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #2 from rguenther at suse dot de rguenther at suse dot de --- On Mon, 6 Oct 2014, jakub at gcc dot gnu.org wrote: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 Jakub Jelinek jakub at gcc dot gnu.org changed:

[Bug tree-optimization/63464] compare one character to many: faster

2014-10-06 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63464 --- Comment #3 from Jakub Jelinek jakub at gcc dot gnu.org --- Created attachment 33654 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33654action=edit gcc5-pr63464.patch Untested patch to avoid the subtraction of info.range_min from index.