Re: C Standards

Kevin Lentin (kevinl@cs.monash.edu.au)
Fri, 22 May 1998 18:14:47 +1000


On Thu, May 21, 1998 at 04:28:59PM +0200, Peter T. Breuer wrote:
> > The fact that a compiler is now free to rearrange code in any way it
> > wishes, should bother the hell out of anybody who writes software that
> > controls machines.
>
> It should encourage them to be careful. They can put sequence points
> whenever they want. Anyway, the compiler won't make a change that can
> affect the functional semantics. What you have to be careful of is
> relying on NON-functional semantics, such as timing, in code.

Let's also add that modern CPUs rearrange code as well. If I remember
correctly, things like the Ppro and P2 do some pretty nasty stuff with the
order they choose to do things. As you say, Peter, as long as the semantics
are maintained.

-- 
[======================================================================]
[     Kevin Lentin               Email: K.Lentin@cs.monash.edu.au      ]
[   finger kevinl@fangorn.cs.monash.edu.au for PGP public key block.   ]
[  KeyId: 06808EED    FingerPrint: 6024308DE1F84314  811B511DBA6FD596  ]
[======================================================================]

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu