[patch] Lno branch merge part 8 -- canonical induction variable creation
Zdenek Dvorak
rakdver@atrey.karlin.mff.cuni.cz
Sat Aug 21 23:21:00 GMT 2004
Hello,
> Again your points "1)" and "2)" above show the confusion. We really,
> need a way to say
>
> 1) doesn't overflow.
> 2) undefined on overflow.
> 3) overflow wraps around using 2's complement arithmetic.
> 4) trap on overflow.
not really. We basically just speak in different words about the same
thing:
> 1) Wrapping -- i.e. the compiler cannot assume anything about it.
is yours 3); is there a reason why we should support a different
wrap semantics?
> 2) Wrap undefined -- i.e. compiler can assume it does not wrap if it
> wants to.
is union of yours 1) and 2). Is there a reason why to distinguish
between "doesn't overflow" and "undefined on overflow" -- i.e. are
there optimizations that could benefit from postulating a different
wrap semantics?
> 3) Trapping -- i.e. the compiler not only assumes it does not wrap,
> but also adds check for it.
is yours 4)
Zdenek
More information about the Gcc-patches
mailing list