From patchwork Tue Jan 25 10:21:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Niedermayer X-Patchwork-Id: 33839 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6602:2c4e:0:0:0:0 with SMTP id x14csp494161iov; Tue, 25 Jan 2022 02:27:54 -0800 (PST) X-Google-Smtp-Source: ABdhPJzDLKn6wXutAjmIdctxs0LojhVY8/ZOzWo4kPgDOQ76R4YSiZxufngxEYuNjwDm/oOlrDhi X-Received: by 2002:aa7:cc83:: with SMTP id p3mr19354551edt.382.1643106474362; Tue, 25 Jan 2022 02:27:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643106474; cv=none; d=google.com; s=arc-20160816; b=x6y6hOGnPZu2x9VP4eiZ75HbQVNmCAjHpt4AYBMnmnA66hASeTaxJho+Crqkhfl1uI mEmWH27t2A+GhRy/PLvvPe2E/g+I318RqQ9dqUqWWLpVCAGqWht5GoA27fluFQHDNtzt pMqDpvgDNnbNeqomuyeaoj5Lv5W/wriHGhjjVqMiFyrvTe/t8Lz2DODab33syd4P3744 /TwvxUrU47IDXTeGs0uVo1IroULQC4BmzNZ7I1jGty+eUAb19DQmvlIBrKElaOGGmK2C 1NiAOX4zq5lZ9ntgvwUtsG9LT7ehCivRfsAXSziCXDs5CcJq3F42pzdpKjhY8mUZSEiq FXcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:delivered-to; bh=PgGsczFZxLnbDjhQtuUvweBFnXLQ9FlRy575cu/djvE=; b=vEp5Kg3ZKmOjjATG9NGmEogtg7bsMwJWmSUUHiMF5iquwDprRZFmQldFIaMhF9bQQD 7MsNF+BuWp66DmAi6nEVQbrpBIvRZGbUqzaTjSdPDiWb/AzjuMtElyLzG5H8kFHCX5+4 ehL3XRdOuhSrAA0rarCH0nvEFGintwZAtWBiQTm16/Dr6cP90ieDCgUw2X+T1p8hSRed lDiHXkADMp1EdV2Hw3SO/uxFKCX4zbtdPBaEK8ogywWpoY82mELzLQjEX03CvPqoN6wB U8y/BBr/uHbSMAY7eyX8HQ2AhfH/koPKuZg/XxA2vrtbTllKWDzEIOYYTuA9jIilFybi dBjA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id c20si9520002ejj.420.2022.01.25.02.27.54; Tue, 25 Jan 2022 02:27:54 -0800 (PST) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0302568B0AE; Tue, 25 Jan 2022 12:27:51 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from vie01a-dmta-pe04-1.mx.upcmail.net (vie01a-dmta-pe04-1.mx.upcmail.net [62.179.121.163]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 4CB0D68AE79 for ; Tue, 25 Jan 2022 12:27:45 +0200 (EET) Received: from [172.31.216.235] (helo=vie01a-pemc-psmtp-pe12.mail.upcmail.net) by vie01a-dmta-pe04.mx.upcmail.net with esmtp (Exim 4.92) (envelope-from ) id 1nCIxl-006wqy-0E for ffmpeg-devel@ffmpeg.org; Tue, 25 Jan 2022 11:22:09 +0100 Received: from localhost ([213.47.68.29]) by vie01a-pemc-psmtp-pe12.mail.upcmail.net with ESMTP id CIwnn6KxgSgGFCIwnnHKlq; Tue, 25 Jan 2022 11:21:09 +0100 X-Env-Mailfrom: michael@niedermayer.cc X-Env-Rcptto: ffmpeg-devel@ffmpeg.org X-SourceIP: 213.47.68.29 X-CNFS-Analysis: v=2.3 cv=f8Q2+96M c=1 sm=1 tr=0 a=2hcxjKEKjp0CzLx6oWAm4g==:117 a=2hcxjKEKjp0CzLx6oWAm4g==:17 a=MKtGQD3n3ToA:10 a=1oJP67jkp3AA:10 a=GEAsPZ9sns4A:10 a=ZZnuYtJkoWoA:10 a=g-c9W3f_86EyvXsXexMA:9 From: Michael Niedermayer To: FFmpeg development discussions and patches Date: Tue, 25 Jan 2022 11:21:08 +0100 Message-Id: <20220125102109.522-1-michael@niedermayer.cc> X-Mailer: git-send-email 2.17.1 X-CMAE-Envelope: MS4wfP/BuDeq29rkRmq8uWK9lY0WvV18CvGdsTglGmRlsYD2m9VYtGTkZdFlYP9FrCaa2VrqOMBvaIlvdZ6LXUBaZn5nL4pcHPnniuWF1scc1yN8PRiqZy7n dIYwXo9+hamVRXzrn+lddwYfYkskqhg+lQAMcYaC4if9Gh6ThAQ0Pld0 Subject: [FFmpeg-devel] [PATCH 1/2] avutil/random_seed: Speed up fate test 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 MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: jsBJphxvlNgJ This decreases the quality of the seeds during the test, it does not affect the seeds outside the test. There is a small chance that this causes test failures, if that happens the threshold needs adjusting Testing on an idle x86_64 system shows that this passes even with the test strength increased to 32768 from 256 with 0 retries So test failures are not anticipated Lowering the threshold from 3 to 2 causes failure at test strength of 32768 Signed-off-by: Michael Niedermayer --- libavutil/random_seed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/random_seed.c b/libavutil/random_seed.c index 70dc509d2f..509b74936c 100644 --- a/libavutil/random_seed.c +++ b/libavutil/random_seed.c @@ -95,7 +95,7 @@ static uint32_t get_generic_seed(void) last_td = t - last_t; buffer[++i & 511] += last_td % 3294638521U; if ((t - init_t) >= CLOCKS_PER_SEC>>5) - if (last_i && i - last_i > 4 || i - last_i > 64 || TEST && i - last_i > 8) + if (last_i && i - last_i > 4 || i - last_i > 64 || TEST && i - last_i > 3) break; } last_t = t;