From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH v3 0/3] automatically skip away from broken commits Date: Wed, 10 Jun 2009 21:43:09 -0700 Message-ID: <4A308B5D.2010704@zytor.com> References: <20090606043853.4031.78284.chriscool@tuxfamily.org> <7vtz2nlrfs.fsf@alter.siamese.dyndns.org> <200906110602.54861.chriscool@tuxfamily.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: Junio C Hamano , Christian Couder , git@vger.kernel.org, Sam Vilain , Ingo Molnar To: Christian Couder X-From: git-owner@vger.kernel.org Thu Jun 11 06:45:50 2009 Return-path: Envelope-to: gcvg-git-2@gmane.org Received: from vger.kernel.org ([209.132.176.167]) by lo.gmane.org with esmtp (Exim 4.50) id 1MEcAf-0001wv-S6 for gcvg-git-2@gmane.org; Thu, 11 Jun 2009 06:45:50 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755521AbZFKEn0 (ORCPT ); Thu, 11 Jun 2009 00:43:26 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755223AbZFKEnZ (ORCPT ); Thu, 11 Jun 2009 00:43:25 -0400 Received: from terminus.zytor.com ([198.137.202.10]:40967 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753927AbZFKEnZ (ORCPT ); Thu, 11 Jun 2009 00:43:25 -0400 Received: from mail.hos.anvin.org (c-98-210-181-100.hsd1.ca.comcast.net [98.210.181.100]) (authenticated bits=0) by terminus.zytor.com (8.14.3/8.14.1) with ESMTP id n5B4hCPX006044 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Jun 2009 21:43:13 -0700 Received: from tazenda.hos.anvin.org (tazenda.hos.anvin.org [172.27.0.16]) by mail.hos.anvin.org (8.14.3/8.14.3) with ESMTP id n5B4hCCR030361; Wed, 10 Jun 2009 21:43:12 -0700 Received: from tazenda.hos.anvin.org (localhost.localdomain [127.0.0.1]) by tazenda.hos.anvin.org (8.14.3/8.13.6) with ESMTP id n5B4h9Mn032191; Wed, 10 Jun 2009 21:43:10 -0700 User-Agent: Thunderbird 2.0.0.14 (X11/20080501) In-Reply-To: <200906110602.54861.chriscool@tuxfamily.org> X-Virus-Scanned: ClamAV 0.94.2/9451/Wed Jun 10 11:05:54 2009 on terminus.zytor.com X-Virus-Status: Clean Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Archived-At: Christian Couder wrote: > > I think my algorithm is better enough than a random one to be worth using by > default. Like HPA says it's in practice like a random one with a bias. > But it's a really poor such. Using an actual biased PRNG will give the best of both variants (a bias to prefer better commits, and still all commits reachable.) After playing around with Wolfram Alpha for way too long, it seems that a suitable bias function would be to take the fourth root of the PRNG value, i.e. raise it to the power 0.25. -hpa -- H. Peter Anvin, Intel Open Source Technology Center I work for Intel. I don't speak on their behalf.