[Bug middle-end/46647] Can't inline memset with -1

2010-11-28 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 H.J. Lu changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|

[Bug middle-end/46647] Can't inline memset with -1

2010-11-26 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #12 from Jakub Jelinek 2010-11-26 09:38:59 UTC --- Author: jakub Date: Fri Nov 26 09:38:54 2010 New Revision: 167170 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=167170 Log: PR middle-end/46647 * builtins.c (fold_bui

[Bug middle-end/46647] Can't inline memset with -1

2010-11-25 Thread hjl at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #11 from hjl at gcc dot gnu.org 2010-11-25 13:48:06 UTC --- Author: hjl Date: Thu Nov 25 13:47:42 2010 New Revision: 167146 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=167146 Log: Properly cast integer constant char. gcc/

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #10 from H.J. Lu 2010-11-24 22:22:17 UTC --- Created attachment 22519 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22519 A patch I am testing it on Linux/x86-64.

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #9 from H.J. Lu 2010-11-24 22:11:03 UTC --- (In reply to comment #8) > I'd prefer to replace the host_integerp call in that routine with > TREE_CODE (...) == INTEGER_CST check. While currently callers check it as > well, it isn't too

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #8 from Jakub Jelinek 2010-11-24 22:04:11 UTC --- I'd prefer to replace the host_integerp call in that routine with TREE_CODE (...) == INTEGER_CST check. While currently callers check it as well, it isn't too expensive and makes it m

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #7 from H.J. Lu 2010-11-24 22:00:25 UTC --- This seems to work: --- diff --git a/gcc/builtins.c b/gcc/builtins.c index c9e8e68..840ec29 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -630,11 +630,10 @@ target_char_cast (tree cst

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #6 from H.J. Lu 2010-11-24 21:52:46 UTC --- The problem seems to be target_char_cast.

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #5 from H.J. Lu 2010-11-24 21:43:11 UTC --- char a[4] isn't handled by fold_builtin_memset.

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #4 f

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 --- Comment #3 from H.J. Lu 2010-11-24 21:08:10 UTC --- fold_builtin_memset fails to handle 0x[8-f]fff.

[Bug middle-end/46647] Can't inline memset with -1

2010-11-24 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46647 H.J. Lu changed: What|Removed |Added CC||rguenth at gcc dot gnu.org Component|t