From patchwork Thu Aug 1 21:11:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Wakely X-Patchwork-Id: 1968041 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=gdW8/v0h; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4WZhW31bhVz1yZl for ; Fri, 2 Aug 2024 07:12:31 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 16756385DDC4 for ; Thu, 1 Aug 2024 21:12:23 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id 4B9723858C41 for ; Thu, 1 Aug 2024 21:11:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4B9723858C41 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4B9723858C41 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722546718; cv=none; b=ZvvQoCjYaPmAT8qyo5a67EksZGeZ1oxT3mclvSl4t/LKmnhiyrKCf769gqFl1YWFejIoi0fu7+O3s3PnEG0DalVvvMoov/Rl0sG4uOYDCVNq2oDEB7Z/EzyNeHiiOG4Ukto9oxPzO37jI+W0rCuLWnKUORHbXFdM7tT0zqD18vQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722546718; c=relaxed/simple; bh=kTZaGDkYDX044ZDV7oHs/HlSikvJYG6qcSx0X4feLHA=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=YLxSFnUbCUftgy4qx3hX1SouAkigTtvnz1jsoKQ4xaes9oiY5mes1DHADFN8ttAhdKNPuEV4bm1xERPRaQHVFTlokVch9V5/JYqDrHwPuSEf9eqoFs8Uj8rECwZtxcJYOkre77wBiziq0sDzdLoVD6GKf23IyPMtVg1poqErWro= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1722546708; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DWxl8WOAG4n2oJ02vD/AOEM5QPJnDAGFENmmtx7ANH8=; b=gdW8/v0hJxr/dhiqgC9ukNNPJuMq5Vtva250VnIWUQeAZOd8QBK2W/O+g62rLlfjMeEbMf PAMHriv6zWuGoZpDbBaLVafsRSr4eGCzmANH5VGpcSLbTkIkz/dnAJdBvmPRVOPS3nl4By zRho1WbuGFwD8uVUS7zXqtqjK6y8OTo= Received: from mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-428-c1MHxDvmP0G8lUMwK5mRdw-1; Thu, 01 Aug 2024 17:11:45 -0400 X-MC-Unique: c1MHxDvmP0G8lUMwK5mRdw-1 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 73F8D1955BED; Thu, 1 Aug 2024 21:11:44 +0000 (UTC) Received: from localhost (unknown [10.42.28.21]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 71ED9300018D; Thu, 1 Aug 2024 21:11:42 +0000 (UTC) From: Jonathan Wakely To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: [committed] libstdc++: Fix incomplete change to reduce iterations for simulators Date: Thu, 1 Aug 2024 22:11:25 +0100 Message-ID: <20240801211141.386410-1-jwakely@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org Tested x86_64-linux. Pushed to trunk. -- >8 -- This should have been done as part of r13-693-ge3b8b4f7814c54, but I only added the preprocessor logic and didn't use ARGS in the code. libstdc++-v3/ChangeLog: * testsuite/26_numerics/random/discrete_distribution/operators/values.cc: Use ARGS to limit number of iterations for simulators. --- .../random/discrete_distribution/operators/values.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libstdc++-v3/testsuite/26_numerics/random/discrete_distribution/operators/values.cc b/libstdc++-v3/testsuite/26_numerics/random/discrete_distribution/operators/values.cc index 3cfe0d69f40..a6a2e713d3e 100644 --- a/libstdc++-v3/testsuite/26_numerics/random/discrete_distribution/operators/values.cc +++ b/libstdc++-v3/testsuite/26_numerics/random/discrete_distribution/operators/values.cc @@ -40,16 +40,16 @@ void test01() std::discrete_distribution<> dd1({ }); auto bdd1 = std::bind(dd1, eng); - testDiscreteDist(bdd1, [](int n) { return discrete_pdf(n, { }); } ); + testDiscreteDist(bdd1, [](int n) { return discrete_pdf(n, { }); } ); std::discrete_distribution<> dd2({ 1.0, 3.0, 2.0}); auto bdd2 = std::bind(dd2, eng); - testDiscreteDist(bdd2, [](int n) + testDiscreteDist(bdd2, [](int n) { return discrete_pdf(n, { 1.0, 3.0, 2.0}); } ); std::discrete_distribution<> dd3({ 2.0, 2.0, 1.0, 0.0, 4.0}); auto bdd3 = std::bind(dd3, eng); - testDiscreteDist(bdd3, [](int n) + testDiscreteDist(bdd3, [](int n) { return discrete_pdf(n, { 2.0, 2.0, 1.0, 0.0, 4.0}); } ); }