-
- Downloads
common.opt: Add -foptimize-strlen option.
* common.opt: Add -foptimize-strlen option. * Makefile.in (OBJS): Add tree-ssa-strlen.o. (tree-sssa-strlen.o): Add dependencies. * opts.c (default_options_table): Enable -foptimize-strlen by default at -O2 if not -Os. * passes.c (init_optimization_passes): Add pass_strlen after pass_object_sizes. * timevar.def (TV_TREE_STRLEN): New timevar. * params.def (PARAM_MAX_TRACKED_STRLENS): New parameter. * tree-pass.h (pass_strlen): Declare. * tree-ssa-strlen.c: New file. * c-decl.c (merge_decls): If compatible stpcpy prototype is seen, set implicit_built_in_decls[BUILT_IN_STPCPY]. cp/ * decl.c (duplicate_decls): If compatible stpcpy prototype is seen, set implicit_built_in_decls[BUILT_IN_STPCPY]. testsuite/ * gcc.dg/strlenopt-1.c: New test. * gcc.dg/strlenopt-1f.c: New test. * gcc.dg/strlenopt-2.c: New test. * gcc.dg/strlenopt-2f.c: New test. * gcc.dg/strlenopt-3.c: New test. * gcc.dg/strlenopt-4.c: New test. * gcc.dg/strlenopt-4g.c: New test. * gcc.dg/strlenopt-4gf.c: New test. * gcc.dg/strlenopt-5.c: New test. * gcc.dg/strlenopt-6.c: New test. * gcc.dg/strlenopt-7.c: New test. * gcc.dg/strlenopt-8.c: New test. * gcc.dg/strlenopt-9.c: New test. * gcc.dg/strlenopt-10.c: New test. * gcc.dg/strlenopt-11.c: New test. * gcc.dg/strlenopt-12.c: New test. * gcc.dg/strlenopt-12g.c: New test. * gcc.dg/strlenopt-13.c: New test. * gcc.dg/strlenopt-14g.c: New test. * gcc.dg/strlenopt-14gf.c: New test. * gcc.dg/strlenopt-15.c: New test. * gcc.dg/strlenopt-16g.c: New test. * gcc.dg/strlenopt-17g.c: New test. * gcc.dg/strlenopt-18g.c: New test. * gcc.dg/strlenopt.h: New file. From-SVN: r179277
Showing
- gcc/ChangeLog 16 additions, 0 deletionsgcc/ChangeLog
- gcc/Makefile.in 4 additions, 0 deletionsgcc/Makefile.in
- gcc/c-decl.c 15 additions, 1 deletiongcc/c-decl.c
- gcc/common.opt 4 additions, 0 deletionsgcc/common.opt
- gcc/cp/ChangeLog 5 additions, 0 deletionsgcc/cp/ChangeLog
- gcc/cp/decl.c 12 additions, 0 deletionsgcc/cp/decl.c
- gcc/passes.c 3 additions, 2 deletionsgcc/passes.c
- gcc/testsuite/ChangeLog 28 additions, 0 deletionsgcc/testsuite/ChangeLog
- gcc/testsuite/gcc.dg/strlenopt-1.c 47 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-1.c
- gcc/testsuite/gcc.dg/strlenopt-10.c 80 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-10.c
- gcc/testsuite/gcc.dg/strlenopt-11.c 70 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-11.c
- gcc/testsuite/gcc.dg/strlenopt-12.c 90 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-12.c
- gcc/testsuite/gcc.dg/strlenopt-12g.c 6 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-12g.c
- gcc/testsuite/gcc.dg/strlenopt-13.c 68 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-13.c
- gcc/testsuite/gcc.dg/strlenopt-14g.c 115 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-14g.c
- gcc/testsuite/gcc.dg/strlenopt-14gf.c 24 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-14gf.c
- gcc/testsuite/gcc.dg/strlenopt-15.c 60 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-15.c
- gcc/testsuite/gcc.dg/strlenopt-16g.c 34 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-16g.c
- gcc/testsuite/gcc.dg/strlenopt-17g.c 57 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-17g.c
- gcc/testsuite/gcc.dg/strlenopt-18g.c 82 additions, 0 deletionsgcc/testsuite/gcc.dg/strlenopt-18g.c
Loading
Please register or sign in to comment