From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Marius Vollmer Newsgroups: gmane.lisp.guile.user Subject: Re: Sort on vectors slow Date: Wed, 20 Oct 2004 00:28:09 +0200 Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Message-ID: <877jpm8hs6.fsf@zagadka.ping.de> References: <1097756911.5279.3531.camel@localhost> <87brey8jog.fsf@zagadka.ping.de> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1098224915 10293 80.91.229.6 (19 Oct 2004 22:28:35 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 19 Oct 2004 22:28:35 +0000 (UTC) Cc: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Wed Oct 20 00:28:28 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CK2Sx-0004Gd-00 for ; Wed, 20 Oct 2004 00:28:27 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CK2aJ-0000q6-4T for guile-user@m.gmane.org; Tue, 19 Oct 2004 18:36:03 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CK2aE-0000oV-TL for guile-user@gnu.org; Tue, 19 Oct 2004 18:35:58 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CK2aE-0000nw-CQ for guile-user@gnu.org; Tue, 19 Oct 2004 18:35:58 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CK2aE-0000no-9R for guile-user@gnu.org; Tue, 19 Oct 2004 18:35:58 -0400 Original-Received: from [195.253.8.218] (helo=mail.dokom.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CK2Sh-0007uC-Ia for guile-user@gnu.org; Tue, 19 Oct 2004 18:28:11 -0400 Original-Received: from [195.138.42.165] (helo=zagadka.ping.de) by mail.dokom.net with smtp (Exim 4.34) id 1CK2Sg-0002iV-LA for guile-user@gnu.org; Wed, 20 Oct 2004 00:28:10 +0200 Original-Received: (qmail 21209 invoked by uid 1000); 19 Oct 2004 22:28:09 -0000 Original-To: Roland Orre In-Reply-To: <87brey8jog.fsf@zagadka.ping.de> (Marius Vollmer's message of "Tue, 19 Oct 2004 23:47:11 +0200") User-Agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux) X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: main.gmane.org gmane.lisp.guile.user:3603 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.user:3603 Marius Vollmer writes: > Now, time to get out the Knuth... Wasn't needed after all... it turned out that our quicksort was always using base_ptr[mid] as the pivot and did not take into account that the "collaps the walls" loop might overwrite that location, thus incorrectly changing the pivot during collapsing. I have fixed this by copying out the pivot into a local variable. 'sort' and 'sort!' should now work reasonably also for large vectors. -- GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405 _______________________________________________ Guile-user mailing list Guile-user@gnu.org http://lists.gnu.org/mailman/listinfo/guile-user