| OLD | NEW |
| 1 @ Copyright (c) 2011 The Native Client Authors. All rights reserved. | 1 @ Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 2 @ Use of this source code is governed by a BSD-style license that can be | 2 @ Use of this source code is governed by a BSD-style license that can be |
| 3 @ found in the LICENSE file. | 3 @ found in the LICENSE file. |
| 4 | 4 |
| 5 @ | 5 @ |
| 6 @ Tests both legal and illegal variations on loads -- both loads that | 6 @ Tests both legal and illegal variations on loads -- both loads that |
| 7 @ require masking, and loads that are guaranteed sandboxed (i.e. through SP) | 7 @ require masking, and loads that are guaranteed sandboxed (i.e. through SP) |
| 8 @ | 8 @ |
| 9 | 9 |
| 10 @ we restrict loads to the lower 1GB of the address space | 10 @ we restrict loads to the lower 1GB of the address space |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 ldr r1, [r1, r2] @ loading with an index is an ERROR | 72 ldr r1, [r1, r2] @ loading with an index is an ERROR |
| 73 | 73 |
| 74 nop | 74 nop |
| 75 nop | 75 nop |
| 76 | 76 |
| 77 bundle9: | 77 bundle9: |
| 78 ldr r1, [sp], #1024 @ post-indexing sp by a constant is fine. | 78 ldr r1, [sp], #1024 @ post-indexing sp by a constant is fine. |
| 79 ldr r1, [sp], r2 @ post-indexing sp by a register is an ERROR | 79 ldr r1, [sp], r2 @ post-indexing sp by a register is an ERROR |
| 80 nop | 80 nop |
| 81 nop | 81 nop |
| 82 | |
| 83 | |
| 84 conditional_sandbox: | |
| 85 tst r0, #0xC0000000 @ Set Z if the top two bits are clear, and | |
| 86 ldreq r1, [r0] @ load: should work. | |
| 87 | |
| 88 tst r0, #0xC0000000 @ Set Z if the top two bits are clear, and | |
| 89 ldr r1, [r0] @ load unconditionally: ERROR. | |
| 90 | |
| 91 tst r0, #0xC0000000 @ Set Z if the top two bits are clear, and | |
| 92 ldrgt r1, [r0] @ load using wrong predicate: ERROR. | |
| 93 | |
| 94 tsteq r0, #0xC0000000 @ Conditionally set Z if the top two bits are clear, | |
| 95 ldrgt r1, [r0] @ and load using wrong predicate: ERROR. | |
| OLD | NEW |