libintrovirt v0.57.4
IntroVirt introspection library
Loading...
Searching...
No Matches
Cr4.hh
Go to the documentation of this file.
1/*
2 * Copyright 2021 Assured Information Security, Inc.
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#pragma once
17
18#include <cstdint>
19
20namespace introvirt {
21namespace x86 {
22
26class Cr4 {
27 public:
34 bool vme() const;
35
42 bool pvi() const;
43
50 bool tsd() const;
51
58 bool de() const;
59
66 bool pse() const;
67
74 bool pae() const;
75
82 bool mce() const;
83
90 bool pge() const;
91
98 bool pce() const;
99
106 bool osfxsr() const;
107
114 bool osxmmexcpt() const;
115
122 bool umip() const;
123
130 bool la57() const;
131
138 bool vmxe() const;
139
146 bool smxe() const;
147
154 bool fsgsbase() const;
155
162 bool pcide() const;
163
170 bool osxsave() const;
171
178 bool smep() const;
179
186 bool smap() const;
187
194 bool pke() const;
195
201 uint64_t value() const;
202
208 explicit Cr4(uint64_t cr4);
209
210 private:
211 const uint64_t cr4_;
212};
213
214} // namespace x86
215} // namespace introvirt
The x86 Control Register 4.
Definition Cr4.hh:26
bool umip() const
Get the UMIP (User-Mode Instruction Prevention) bit.
bool pse() const
Get the PSE (Page Size Extension) bit.
bool osfxsr() const
Get the OSFXSR (Operating system support for FXSAVE and FXRSTOR instructions) bit.
bool smap() const
Get the SMAP (Supervisor Mode Access Prevention Enable) bit.
bool pce() const
Get the PCE (Performance-Monitoring Counter enable) bit.
bool vme() const
Get the VME (Virtual 8086 Mode Extensions) bit.
bool osxsave() const
Get the OSXSAVE (XSAVE and Processor Extended States Enable) bit.
bool vmxe() const
Get the VMXE (Virtual Machine Extensions Enable) bit.
bool smep() const
Get the SMEP (Supervisor Mode Execution Protection Enable) bit.
Cr4(uint64_t cr4)
Construct a new Cr4 object.
bool la57() const
Get the LA57 bit.
bool de() const
Get the DE (Debugging Extensions) bit.
bool osxmmexcpt() const
Get the OSXMMEXCPT bit.
bool fsgsbase() const
Get the FSGSBASE bit.
bool pvi() const
Get the PVI (Protected-mode Virtual Interrupts) bit.
bool smxe() const
Get the SMXE (Safer Mode Extensions Enable) bit.
bool pcide() const
Get the PCIDE (PCID Enable) bit.
bool mce() const
Get the MCE (Machine Check Exception) bit.
bool pae() const
Get the PAE (Physical Address Extension) bit.
bool pge() const
Get the PGE (Page Global Enabled) bit.
bool pke() const
Get the PKE (Protection Key Enable) bit.
uint64_t value() const
Get the raw value.
bool tsd() const
Get the TSD (Time Stamp Disable) bit.
Core IntroVirt classes.
Definition Cr0.hh:20