X-Original-To: pgsql-hackers@postgresql.org Received: from spampd.localdomain (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id BB5B0476344 for ; Fri, 18 Apr 2003 02:06:07 -0400 (EDT) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id E593E476342 for ; Fri, 18 Apr 2003 02:06:04 -0400 (EDT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.9/8.12.9) with ESMTP id h3I664U6001967; Fri, 18 Apr 2003 02:06:05 -0400 (EDT) To: Stephan Szabo Cc: Kevin Brown , pgsql-hackers@postgresql.org, pgsql-performance@postgresql.org Subject: Re: [PERFORM] Foreign key performance In-reply-to: <20030417222628.G97462-100000@megazone23.bigpanda.com> References: <20030417222628.G97462-100000@megazone23.bigpanda.com> Comments: In-reply-to Stephan Szabo message dated "Thu, 17 Apr 2003 22:30:45 -0700" Date: Fri, 18 Apr 2003 02:06:04 -0400 Message-ID: <1966.1050645964@sss.pgh.pa.us> From: Tom Lane X-Spam-Status: No, hits=-32.3 required=5.0 tests=BAYES_00,EMAIL_ATTRIBUTION,IN_REP_TO,QUOTED_EMAIL_TEXT, REFERENCES,REPLY_WITH_QUOTES autolearn=ham version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) X-Archive-Number: 200304/683 X-Sequence-Number: 38173 Stephan Szabo writes: > It appears (from some not terribly scientific experiments - see below) > that it's likely to be related to managing the deferred trigger queue > given that in my case at least running the constraints non-deferred was > negligible in comparison. At one time the deferred-trigger queue had an O(N^2) behavioral problem for large N = number of pending trigger events. But I thought we'd fixed that. What's the test case exactly? Can you get a profile with gprof? regards, tom lane