LIEF: Library to Instrument Executable Formats Version 0.15.0
Loading...
Searching...
No Matches
OAT/enums.hpp
1/* Copyright 2017 - 2024 R. Thomas
2 * Copyright 2017 - 2024 Quarkslab
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16#ifndef LIEF_OAT_ENUMS_H
17#define LIEF_OAT_ENUMS_H
18
19namespace LIEF {
20namespace OAT {
21
22enum OAT_CLASS_TYPES {
23 OAT_CLASS_ALL_COMPILED = 0,
24 OAT_CLASS_SOME_COMPILED = 1,
25 OAT_CLASS_NONE_COMPILED = 2,
26};
27
28// From art/runtime/mirror/class.h
29enum OAT_CLASS_STATUS {
30 STATUS_RETIRED = -2, // Retired, should not be used. Use the newly cloned one instead.
31 STATUS_ERROR = -1,
32 STATUS_NOTREADY = 0,
33 STATUS_IDX = 1, // Loaded, DEX idx in super_class_type_idx_ and interfaces_type_idx_.
34 STATUS_LOADED = 2, // DEX idx values resolved.
35 STATUS_RESOLVING = 3, // Just cloned from temporary class object.
36 STATUS_RESOLVED = 4, // Part of linking.
37 STATUS_VERIFYING = 5, // In the process of being verified.
38 STATUS_RETRY_VERIFICATION_AT_RUNTIME = 6, // Compile time verification failed, retry at runtime.
39 STATUS_VERIFYING_AT_RUNTIME = 7, // Retrying verification at runtime.
40 STATUS_VERIFIED = 8, // Logically part of linking; done pre-init.
41 STATUS_INITIALIZING = 9, // Class init in progress.
42 STATUS_INITIALIZED = 10, // Ready to go.
43};
44
45enum HEADER_KEYS {
46 KEY_IMAGE_LOCATION = 0,
47 KEY_DEX2OAT_CMD_LINE = 1,
48 KEY_DEX2OAT_HOST = 2,
49 KEY_PIC = 3,
50 KEY_HAS_PATCH_INFO = 4,
51 KEY_DEBUGGABLE = 5,
52 KEY_NATIVE_DEBUGGABLE = 6,
53 KEY_COMPILER_FILTER = 7,
54 KEY_CLASS_PATH = 8,
55 KEY_BOOT_CLASS_PATH = 9,
56 KEY_CONCURRENT_COPYING = 10,
57 KE_COMPILATION_REASON = 11,
58};
59
60enum INSTRUCTION_SETS {
61 INST_SET_NONE = 0,
62 INST_SET_ARM = 1,
63 INST_SET_ARM_64 = 2,
64 INST_SET_THUMB2 = 3,
65 INST_SET_X86 = 4,
66 INST_SET_X86_64 = 5,
67 INST_SET_MIPS = 6,
68 INST_SET_MIPS_64 = 7,
69};
70
71
72
73static const HEADER_KEYS header_keys_list[] = {
74 HEADER_KEYS::KEY_IMAGE_LOCATION ,
75 HEADER_KEYS::KEY_DEX2OAT_CMD_LINE ,
76 HEADER_KEYS::KEY_DEX2OAT_HOST ,
77 HEADER_KEYS::KEY_PIC ,
78 HEADER_KEYS::KEY_HAS_PATCH_INFO ,
79 HEADER_KEYS::KEY_DEBUGGABLE ,
80 HEADER_KEYS::KEY_NATIVE_DEBUGGABLE ,
81 HEADER_KEYS::KEY_COMPILER_FILTER ,
82 HEADER_KEYS::KEY_CLASS_PATH ,
83 HEADER_KEYS::KEY_BOOT_CLASS_PATH ,
84 HEADER_KEYS::KEY_CONCURRENT_COPYING ,
85 HEADER_KEYS::KE_COMPILATION_REASON ,
86};
87
88}
89}
90#endif
LIEF namespace.
Definition Abstract/Binary.hpp:32