From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 79887 invoked by alias); 11 Apr 2015 11:50:55 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 79868 invoked by uid 89); 11 Apr 2015 11:50:55 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,SPF_HELO_PASS,T_RP_MATCHES_RCVD autolearn=no version=3.3.2 X-Spam-User: qpsmtpd, 2 recipients X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Sat, 11 Apr 2015 11:50:54 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t3BBorMC002580 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sat, 11 Apr 2015 07:50:53 -0400 Received: from localhost (ovpn-116-37.ams2.redhat.com [10.36.116.37]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t3BBoqnG016187; Sat, 11 Apr 2015 07:50:52 -0400 Date: Sat, 11 Apr 2015 11:50:00 -0000 From: Jonathan Wakely To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: Re: [patch] libstdc++/58038 libstdc++/60421 fix overflows in std::this_thread::sleep_for() Message-ID: <20150411115051.GE9755@redhat.com> References: <20150326195919.GM9755@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20150326195919.GM9755@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SW-Source: 2015-04/txt/msg00496.txt.bz2 On 26/03/15 19:59 +0000, Jonathan Wakely wrote: >We have a couple of bugs where durations with unsigned representations >result in negative or huge time_t values, which result in not sleeping >at all or sleeping for billions of years (or merely for decades if you >have a 32-bit time_t). > >This change simply returns early for time points in the past or >negative durations. > >Tested x86_64-linux, powerpc64le-linux, committed to trunk. Also committed to the 4.9 branch.