diff options
author | fche <fche@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-09-16 20:37:09 +0000 |
---|---|---|
committer | fche <fche@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-09-16 20:37:09 +0000 |
commit | 6ab3444ba2be989344d53d83999ce6a64fe15465 (patch) | |
tree | 3ef0fc16fc871b1fa7bb6b7cfcf47b60e184390c /gcc/testsuite/gcc.misc-tests | |
parent | dd2d357d725d0584196a8afb67d48eb8e318b5fa (diff) | |
download | gcc-6ab3444ba2be989344d53d83999ce6a64fe15465.tar.gz |
2004-09-16 Frank Ch. Eigler <fche@redhat.com>
* gcc.misc-tests/bprob.exp, g++.dg/bprob/bprob.exp: Iterate tests
with -ftree-based-profiling also.
* lib/profopt.exp: Support late-set profile_option/feedback_option.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@87612 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.misc-tests')
-rw-r--r-- | gcc/testsuite/gcc.misc-tests/bprob.exp | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/gcc/testsuite/gcc.misc-tests/bprob.exp b/gcc/testsuite/gcc.misc-tests/bprob.exp index 8fde6829f83..554bf76dde9 100644 --- a/gcc/testsuite/gcc.misc-tests/bprob.exp +++ b/gcc/testsuite/gcc.misc-tests/bprob.exp @@ -1,4 +1,4 @@ -# Copyright (C) 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -27,8 +27,6 @@ if { ![check_profiling_available "-fprofile-arcs"] } { # The procedures in profopt.exp need these parameters. set tool gcc -set profile_option -fprofile-arcs -set feedback_option -fbranch-probabilities set prof_ext gcda set perf_ext tim @@ -49,11 +47,19 @@ if $tracelevel then { # Load support procs. load_lib profopt.exp -foreach src [lsort [glob -nocomplain $srcdir/$subdir/bprob-*.c]] { - # If we're only testing specific files and this isn't one of them, skip it. - if ![runtest_file_p $runtests $src] then { - continue - } +set profile_options "-fprofile-arcs" +set feedback_options "-fbranch-probabilities" +if {[check_profiling_available "-ftree-based-profiling"]} { + lappend profile_options "-ftree-based-profiling -fprofile-arcs" + lappend feedback_options "-ftree-based-profiling -fbranch-probabilities" +} - profopt-execute $src +foreach profile_option $profile_options feedback_option $feedback_options { + foreach src [lsort [glob -nocomplain $srcdir/$subdir/bprob-*.c]] { + # If we're only testing specific files and this isn't one of them, skip it. + if ![runtest_file_p $runtests $src] then { + continue + } + profopt-execute $src + } } |