Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(101)

Side by Side Diff: test/win/gyptest-cl-optimizations.py

Issue 23253003: ninja/win: Set /O2 compiler flag by default if no 'Optimization' specified (Closed) Base URL: http://gyp.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « pylib/gyp/msvs_emulation.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 2
3 # Copyright (c) 2012 Google Inc. All rights reserved. 3 # Copyright (c) 2012 Google Inc. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """ 7 """
8 Make sure optimization settings are extracted properly. 8 Make sure optimization settings are extracted properly.
9 """ 9 """
10 10
(...skipping 19 matching lines...) Expand all
30 30
31 ninja_file = test.built_file_path('obj/test_opt_lev_speed.ninja', chdir=CHDIR) 31 ninja_file = test.built_file_path('obj/test_opt_lev_speed.ninja', chdir=CHDIR)
32 test.must_contain(ninja_file, 'cflags = /O2') 32 test.must_contain(ninja_file, 'cflags = /O2')
33 33
34 ninja_file = test.built_file_path('obj/test_opt_lev_max.ninja', chdir=CHDIR) 34 ninja_file = test.built_file_path('obj/test_opt_lev_max.ninja', chdir=CHDIR)
35 test.must_contain(ninja_file, 'cflags = /Ox') 35 test.must_contain(ninja_file, 'cflags = /Ox')
36 36
37 ninja_file = test.built_file_path('obj/test_opt_unset.ninja', chdir=CHDIR) 37 ninja_file = test.built_file_path('obj/test_opt_unset.ninja', chdir=CHDIR)
38 test.must_not_contain(ninja_file, '/Od') 38 test.must_not_contain(ninja_file, '/Od')
39 test.must_not_contain(ninja_file, '/O1') 39 test.must_not_contain(ninja_file, '/O1')
40 test.must_not_contain(ninja_file, '/O2')
41 test.must_not_contain(ninja_file, '/Ox') 40 test.must_not_contain(ninja_file, '/Ox')
41 # Set by default if none specified.
42 test.must_contain(ninja_file, '/O2')
42 43
43 ninja_file = test.built_file_path('obj/test_opt_fpo.ninja', chdir=CHDIR) 44 ninja_file = test.built_file_path('obj/test_opt_fpo.ninja', chdir=CHDIR)
44 test.must_contain(ninja_file, '/Oy') 45 test.must_contain(ninja_file, '/Oy')
45 test.must_not_contain(ninja_file, '/Oy-') 46 test.must_not_contain(ninja_file, '/Oy-')
46 47
47 ninja_file = test.built_file_path('obj/test_opt_fpo_off.ninja', chdir=CHDIR) 48 ninja_file = test.built_file_path('obj/test_opt_fpo_off.ninja', chdir=CHDIR)
48 test.must_contain(ninja_file, '/Oy-') 49 test.must_contain(ninja_file, '/Oy-')
49 50
50 ninja_file = test.built_file_path('obj/test_opt_intrinsic.ninja', 51 ninja_file = test.built_file_path('obj/test_opt_intrinsic.ninja',
51 chdir=CHDIR) 52 chdir=CHDIR)
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 96
96 ninja_file = test.built_file_path('obj/test_opt_fso.ninja', 97 ninja_file = test.built_file_path('obj/test_opt_fso.ninja',
97 chdir=CHDIR) 98 chdir=CHDIR)
98 test.must_contain(ninja_file, '/GT') 99 test.must_contain(ninja_file, '/GT')
99 100
100 ninja_file = test.built_file_path('obj/test_opt_fso_off.ninja', 101 ninja_file = test.built_file_path('obj/test_opt_fso_off.ninja',
101 chdir=CHDIR) 102 chdir=CHDIR)
102 test.must_not_contain(ninja_file, '/GT') 103 test.must_not_contain(ninja_file, '/GT')
103 104
104 test.pass_test() 105 test.pass_test()
OLDNEW
« no previous file with comments | « pylib/gyp/msvs_emulation.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698