OLD | NEW |
| (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 * input_tester.h | |
9 * Implements a decoder that matches the instructions read from stdin. | |
10 */ | |
11 | |
12 #ifndef NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_TESTING_ENUMINSTS_INPUT_TESTER_H
_ | |
13 #define NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_TESTING_ENUMINSTS_INPUT_TESTER_H
_ | |
14 | |
15 #include "native_client/src/trusted/validator/x86/testing/enuminsts/enuminsts.h" | |
16 | |
17 /* Defines a reader that reads instruction byte sequences from stdin | |
18 * (one per line). '#' denotes the beginning of a comment, and spaces | |
19 * are allowed between (hexidecimal) bytes. If an input line is just whitespace, | |
20 * it is skipped and the next line is read. Communicates with the input decoder | |
21 * (see below) so that they process the same sequence of instructions. | |
22 * Argument: | |
23 * ibytes - An array to put the sequence of read bytes into. | |
24 * Returns: | |
25 * The number of bytes put into ibytes. If zero, there is no more input. | |
26 */ | |
27 extern int ReadAnInstruction(InstByteArray ibytes); | |
28 | |
29 /* Defines an input decoder for instructions read from stdin. */ | |
30 extern NaClEnumeratorDecoder* RegisterInputDecoder(void); | |
31 | |
32 #endif // NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_TESTING_ENUMINSTS_INPUT_TESTE
R_H_ | |
OLD | NEW |