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

Side by Side Diff: pydir/run-pnacl-sz.py

Issue 2340733003: Subzero, MIPS32: Randomly insert NOP (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 4 years, 3 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
« no previous file with comments | « no previous file | src/IceTargetLoweringMIPS32.h » ('j') | 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 python2 1 #!/usr/bin/env python2
2 2
3 import argparse 3 import argparse
4 import itertools 4 import itertools
5 import os 5 import os
6 import re 6 import re
7 import subprocess 7 import subprocess
8 import sys 8 import sys
9 import tempfile 9 import tempfile
10 10
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 asm_temp = tempfile.NamedTemporaryFile(delete=False) 195 asm_temp = tempfile.NamedTemporaryFile(delete=False)
196 asm_temp.close() 196 asm_temp.close()
197 output_file_name = asm_temp.name 197 output_file_name = asm_temp.name
198 if args.assemble and args.filetype != 'obj': 198 if args.assemble and args.filetype != 'obj':
199 cmd += (['|', os.path.join(pnacl_bin_path, 'llvm-mc')] + 199 cmd += (['|', os.path.join(pnacl_bin_path, 'llvm-mc')] +
200 TargetAssemblerFlags(args.target, args.sandbox) + 200 TargetAssemblerFlags(args.target, args.sandbox) +
201 ['-filetype=obj', '-o', output_file_name]) 201 ['-filetype=obj', '-o', output_file_name])
202 elif output_file_name: 202 elif output_file_name:
203 cmd += ['-o', output_file_name] 203 cmd += ['-o', output_file_name]
204 if args.disassemble: 204 if args.disassemble:
205 # Show wide instruction encodings, diassemble, and show relocs. 205 # Show wide instruction encodings, diassemble, and show relocs.
Jim Stichnoth 2016/09/15 05:24:20 Update the comment for '-z' ?
obucinac 2016/09/15 10:44:55 Done.
206 cmd += (['&&', os.path.join(pnacl_bin_path, GetObjdumpCmd())] + 206 cmd += (['&&', os.path.join(pnacl_bin_path, GetObjdumpCmd())] +
207 args.dis_flags + 207 args.dis_flags +
208 ['-w', '-d', '-r'] + TargetDisassemblerFlags(args.target) + 208 ['-w', '-d', '-r', '-z'] + TargetDisassemblerFlags(args.target) +
209 [output_file_name]) 209 [output_file_name])
210 210
211 stdout_result = shellcmd(cmd, echo=args.echo_cmd) 211 stdout_result = shellcmd(cmd, echo=args.echo_cmd)
212 if not args.echo_cmd: 212 if not args.echo_cmd:
213 sys.stdout.write(stdout_result) 213 sys.stdout.write(stdout_result)
214 if asm_temp and not keep_output_file: 214 if asm_temp and not keep_output_file:
215 os.remove(output_file_name) 215 os.remove(output_file_name)
216 216
217 if __name__ == '__main__': 217 if __name__ == '__main__':
218 main() 218 main()
OLDNEW
« no previous file with comments | « no previous file | src/IceTargetLoweringMIPS32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698