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

Side by Side Diff: src/trusted/validator_mips/testdata/test_unpredicted.S

Issue 11090024: [MIPS] New pattern in validator to detect jumps/branches in delay slots. (Closed) Base URL: http://git.chromium.org/native_client/src/native_client.git@master
Patch Set: Two more test cases added. Created 8 years, 2 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
(Empty)
1 /*
2 * Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file.
5 */
6
7 #
8 # Tests unpredicted situations in NaCl for Mips.
9 #
10
11 .set JUMP_MASK, $t6
12
13 .globl _start
14 .set noreorder
15 _start:
16
17 b _start - 0x10000 # OK - trampoline start.
18 b _start - 0x10000 # Error - branch is in the delay slot.
19 nop
20 nop
21
22 and $v0, $v0, JUMP_MASK
23 jr $v0 # OK
24 jr $v0 # Error - jump is in the delay slot.
25 nop
26
27 and $v0, $v0, JUMP_MASK
28 jr $v0 # OK
29 b _start - 0x10000 # Error - branch is in the delay slot.
30 nop
31
32 b _start - 0x10000 # OK - trampoline start.
33 jr $v0 # Error - jump is in the delay slot.
34 nop
35 nop
36
37 end_of_code:
OLDNEW
« no previous file with comments | « src/trusted/validator_mips/build.scons ('k') | src/trusted/validator_mips/testdata/test_unpredicted.err » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698