This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug middle-end/27567] [4.0/4.1/4.2 Regression] __builtin_memcpy generates redundant stores/moves.



------- Comment #6 from jakub at gcc dot gnu dot org  2006-09-02 06:55 -------
Subject: Bug 27567

Author: jakub
Date: Sat Sep  2 06:55:09 2006
New Revision: 116656

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=116656
Log:
        PR middle-end/27567
        * builtins.c (fold_builtin_memcpy, fold_builtin_memmove): Remove.
        (fold_builtin_mempcpy): Rename to...
        (fold_builtin_memory_op): ... this.  Optimize one element copy
        into an assignment.
        (fold_builtin_memset, fold_builtin_bzero, fold_builtin_bcopy): New
        functions.
        (expand_builtin_strcpy, expand_builtin_strncpy): Handle COMPOUND_EXPR.
        (expand_builtin_memcpy, expand_builtin_mempcpy,
        expand_builtin_memmove): Likewise.  Use fold_builtin_memory_op.
        (fold_builtin_1): Handle BUILT_IN_MEMSET, BUILT_IN_BZERO and
        BUILT_IN_BCOPY.  Use fold_builtin_memory_op for
        BUILT_IN_MEM{CPY,PCPY,MOVE}.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/builtins.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27567


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