Makefile.in (OBJS): Remove matrix-reorg.o.

2012-08-10  Richard Guenther  <rguenther@suse.de>

	* Makefile.in (OBJS): Remove matrix-reorg.o.
	(matrix-reorg.o): Remove dependence rule.
	(GTFILES): Remove matrix-reorg.c.
	* matrix-reorg.c: Remove.
	* passes.c (init_optimization_passes): Do not schedule
	pass_ipa_matrix_reorg.
	* tree-pass.h (pass_ipa_matrix_reorg): Remove.
	* common.opt (fipa-matrix-reorg): Stub out.
	* doc/invoke.texi (fipa-matrix-reorg): Remove documentation.

	* gcc.dg/matrix/*.c: Adjust and move ...
	* gcc.dg/torture/: ... here.
	* gcc.dg/matrix: Remove directory.

From-SVN: r190298
This commit is contained in:
Richard Guenther 2012-08-10 14:19:09 +00:00 committed by Richard Biener
parent 09e4850d7e
commit 04f92ff4fc
21 changed files with 46 additions and 2514 deletions

View File

@ -1,3 +1,15 @@
2012-08-10 Richard Guenther <rguenther@suse.de>
* Makefile.in (OBJS): Remove matrix-reorg.o.
(matrix-reorg.o): Remove dependence rule.
(GTFILES): Remove matrix-reorg.c.
* matrix-reorg.c: Remove.
* passes.c (init_optimization_passes): Do not schedule
pass_ipa_matrix_reorg.
* tree-pass.h (pass_ipa_matrix_reorg): Remove.
* common.opt (fipa-matrix-reorg): Stub out.
* doc/invoke.texi (fipa-matrix-reorg): Remove documentation.
2012-08-10 Richard Guenther <rguenther@suse.de>
PR middle-end/54219

View File

@ -1301,7 +1301,6 @@ OBJS = \
lto-symtab.o \
lto-opts.o \
lto-compress.o \
matrix-reorg.o \
mcf.o \
mode-switching.o \
modulo-sched.o \
@ -2893,13 +2892,6 @@ ipa-split.o : ipa-split.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(TREE_H) $(TARGET_H) $(CGRAPH_H) $(IPA_PROP_H) $(TREE_FLOW_H) \
$(TREE_PASS_H) $(FLAGS_H) $(DIAGNOSTIC_H) $(TREE_DUMP_H) \
$(TREE_INLINE_H) $(PARAMS_H) $(GIMPLE_PRETTY_PRINT_H) ipa-inline.h
matrix-reorg.o : matrix-reorg.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(TM_H) $(TREE_H) $(RTL_H) $(TREE_INLINE_H) $(TREE_FLOW_H) \
tree-flow-inline.h langhooks.h $(HASHTAB_H) $(DIAGNOSTIC_CORE_H) $(FLAGS_H) $(GGC_H) \
debug.h $(TARGET_H) $(CGRAPH_H) $(DIAGNOSTIC_CORE_H) \
$(PARAMS_H) intl.h $(FUNCTION_H) $(BASIC_BLOCK_H) \
$(CFGLOOP_H) tree-iterator.h $(TREE_PASS_H) $(OPTS_H) $(TREE_DATA_REF_H) \
tree-ssa-sccvn.h
ipa-inline.o : ipa-inline.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TREE_H) langhooks.h $(TREE_INLINE_H) $(FLAGS_H) $(CGRAPH_H) intl.h \
$(DIAGNOSTIC_H) $(FIBHEAP_H) $(PARAMS_H) $(TREE_PASS_H) \
@ -3657,7 +3649,7 @@ GTFILES = $(CPP_ID_DATA_H) $(srcdir)/input.h $(srcdir)/coretypes.h \
$(srcdir)/cselib.h $(srcdir)/basic-block.h $(srcdir)/ipa-ref.h $(srcdir)/cgraph.h \
$(srcdir)/reload.h $(srcdir)/caller-save.c $(srcdir)/symtab.c \
$(srcdir)/alias.c $(srcdir)/bitmap.c $(srcdir)/cselib.c $(srcdir)/cgraph.c \
$(srcdir)/ipa-prop.c $(srcdir)/ipa-cp.c $(srcdir)/matrix-reorg.c \
$(srcdir)/ipa-prop.c $(srcdir)/ipa-cp.c \
$(srcdir)/dbxout.c \
$(srcdir)/dwarf2out.h \
$(srcdir)/dwarf2asm.c \

View File

@ -1349,9 +1349,8 @@ Common Report Var(flag_ipa_reference) Init(0) Optimization
Discover readonly and non addressable static variables
fipa-matrix-reorg
Common Report Var(flag_ipa_matrix_reorg) Optimization
Perform matrix layout flattening and transposing based
on profiling information.
Common Ignore
Does nothing. Preserved for backward compatibility.
fipa-struct-reorg
Common Ignore

View File

@ -367,7 +367,7 @@ Objective-C and Objective-C++ Dialects}.
-fgcse-sm -fhoist-adjacent-loads -fif-conversion @gol
-fif-conversion2 -findirect-inlining @gol
-finline-functions -finline-functions-called-once -finline-limit=@var{n} @gol
-finline-small-functions -fipa-cp -fipa-cp-clone -fipa-matrix-reorg @gol
-finline-small-functions -fipa-cp -fipa-cp-clone @gol
-fipa-pta -fipa-profile -fipa-pure-const -fipa-reference @gol
-fira-algorithm=@var{algorithm} @gol
-fira-region=@var{region} @gol
@ -7195,18 +7195,6 @@ it may significantly increase code size
(see @option{--param ipcp-unit-growth=@var{value}}).
This flag is enabled by default at @option{-O3}.
@item -fipa-matrix-reorg
@opindex fipa-matrix-reorg
Perform matrix flattening and transposing.
Matrix flattening tries to replace an @math{m}-dimensional matrix
with its equivalent @math{n}-dimensional matrix, where @math{n < m}.
This reduces the level of indirection needed for accessing the elements
of the matrix. The second optimization is matrix transposing, which
attempts to change the order of the matrix's dimensions in order to
improve cache locality.
Both optimizations need the @option{-fwhole-program} flag.
Transposing is enabled only if profiling information is available.
@item -ftree-sink
@opindex ftree-sink
Perform forward store motion on trees. This flag is

File diff suppressed because it is too large Load Diff

View File

@ -1330,7 +1330,6 @@ init_optimization_passes (void)
NEXT_PASS (pass_feedback_split_functions);
}
NEXT_PASS (pass_ipa_increase_alignment);
NEXT_PASS (pass_ipa_matrix_reorg);
NEXT_PASS (pass_ipa_tm);
NEXT_PASS (pass_ipa_lower_emutls);
*p = NULL;

View File

@ -1,3 +1,9 @@
2012-08-10 Richard Guenther <rguenther@suse.de>
* gcc.dg/matrix/*.c: Adjust and move ...
* gcc.dg/torture/: ... here.
* gcc.dg/matrix: Remove directory.
2012-08-10 Richard Guenther <rguenther@suse.de>
PR middle-end/54219

View File

@ -1,67 +0,0 @@
# Copyright (C) 2001, 2002, 2004, 2005, 2007, 2010, 2011
# 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
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GCC; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
# Test the functionality of programs compiled with profile-directed block
# ordering using -fprofile-generate followed by -fbranch-use.
load_lib gcc-dg.exp
load_lib target-supports.exp
set DEFAULT_MATCFLAGS "-O3 -fipa-matrix-reorg -fdump-ipa-matrix-reorg -fwhole-program -fno-tree-fre"
# Initialize `dg'.
dg-init
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/matrix-\[1-6\].\[cS\]]] \
"" $DEFAULT_MATCFLAGS
dg-final
# Some targets don't support tree profiling.
if { ![check_profiling_available "-fprofile-generate"] } {
return
}
# The procedures in profopt.exp need these parameters.
set tool gcc
set prof_ext "gcda"
if $tracelevel then {
strace $tracelevel
}
# Load support procs.
load_lib profopt.exp
# Save and override the default list defined in profopt.exp.
set matrix_save_profopt_options $PROFOPT_OPTIONS
set PROFOPT_OPTIONS [list {}]
# These are globals used by profopt-execute. The first is options
# needed to generate profile data, the second is options to use the
# profile data.
set profile_option "-fprofile-generate -O3 -fno-tree-fre"
set feedback_option "-fprofile-use -fipa-matrix-reorg -fdump-ipa-matrix-reorg -O3 -fwhole-program -fno-tree-fre"
foreach src [lsort [glob -nocomplain $srcdir/$subdir/transpose-*.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
}
set PROFOPT_OPTIONS $matrix_save_profopt_options

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
@ -88,5 +88,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
@ -111,5 +111,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened 2 dimensions" 1 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -95,5 +95,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened 2 dimensions" 1 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -93,5 +93,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened" 0 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,5 +1,5 @@
/* { dg-do compile } */
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
@ -94,5 +94,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened" 0 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,4 +1,5 @@
/* { dg-do compile } */
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
@ -40,7 +41,8 @@ main (int argc, char **argv)
}
for (i = 0; i < ARCHnodes; i++)
for (j = 0; j < 3; j++)
free (vel[i][j]);
if (!(i == 1 && j == 0))
free (vel[i][j]);
for (i = 0; i < ARCHnodes; i++)
free (vel[i]);
@ -93,5 +95,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final { scan-ipa-dump-times "Flattened 2 dimensions" 1 "matrix-reorg" } } */
/* { dg-final { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,6 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -92,7 +95,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 3 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,5 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
@ -90,6 +92,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 0 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,6 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -96,6 +99,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 2 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 2 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,6 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -95,6 +98,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 2 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,6 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -91,6 +94,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 0 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -1,3 +1,6 @@
/* { dg-do run } */
/* { dg-options "-fwhole-program" } */
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -91,6 +94,3 @@ mem_init (void)
}
/*--------------------------------------------------------------------------*/
/* { dg-final-use { scan-ipa-dump-times "Flattened 3 dimensions" 1 "matrix-reorg" } } */
/* { dg-final-use { scan-ipa-dump-times "Transposed" 0 "matrix-reorg" } } */
/* { dg-final-use { cleanup-ipa-dump "matrix-reorg" } } */

View File

@ -372,7 +372,6 @@ extern struct simple_ipa_opt_pass pass_early_local_passes;
extern struct ipa_opt_pass_d pass_ipa_whole_program_visibility;
extern struct ipa_opt_pass_d pass_ipa_lto_gimple_out;
extern struct simple_ipa_opt_pass pass_ipa_increase_alignment;
extern struct simple_ipa_opt_pass pass_ipa_matrix_reorg;
extern struct ipa_opt_pass_d pass_ipa_inline;
extern struct simple_ipa_opt_pass pass_ipa_free_lang_data;
extern struct simple_ipa_opt_pass pass_ipa_free_inline_summary;