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

Side by Side Diff: tests_lit/lit.cfg

Issue 1531623007: Add option to force filetype=asm for testing (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix merge ordering issue. Created 4 years, 11 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
OLDNEW
1 # -*- Python -*- 1 # -*- Python -*-
2 # Taken from utils/lit/tests in the LLVM tree and hacked together to support 2 # Taken from utils/lit/tests in the LLVM tree and hacked together to support
3 # our tests. 3 # our tests.
4 # 4 #
5 # Note: This configuration has simple commands to run Subzero's translator. 5 # Note: This configuration has simple commands to run Subzero's translator.
6 # They have the form %X2i (i.e. %p2i, %l2i, and %lc2i) where X is defined 6 # They have the form %X2i (i.e. %p2i, %l2i, and %lc2i) where X is defined
7 # as follows: 7 # as follows:
8 # 8 #
9 # p : Run Subzero's translator, building ICE from PNaCl bitcode directly. 9 # p : Run Subzero's translator, building ICE from PNaCl bitcode directly.
10 # l : Run Subzero's translator, converting the .ll file to a PNaCl bitcode 10 # l : Run Subzero's translator, converting the .ll file to a PNaCl bitcode
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 if_atts_cmd = if_atts + ['--have=' + att for att in pnacl_sz_atts] 82 if_atts_cmd = if_atts + ['--have=' + att for att in pnacl_sz_atts]
83 ifl2i_atts_cmd = if_atts + [if_cond_flag('allow_llvm_ir' in pnacl_sz_atts), 83 ifl2i_atts_cmd = if_atts + [if_cond_flag('allow_llvm_ir' in pnacl_sz_atts),
84 '--command'] 84 '--command']
85 iflc2i_atts_cmd = if_atts + [if_cond_flag('allow_llvm_ir_as_input' 85 iflc2i_atts_cmd = if_atts + [if_cond_flag('allow_llvm_ir_as_input'
86 in pnacl_sz_atts), '--command'] 86 in pnacl_sz_atts), '--command']
87 87
88 # Base command for running pnacl-sz 88 # Base command for running pnacl-sz
89 pnacl_sz_cmd = [os.path.join(pydir, 'run-pnacl-sz.py'), 89 pnacl_sz_cmd = [os.path.join(pydir, 'run-pnacl-sz.py'),
90 '--pnacl-sz', pnacl_sz_tool, 90 '--pnacl-sz', pnacl_sz_tool,
91 '--pnacl-bin-path', pnaclbinpath] 91 '--pnacl-bin-path', pnaclbinpath]
92 if 'FORCEASM' in lit_config.params:
93 pnacl_sz_cmd += ['--forceasm']
92 94
93 # Run commands only if corresponding build attributes apply, including 95 # Run commands only if corresponding build attributes apply, including
94 # for each compiler setup. 96 # for each compiler setup.
95 config.substitutions.append(('%ifp', ' ')) 97 config.substitutions.append(('%ifp', ' '))
96 config.substitutions.append(('%iflc', ' '.join(iflc2i_atts_cmd))) 98 config.substitutions.append(('%iflc', ' '.join(iflc2i_atts_cmd)))
97 config.substitutions.append(('%ifl', ' '.join(ifl2i_atts_cmd))) 99 config.substitutions.append(('%ifl', ' '.join(ifl2i_atts_cmd)))
98 config.substitutions.append(('%if', ' '.join(if_atts_cmd))) 100 config.substitutions.append(('%if', ' '.join(if_atts_cmd)))
99 101
100 # Translate LLVM source for each compiler setup. 102 # Translate LLVM source for each compiler setup.
101 config.substitutions.append(('%p2i', ' '.join(pnacl_sz_cmd))) 103 config.substitutions.append(('%p2i', ' '.join(pnacl_sz_cmd)))
(...skipping 30 matching lines...) Expand all
132 config.available_features.add("python%d.%d" % (sys.version_info[0], 134 config.available_features.add("python%d.%d" % (sys.version_info[0],
133 sys.version_info[1])) 135 sys.version_info[1]))
134 136
135 # Debugging output 137 # Debugging output
136 def dbg(s): 138 def dbg(s):
137 print '[DBG] %s' % s 139 print '[DBG] %s' % s
138 140
139 dbg('bin_root = %s' % bin_root) 141 dbg('bin_root = %s' % bin_root)
140 dbg('pnaclbinpath = %s' % pnaclbinpath) 142 dbg('pnaclbinpath = %s' % pnaclbinpath)
141 dbg("Build attributes = %s" % pnacl_sz_atts) 143 dbg("Build attributes = %s" % pnacl_sz_atts)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698