| OLD | NEW |
| 1 # -*- python -*- | 1 # -*- python -*- |
| 2 # Copyright 2012 The Native Client Authors. All rights reserved. | 2 # Copyright 2012 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 Import('env') | 6 Import('env') |
| 7 | 7 |
| 8 # step_test_guest.nexe fails to link when Valgrind is enabled because | 8 # step_test_guest.nexe fails to link when Valgrind is enabled because |
| 9 # of a problem with the TLS ".tbss" section. | 9 # of a problem with the TLS ".tbss" section. |
| 10 if env.IsRunningUnderValgrind(): | 10 if env.IsRunningUnderValgrind(): |
| 11 Return() | 11 Return() |
| 12 | 12 |
| 13 if 'TRUSTED_ENV' not in env: | 13 if 'TRUSTED_ENV' not in env: |
| 14 Return() | 14 Return() |
| 15 trusted_env = env['TRUSTED_ENV'] | 15 trusted_env = env['TRUSTED_ENV'] |
| 16 | 16 |
| 17 if not env.AllowInlineAssembly(): | 17 if not env.AllowInlineAssembly(): |
| 18 Return() | 18 Return() |
| 19 | 19 |
| 20 if not (env.Bit('build_x86') or env.Bit('build_arm')): | 20 if not (env.Bit('build_x86') or env.Bit('build_arm')): |
| 21 Return() | 21 Return() |
| 22 # This test uses POSIX signal handling so does not build on Windows. | 22 # This test uses POSIX signal handling so does not build on Windows. |
| 23 if env.Bit('host_windows'): | 23 if env.Bit('host_windows'): |
| 24 Return() | 24 Return() |
| 25 # This test expects that a signal handler will be able to return to | 25 # This test expects that a signal handler will be able to return to |
| 26 # untrusted code, and so it does not work on Mac OS X which does not | 26 # untrusted code, and so it does not work on Mac OS X which does not |
| 27 # restore %cs to its saved value on return from a signal handler. | 27 # restore %cs to its saved value on return from a signal handler. |
| 28 if env.Bit('host_mac'): | 28 if env.Bit('host_mac'): |
| 29 Return() | 29 Return() |
| 30 # nacl-clang's integrated assembler expands "naclcall" to a sequence which |
| 31 # separates the push of the return address from the jump, and so breaks the |
| 32 # test's expectations for the stack pointer. |
| 33 # TODO(dschuff): re-enable this test after we switch to gas with nacl-clang |
| 34 if env.Bit('nacl_clang'): |
| 35 Return() |
| 30 | 36 |
| 31 if env.Bit('build_x86'): | 37 if env.Bit('build_x86'): |
| 32 step_test_guest = env.ComponentProgram( | 38 step_test_guest = env.ComponentProgram( |
| 33 'step_test_guest', ['step_test_guest.c'], | 39 'step_test_guest', ['step_test_guest.c'], |
| 34 EXTRA_LIBS=['${NONIRT_LIBS}'], | 40 EXTRA_LIBS=['${NONIRT_LIBS}'], |
| 35 EXTRA_LINKFLAGS=['-nostdlib']) | 41 EXTRA_LINKFLAGS=['-nostdlib']) |
| 36 | 42 |
| 37 step_test_host = trusted_env.ComponentProgram( | 43 step_test_host = trusted_env.ComponentProgram( |
| 38 'step_test_host', ['step_test_host.c'], EXTRA_LIBS=['sel']) | 44 'step_test_host', ['step_test_host.c'], EXTRA_LIBS=['sel']) |
| 39 | 45 |
| (...skipping 18 matching lines...) Expand all Loading... |
| 58 regs_step_test_host = trusted_env.ComponentProgram( | 64 regs_step_test_host = trusted_env.ComponentProgram( |
| 59 'regs_step_test_host', ['regs_step_test_host.c'], | 65 'regs_step_test_host', ['regs_step_test_host.c'], |
| 60 EXTRA_LIBS=['sel', 'test_common']) | 66 EXTRA_LIBS=['sel', 'test_common']) |
| 61 | 67 |
| 62 node = env.CommandTest( | 68 node = env.CommandTest( |
| 63 'signal_handler_regs_single_step.out', | 69 'signal_handler_regs_single_step.out', |
| 64 env.AddBootstrap(regs_step_test_host, [regs_step_test_guest])) | 70 env.AddBootstrap(regs_step_test_host, [regs_step_test_guest])) |
| 65 env.AddNodeToTestSuite(node, ['small_tests', 'nonpexe_tests'], | 71 env.AddNodeToTestSuite(node, ['small_tests', 'nonpexe_tests'], |
| 66 'run_signal_handler_regs_single_step_test', | 72 'run_signal_handler_regs_single_step_test', |
| 67 is_broken=not env.Bit('nacl_static_link')) | 73 is_broken=not env.Bit('nacl_static_link')) |
| OLD | NEW |