RE: IPv4 checksum oddness (gcc compiler bug?)

From: Mike Bristow <mike_at_urgle.com>
Date: Wed, 25 Aug 2004 12:12:16 +0100
On Wed, 2004-08-25 at 00:57, Li, Qing wrote:
> 	I ran into a checksum problem and filed the following bug
> report.
> 	See if it's related.
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=69257

To quote from Apple's GCC 3.3 docs:

 You can't expect a sequence of volatile asm instructions to remain
 perfectly consecutive. If you want consecutive output, use a single
 asm.  Also, GCC will perform some optimizations across a volatile asm
 instruction; GCC does not "forget everything" when it encounters a
 volatile asm instruction the way some other compilers do.

I've added a patch to the PR above which uses a single asm statement;
I'll make some noise about it post 5.3.

-- 
Mike Bristow - http://www.urgle.com/~mike/ - mike_at_urgle.com
Why did the farmer call his horse Blacksmith?
Mrs Sippi
Received on Wed Aug 25 2004 - 09:12:24 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:08 UTC