From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Lammerts Date: Sat, 10 Oct 2009 12:09:37 -0400 Subject: [U-Boot] [PATCH 1/3] memcpy: use 32-bit copies if possible In-Reply-To: <20091008074114.GA30203@mail.gnudd.com> References: <200910070452.02225.vapier@gentoo.org> <20091008074114.GA30203@mail.gnudd.com> Message-ID: <4AD0B1C1.4010006@lists.lammerts.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 10/08/09 03:41, Alessandro Rubini wrote: > For memcpy all is well, for memset I have this problem: > if (sizeof(long) > 4) > cl |= cl << 32; > string.c:416: warning: left shift count >= width of type > > (obviously there is no such shift in the generated code, > since the condition is false at compile time). > > I think I'll stick to u32 for memset, unless I get better suggestions. What about if (sizeof(long) > 4) cl |= (unsigned long long)cl << 32; ? Eric