Commit Message

On 18 Dec 2010, at 18:58, Mike Stump wrote:
> On Dec 17, 2010, at 1:37 AM, IainS wrote:>> This has now been regstrapped on *-darwin9 and x86_64-darwin10.>>>> There are outstanding issues with -freorder-blocks-and-partition >> (on Darwin, at least) which results in the fail of partition2.C on >> Darwin10.>> :-( I kinda hate regressions.... and the opt.c change I kinda wish > were broken out, either, it goes in first, or it goes in second.
makes sense... see below.
> Normally, I'd say since I think the changes for the two remaining > problems are well underway, I'd propose to stage in the fixes for > those first, before the below goes in, so that when it does go in, > there are no regressions, but, the problem with that is this patch > is to `fix' regressions, and as I said, I hate regressions....>> so...>>> OK for trunk?>> Ok.
So, to address your concerns...
I applied two patches - the first to fix the regressions with the
addition of:
/* FIXME: Darwin cannot support multiple function sections until
(a) the new code
atoms created have a proper start label and (b) there are
suitable pubnames
emitted. This applies to all current Darwin versions (OSX <=
10.6.5). */
if (global_options.x_flag_reorder_blocks_and_partition)
{
inform (input_location,
"-freorder-blocks-and-partition is currently disabled for this "
"platform");
flag_reorder_blocks_and_partition = 0;
flag_reorder_blocks = 1;
}
which is a bit brutal - probably we could just disable for debug
cases .. but, since we have fixes in the pipeline for (a) and (b) ...
... this should ensure that no regressions occur with the application
of the second patch (opts.c).
Index: gcc/ChangeLog
===================================================================
--- gcc/ChangeLog (revision 168083)
+++ gcc/ChangeLog (working copy)
@@ -1,5 +1,12 @@
2010-12-20 Iain Sandoe <iains@gcc.gnu.org>
+ Jan Hubicka <jh@suse.cz>
+ PR middle-end/46916
+ * opts.c (finish_options): Enable -freorder-functions
+ when -freorder-blocks-and-partition is active.
+
+2010-12-20 Iain Sandoe <iains@gcc.gnu.org>
+
PR c++/46904
PR middle-end/46916
PR target/46950
Index: gcc/opts.c
===================================================================
--- gcc/opts.c (revision 168083)
+++ gcc/opts.c (working copy)
@@ -755,6 +755,10 @@ finish_options (struct gcc_options *opts, struct g
opts->x_flag_reorder_blocks = 1;
}
+ if (opts->x_flag_reorder_blocks_and_partition
+ && !opts_set->x_flag_reorder_functions)
+ opts->x_flag_reorder_functions = 1;
+
/* Pipelining of outer loops is only possible when general pipelining
capabilities are requested. */
if (!opts->x_flag_sel_sched_pipelining)
cheers
Iain

Comments

On Dec 20, 2010, at 2:19 AM, IainS <developer@sandoe-acoustics.co.uk> wrote:
> On 18 Dec 2010, at 18:58, Mike Stump wrote:> >> On Dec 17, 2010, at 1:37 AM, IainS wrote:>>> This has now been regstrapped on *-darwin9 and x86_64-darwin10.>>> >>> There are outstanding issues with -freorder-blocks-and-partition (on Darwin, at least) which results in the fail of partition2.C on Darwin10.>> >> :-( I kinda hate regressions.... and the opt.c change I kinda wish were broken out, either, it goes in first, or it goes in second.> > makes sense... see below.> >> Normally, I'd say since I think the changes for the two remaining problems are well underway, I'd propose to stage in the fixes for those first, before the below goes in, so that when it does go in, there are no regressions, but, the problem with that is this patch is to `fix' regressions, and as I said, I hate regressions....>> >> so...>> >>> OK for trunk?>> >> Ok.> > So, to address your concerns...> > I applied two patches - the first to fix the regressions
Ok, thanks.
>