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

Side by Side Diff: src/trusted/validator/x86/ncval_reg_sfi/address_sets.h

Issue 625923004: Delete old x86 validator. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: rebase master Created 6 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 /*
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
4 * found in the LICENSE file.
5 */
6
7 #ifndef NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_NCVAL_REG_SFI_ADDRESS_SETS_H__
8 #define NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_NCVAL_REG_SFI_ADDRESS_SETS_H__
9
10 /*
11 * address_sets.h - Implements a bit set of addresses that is used by branch
12 * validation to check if branches are safe.
13 */
14
15 #include "native_client/src/trusted/validator/types_memory_model.h"
16
17 struct NaClValidatorState;
18
19 /* Models a set of addresses using an an array of possible addresses,
20 * where the last 3 bits are unioned together using a bit mask. This cuts
21 * down on the memory footprint of the address table.
22 */
23 typedef uint8_t* NaClAddressSet;
24
25 /* Return true if the corresponding address is in the given address set. */
26 uint8_t NaClAddressSetContains(NaClAddressSet set,
27 NaClPcAddress address,
28 struct NaClValidatorState* state);
29
30 /* Adds the given address to the given address set. */
31 void NaClAddressSetAdd(NaClAddressSet set, NaClPcAddress address,
32 struct NaClValidatorState* state);
33
34 /* Create an address set for the range 0..Size. */
35 NaClAddressSet NaClAddressSetCreate(NaClMemorySize size);
36
37 /* frees the memory of the address set back to the system. */
38 void NaClAddressSetDestroy(NaClAddressSet set);
39
40 /* Returns the array size to use for the given memory size. */
41 size_t NaClAddressSetArraySize(NaClMemorySize size);
42
43 #endif /* NATIVE_CLIENT_SRC_TRUSTED_VALIDATOR_X86_NCVAL_REG_SFI_ADDRESS_SETS_H_ _ */
OLDNEW
« no previous file with comments | « src/trusted/validator/x86/ncval_reg_sfi/README ('k') | src/trusted/validator/x86/ncval_reg_sfi/address_sets.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698