From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7926 invoked by alias); 28 Aug 2005 21:58:08 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 7909 invoked by uid 48); 28 Aug 2005 21:58:04 -0000 Date: Sun, 28 Aug 2005 22:18:00 -0000 Message-ID: <20050828215804.7908.qmail@sourceware.org> From: "kevin at planetsaphire dot com" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20050828200424.23605.kevin@planetsaphire.com> References: <20050828200424.23605.kevin@planetsaphire.com> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug target/23605] memset() Optimization on x86-32 bit X-Bugzilla-Reason: CC X-SW-Source: 2005-08/txt/msg03219.txt.bz2 List-Id: ------- Additional Comments From kevin at planetsaphire dot com 2005-08-28 21:58 ------- (In reply to comment #6) > inlining memset is not an optimization as most OS's memsets are better than the inlined version, using > sse registers,etc. I have finished reviewing over the glibc memset.* source files for the 32-bit Intel platforms, simply because every one using Linux is using glibc as the "libc". I find that SSE (nor even MMX) is used in the 32-bit implementations of memset. I think it is best to change this bug into an enhancement for the next available GCC branch. The reason for this change is because of a few reasons: 1. Fedora Core 3 (the distro installed on my computer) does not install the i686 binaries of glibc during install; rather, it installs the i386 version. 2. You are right about systems having better memset()s, though considering the widespread use of glibc, most implementations do not utilize SSE, MMX, etc. Maybe the memset() optimization can be turned on by the use of a new flag? After all, the i386 build of glibc does not include the use of instructions that can possibly be used on i686. In addition, there may be a few circumstances where the user may not want to use the i686 build, such as debugging, apps that require the i386 build (perhaps to get around a few glibc bugs), and hardware processor issues with other functions in glibc. I hope the GCC staff and the steering committee reviews over this possible enhancement seriously. The optimization would allow the user to get around slower code in certain situations when it comes to using memset(). -- What |Removed |Added ---------------------------------------------------------------------------- Severity|minor |enhancement Status|RESOLVED |UNCONFIRMED Priority|P2 |P1 Resolution|INVALID | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23605