This is the mail archive of the gcc-cvs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

r125575 - in /trunk/gcc: ChangeLog common.opt d...


Author: hjagasia
Date: Fri Jun  8 16:30:49 2007
New Revision: 125575

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=125575
Log:
gcc/ChangeLog:
2007-06-08  Harsha Jagasia <harsha.jagasia@amd.com>
            Tony Linthicum <tony.linthicum@amd.com>

	* doc/extend.texi: Add fvect-cost-model flag.
	* common.opt (fvect-cost-model): New flag.
	* tree-vectorizer.c (new_stmt_vec_info): Initialize inside and outside
	cost fields in stmt_vec_info struct for STMT.
	* tree-vectorizer.h (stmt_vec_info): Define inside and outside cost
	fields in stmt_vec_info struct and access functions for the same.
	(TARG_COND_BRANCH_COST): Define cost of conditional branch.
	(TARG_VEC_STMT_COST): Define cost of any vector operation, excluding
	load, store and vector to scalar operation.
	(TARG_VEC_TO_SCALAR_COST): Define cost of vector to scalar operation.
	(TARG_VEC_LOAD_COST): Define cost of aligned vector load.
	(TARG_VEC_UNALIGNED_LOAD_COST): Define cost of misasligned vector load.
	(TARG_VEC_STORE_COST): Define cost of vector store.
	(vect_estimate_min_profitable_iters): Define new function.
	* tree-vect-analyze.c (vect_analyze_operations): Add a compile-time
	check to evaluate if loop iterations are less than minimum profitable
	iterations determined by cost model or minimum vect loop bound defined
	by user, whichever is more conservative.
	* tree-vect-transform.c (vect_do_peeling_for_loop_bound): Add a
	run-time check to evaluate if loop iterations are less than minimum
	profitable iterations determined by cost model or minimum vect loop
	bound defined by user, whichever is more conservative.
	(vect_estimate_min_profitable_iterations): New function to estimate
	mimimimum iterartions required for vector version of loop to be
	profitable over scalar version.
        (vect_model_reduction_cost): New function.
	(vect_model_induction_cost): New function.
	(vect_model_simple_cost): New function.
	(vect_cost_strided_group_size): New function.
	(vect_model_store_cost): New function.
	(vect_model_load_cost): New function.
	(vectorizable_reduction): Call vect_model_reduction_cost during
	analysis phase.
	(vectorizable_induction): Call vect_model_induction_cost during
	analysis phase.
	(vectorizable_load): Call vect_model_load_cost during analysis phase.
	(vectorizable_store): Call vect_model_store_cost during analysis phase.
	(vectorizable_call, vectorizable_assignment, vectorizable_operation,
	vectorizable_promotion, vectorizable_demotion): Call 
	vect_model_simple_cost during analysis phase.

gcc/testsuite/ChangeLog:
2007-06-08  Harsha Jagasia <harsha.jagasia@amd.com>

	* gcc.dg/vect/costmodel: New directory.
	* gcc.dg/vect/costmodel/i386: New directory.
	* gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp: New testsuite.
	* gcc.dg/vect/costmodel/i386/costmodel-fast-math-vect-pr29925.c:
	New test.
	* gcc.dg/vect/costmodel/i386/costmodel-vect-31.c: New test.
	* gcc.dg/vect/costmodel/i386/costmodel-vect-33.c: New test.
	* gcc.dg/vect/costmodel/i386/costmodel-vect-68.c: New test.
	* gcc.dg/vect/costmodel/i386/costmodel-vect-reduc-1char.c: New test.
	* gcc.dg/vect/costmodel/x86_64: New directory.
	* gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp:
	New testsuite.	
	* gcc.dg/vect/costmodel/x86_64/costmodel-fast-math-vect-pr29925.c:
	New test.
	* gcc.dg/vect/costmodel/x86_64/costmodel-vect-31.c: New test.
	* gcc.dg/vect/costmodel/x86_64/costmodel-vect-33.c: New test.
	* gcc.dg/vect/costmodel/x86_64/costmodel-vect-68.c: New test.
	* gcc.dg/vect/costmodel/x86_64/costmodel-vect-reduc-1char.c: New test.
	* gcc.dg/vect/costmodel/x86_64/costmodel-pr30843.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/costmodel-fast-math-vect-pr29925.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/costmodel-vect-31.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/costmodel-vect-33.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/costmodel-vect-68.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/costmodel-vect-reduc-1char.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-fast-math-vect-pr29925.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-pr30843.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-vect-31.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-vect-33.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-vect-68.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/costmodel-vect-reduc-1char.c
    trunk/gcc/testsuite/gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/common.opt
    trunk/gcc/doc/invoke.texi
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-vect-analyze.c
    trunk/gcc/tree-vect-transform.c
    trunk/gcc/tree-vectorizer.c
    trunk/gcc/tree-vectorizer.h


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]