[FFmpeg-devel] [RFC] Sechole in gcc 3.3+ and 4.*

Michael Niedermayer michaelni
Mon Apr 7 16:30:59 CEST 2008


On Mon, Apr 07, 2008 at 04:58:30PM +0300, Uoti Urpala wrote:
> On Mon, 2008-04-07 at 15:42 +0200, Michael Niedermayer wrote:
> > Above defines strictly how signed integers are represented on twos complement
> > systems. As a side effect this requires the +-* operations to be identical to
> > unsigned integers.
> 
> It does not. There is (rather obviously IMO) no requirement that if A
> and B have different types but the same representation, and similarly C
> and D, then A+C would need to have the same representation as B+D.

Each value within the supported range has a clear repesentation and each
representation has a clear value. The value of A+C and B+D are defined
by the arithmetic in Z/nZ n=2^m 
As they have clear values which are within the supported range their
representations are clear and equal.

>From this it follows that for all inputs within the supported range the
outputs match thus the operations are per definition identical.

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080407/9726c13c/attachment.pgp>



More information about the ffmpeg-devel mailing list