| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 # | 5 # |
| 6 # IMPORTANT NOTE: If you make local mods to this file, you must run: | 6 # IMPORTANT NOTE: If you make local mods to this file, you must run: |
| 7 # % tools/llvm/utman.sh driver | 7 # % tools/llvm/utman.sh driver |
| 8 # in order for them to take effect in the scons build. This command | 8 # in order for them to take effect in the scons build. This command |
| 9 # updates the copy in the toolchain/ tree. | 9 # updates the copy in the toolchain/ tree. |
| 10 # | 10 # |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 # glibc, then you must do pnacl-translate -static. This will | 23 # glibc, then you must do pnacl-translate -static. This will |
| 24 # be removed once we can detect .pexe type. | 24 # be removed once we can detect .pexe type. |
| 25 'STATIC' : '0', | 25 'STATIC' : '0', |
| 26 | 26 |
| 27 'INPUTS' : '', | 27 'INPUTS' : '', |
| 28 'OUTPUT' : '', | 28 'OUTPUT' : '', |
| 29 'OUTPUT_TYPE' : '', | 29 'OUTPUT_TYPE' : '', |
| 30 'LLC' : '${SANDBOXED ? ${LLC_SB} : ${LLVM_LLC}}', | 30 'LLC' : '${SANDBOXED ? ${LLC_SB} : ${LLVM_LLC}}', |
| 31 | 31 |
| 32 'TRIPLE' : '${TRIPLE_%ARCH%}', | 32 'TRIPLE' : '${TRIPLE_%ARCH%}', |
| 33 'TRIPLE_ARM' : 'armv7a-none-linux-gnueabi', | 33 'TRIPLE_ARM' : 'armv7a-none-nacl-gnueabi', |
| 34 'TRIPLE_X8632': 'i686-none-linux-gnu', | 34 'TRIPLE_X8632': 'i686-none-nacl-gnu', |
| 35 'TRIPLE_X8664': 'x86_64-none-linux-gnu', | 35 'TRIPLE_X8664': 'x86_64-none-nacl-gnu', |
| 36 | 36 |
| 37 'LLC_FLAGS_COMMON': '-asm-verbose=false ' + | 37 'LLC_FLAGS_COMMON': '-asm-verbose=false ' + |
| 38 '${PIC ? -relocation-model=pic} ' + | 38 '${PIC ? -relocation-model=pic} ' + |
| 39 '${PIC && ARCH==X8664 && LIBMODE_NEWLIB ? ' + | 39 '${PIC && ARCH==X8664 && LIBMODE_NEWLIB ? ' + |
| 40 ' -force-tls-non-pic }', | 40 ' -force-tls-non-pic }', |
| 41 'LLC_FLAGS_ARM' : | 41 'LLC_FLAGS_ARM' : |
| 42 # The following options might come in hand and are left here as comments: | 42 # The following options might come in hand and are left here as comments: |
| 43 # TODO(robertm): describe their purpose | 43 # TODO(robertm): describe their purpose |
| 44 # '-soft-float -aeabi-calls -sfi-zero-mask', | 44 # '-soft-float -aeabi-calls -sfi-zero-mask', |
| 45 # NOTE: we need a fairly high fudge factor because of | 45 # NOTE: we need a fairly high fudge factor because of |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 221 script.append('rpc Translate h(myfile) * h() i()') | 221 script.append('rpc Translate h(myfile) * h() i()') |
| 222 script.append('set_variable out_handle ${result0}') | 222 script.append('set_variable out_handle ${result0}') |
| 223 script.append('set_variable out_size ${result1}') | 223 script.append('set_variable out_size ${result1}') |
| 224 script.append('map_shmem ${out_handle} addr') | 224 script.append('map_shmem ${out_handle} addr') |
| 225 script.append('save_to_file %s ${addr} 0 ${out_size}' % outfile) | 225 script.append('save_to_file %s ${addr} 0 ${out_size}' % outfile) |
| 226 script.append('') | 226 script.append('') |
| 227 return '\n'.join(script) | 227 return '\n'.join(script) |
| 228 | 228 |
| 229 if __name__ == "__main__": | 229 if __name__ == "__main__": |
| 230 DriverMain(main) | 230 DriverMain(main) |
| OLD | NEW |