From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2937 invoked by alias); 17 Feb 2014 14:29:02 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 2899 invoked by uid 48); 17 Feb 2014 14:28:58 -0000 From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug ipa/60243] New: IPA is slow on large cgraph tree Date: Mon, 17 Feb 2014 14:29:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ipa X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: compile-time-hog X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status keywords bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-02/txt/msg01698.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60243 Bug ID: 60243 Summary: IPA is slow on large cgraph tree Product: gcc Version: 4.9.0 Status: UNCONFIRMED Keywords: compile-time-hog Severity: normal Priority: P3 Component: ipa Assignee: unassigned at gcc dot gnu.org Reporter: rguenth at gcc dot gnu.org I've built that testcase to show quadraticness in ipa_modify_call_arguments calls to update_ssa: #!/bin/sh for i in `seq $1`; do echo "static void test$i (int);" done for i in `seq $1`; do echo "void test$i (int i) {" echo "asm (\"\":::\"memory\");" for j in `seq $i $1`; do if ! test $i == $j; then echo "test$j (i);" fi done echo "}" done echo "int main() { test1 (5); return 0; }" but curiously I see (for 1000 and using 4.8): ipa inlining heuristics : 2.78 ( 6%) usr 0.02 ( 0%) sys 2.80 ( 5%) wall 1546 kB ( 0%) ggc ipa profile : 14.34 (29%) usr 0.01 ( 0%) sys 14.35 (25%) wall 0 kB ( 0%) ggc ipa SRA : 2.32 ( 5%) usr 2.09 (34%) sys 4.49 ( 8%) wall 281101 kB (32%) ggc tree SSA rewrite : 0.54 ( 1%) usr 0.68 (11%) sys 1.99 ( 4%) wall 87933 kB (10%) ggc tree SSA incremental : 0.02 ( 0%) usr 0.02 ( 0%) sys 0.07 ( 0%) wall 0 kB ( 0%) ggc TOTAL : 49.83 6.10 56.55 883870 kB that's because all affected bodies are not yet in SSA form ... heh. So that part may not be a real issue. But the IPA profile part? At -O2?