[patch, fortran] PR 40628, front-end optimization pass

Thomas Koenig tkoenig@netcologne.de
Sat Jul 17 18:38:00 GMT 2010


Hello world,

finally, here's the first attempt at a front-end optimization pass.
Right now, it fixes PR 40626 and optimizes comparisons between variables
(which only really is relevant for character comparisons).  Many more
things could (and should) be added over time.

This now passes regression-testing for trunk.

OK for trunk?

	Thomas

2010-0717  Thomas Koenig  <tkoenig@gcc.gnu.org>

	* Make-lang.in:  Add fortran/optimize.o.
	* gfortran.h:  Add prototype for gfc_optimize_namespace.
	* trans-decl.c (gfc_generate_function_code):  If optimizing,
	call gfc_optimize_namespace.
	* optimize.c:  New file.

2010-0717  Thomas Koenig  <tkoenig@gcc.gnu.org>

	* trim_optimize_1.f90:  New test.
	* character_comparision_1.f90:  New test.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: optimize.c
Type: text/x-csrc
Size: 9152 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20100717/44b1aefa/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: opt-1.diff
Type: text/x-patch
Size: 1230 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20100717/44b1aefa/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: character_comparison_1.f90
Type: text/x-fortran
Size: 825 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20100717/44b1aefa/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: trim_optimize_1.f90
Type: text/x-fortran
Size: 410 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20100717/44b1aefa/attachment-0003.bin>


More information about the Gcc-patches mailing list