r260689 - in /trunk/gcc: ChangeLog fold-const.c...

law@gcc.gnu.org law@gcc.gnu.org
Thu May 24 20:47:00 GMT 2018


Author: law
Date: Thu May 24 20:47:03 2018
New Revision: 260689

URL: https://gcc.gnu.org/viewcvs?rev=260689&root=gcc&view=rev
Log:
        * fold-const.c (tree_nonzero_bits): New function.
        * fold-const.h (tree_nonzero_bits): Likewise.
        * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
        friends.  POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.

        * gcc.dg/fold-popcount-1.c: New testcase.
        * gcc.dg/fold-popcount-2.c: New testcase.
        * gcc.dg/fold-popcount-3.c: New testcase.
        * gcc.dg/fold-popcount-4.c: New testcase.

Added:
    trunk/gcc/testsuite/gcc.dg/fold-popcount-1.c
    trunk/gcc/testsuite/gcc.dg/fold-popcount-2.c
    trunk/gcc/testsuite/gcc.dg/fold-popcount-3.c
    trunk/gcc/testsuite/gcc.dg/fold-popcount-4.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/fold-const.c
    trunk/gcc/fold-const.h
    trunk/gcc/match.pd
    trunk/gcc/testsuite/ChangeLog



More information about the Gcc-cvs mailing list