From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id 6FDD44CD87 for ; Wed, 12 Feb 2025 19:45:33 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2D72E68C02D; Wed, 12 Feb 2025 21:45:29 +0200 (EET) Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 73FB368BB4E for ; Wed, 12 Feb 2025 21:45:22 +0200 (EET) Received: by mail.gandi.net (Postfix) with ESMTPSA id C77CB44417 for ; Wed, 12 Feb 2025 19:45:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1739389521; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=22afiEoZ2GGaJe6VioUqdQQLA/7vZG+ag1dU7irk2dA=; b=iH6WdzA1+CWw+hu8lOSVvjTzTmr4/xTTTVYHPJSda8B85SB/gKOWr710GoJtGkBku5IG0b k3U3iCDVm8/7ZBbbZoz1ciKlNKWdBiVd/H6IvaJw73fjiql1wFJZz2Xpn5B2buIMPlInWC fMiM34q3sObBUT3YrvPhPB70YTpswIpPklsz6j4nHDvEvtmtCQzfKWHPdnQVln1CEgSIM8 7lBJ74Cc/3T+ynKXr7/RNoQFNXP7M0c6v2zox4429++mJHkDXkWMVWKuFRa+c4TLyMIpuf ljwUFS4y4tXzRXqOa7ro1oH7sodmLZ0CuN+vmy9foRcKSbkdfAkeG8xzwaXUhw== Date: Wed, 12 Feb 2025 20:45:20 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20250212194520.GQ4991@pb2> References: <20250205221813.4110398-1-martin@martin.st> <20250205221813.4110398-2-martin@martin.st> <20250206001638.GI4991@pb2> <20250206160443.GT4991@pb2> <317e9c7e-bc5-81dc-f036-9b1426a95b1@martin.st> <20250209222850.GB4991@pb2> <2ddaa6c8-711e-e23c-8d3b-673d2042bf79@martin.st> <20250211234944.GJ4991@pb2> <9cfa4774-50b1-7f98-4f8-e17ad8793dfb@martin.st> MIME-Version: 1.0 In-Reply-To: <9cfa4774-50b1-7f98-4f8-e17ad8793dfb@martin.st> X-GND-State: clean X-GND-Score: -70 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdeggeejiecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucesvcftvggtihhpihgvnhhtshculddquddttddmnegfrhhlucfvnfffucdlfedtmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofhitghhrggvlhcupfhivgguvghrmhgrhigvrhcuoehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgeqnecuggftrfgrthhtvghrnhepudetvdfhudeuudegudefgfehhfevvdfggfffkefhvdfgvdetffdtjeekheetfeehnecukfhppeeguddrieeirdeijedruddufeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeeguddrieeirdeijedruddufedphhgvlhhopehlohgtrghlhhhoshhtpdhmrghilhhfrhhomhepmhhitghhrggvlhesnhhivgguvghrmhgrhigvrhdrtggtpdhnsggprhgtphhtthhopedupdhrtghpthhtohepfhhfmhhpvghgqdguvghvvghlsehffhhmphgvghdrohhrgh X-GND-Sasl: michael@niedermayer.cc Subject: Re: [FFmpeg-devel] [PATCH v2 2/2] random_seed: Improve behaviour with small timer increments with high precision timers X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: multipart/mixed; boundary="===============4254002705206448492==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============4254002705206448492== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="BheNmL6Zaum/d0qi" Content-Disposition: inline --BheNmL6Zaum/d0qi Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Martin On Wed, Feb 12, 2025 at 11:25:03AM +0200, Martin Storsj=F6 wrote: [...] > > Heres an example where the SWAP is needed: > > noswap swap > > 5 -> [x 5] [x 5] > > 4 -> [5 4] [5 4] > > 5 -> [5 4] [4 5] > > 6 -> [4 6] [5 6] > > 5 -> [6 5] [6 5] > >=20 > > In the last case the 5 is in the old* when the swap was used but not > > when it was not used >=20 > Sorry, but your examples do not make sense or do not contain enough conte= xt > (it does not include the initial states of the two old values, and it > requires guesswork which ones of the two [x y] values is old and which one > is old2). >=20 > But to be clear: >=20 > Please specify the initial values of the variables new, old and old2, for= a > case where >=20 > > > if (old2 =3D=3D new) { > > > FFSWAP(old,old2); > > > } else if (old !=3D new) { > > > old2 =3D old; > > > old =3D new; > > > } >=20 > produces a different end result than >=20 > > > if (old !=3D new) { > > > old2 =3D old; > > > old =3D new; > > > } >=20 > I claim that for any values of these variables, the end result is the sam= e. yes, you are correct, i thought you intended to run the old2/old update onl= y if new differs from both old and old2. The actual code you wrote is fine and nicely optimizes the swap out thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB The worst form of inequality is to try to make unequal things equal. -- Aristotle --BheNmL6Zaum/d0qi Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEKAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCZ6z6TQAKCRBhHseHBAsP q++sAKCVcWykVmfhiGPlC4ZSOSN+t1M+3wCfQ+lytTEQNbx0gn4BH4IjZClsWig= =yVp/ -----END PGP SIGNATURE----- --BheNmL6Zaum/d0qi-- --===============4254002705206448492== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". --===============4254002705206448492==--