VirtualBox

source: vbox/trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-instr-2.h@ 105684

Last change on this file since 105684 was 104000, checked in by vboxsync, 8 months ago

ValKit/bs3-cpu-instr-2: Added shl,shr,sar,rol,ror,rcl&rcr tests (only intel data). bugref:10376

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.5 KB
Line 
1/* $Id: bs3-cpu-instr-2.h 104000 2024-03-22 15:37:38Z vboxsync $ */
2/** @file
3 * BS3Kit - bs3-cpu-instr-2, common header file.
4 */
5
6/*
7 * Copyright (C) 2024 Oracle and/or its affiliates.
8 *
9 * This file is part of VirtualBox base platform packages, as
10 * available from https://www.virtualbox.org.
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation, in version 3 of the
15 * License.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, see <https://www.gnu.org/licenses>.
24 *
25 * The contents of this file may alternatively be used under the terms
26 * of the Common Development and Distribution License Version 1.0
27 * (CDDL), a copy of it is provided in the "COPYING.CDDL" file included
28 * in the VirtualBox distribution, in which case the provisions of the
29 * CDDL are applicable instead of those of the GPL.
30 *
31 * You may elect to license modified versions of this file under the
32 * terms and conditions of either the GPL or the CDDL or both.
33 *
34 * SPDX-License-Identifier: GPL-3.0-only OR CDDL-1.0
35 */
36
37#ifndef VBOX_INCLUDED_SRC_bootsectors_bs3_cpu_instr_2_h
38#define VBOX_INCLUDED_SRC_bootsectors_bs3_cpu_instr_2_h
39#ifndef RT_WITHOUT_PRAGMA_ONCE
40# pragma once
41#endif
42
43#pragma pack(1)
44
45/* binary: */
46
47typedef struct BS3CPUINSTR2BIN8
48{
49 uint8_t uSrc1, uSrc2, uResult;
50 uint16_t fEflOut;
51} BS3CPUINSTR2BIN8;
52typedef BS3CPUINSTR2BIN8 const RT_FAR *PCBS3CPUINSTR2BIN8;
53
54typedef struct BS3CPUINSTR2BIN16
55{
56 uint16_t uSrc1, uSrc2, uResult;
57 uint16_t fEflOut;
58} BS3CPUINSTR2BIN16;
59typedef BS3CPUINSTR2BIN16 const RT_FAR *PCBS3CPUINSTR2BIN16;
60
61typedef struct BS3CPUINSTR2BIN32
62{
63 uint32_t uSrc1, uSrc2, uResult;
64 uint16_t fEflOut;
65} BS3CPUINSTR2BIN32;
66typedef BS3CPUINSTR2BIN32 const RT_FAR *PCBS3CPUINSTR2BIN32;
67
68typedef struct BS3CPUINSTR2BIN64
69{
70 uint64_t uSrc1, uSrc2, uResult;
71 uint16_t fEflOut;
72} BS3CPUINSTR2BIN64;
73typedef BS3CPUINSTR2BIN64 const RT_FAR *PCBS3CPUINSTR2BIN64;
74
75/** Using unused EFLAGS bit 3 for CF input value for ADC, SBB and such. */
76#define BS3CPUINSTR2BIN_EFL_CARRY_IN_BIT 3
77
78
79/* shifting: */
80
81typedef struct BS3CPUINSTR2SHIFT8
82{
83 uint8_t uSrc1;
84 uint8_t uSrc2;
85 uint16_t fEflIn;
86 uint8_t uResult;
87 uint16_t fEflOut;
88} BS3CPUINSTR2SHIFT8;
89typedef BS3CPUINSTR2SHIFT8 const RT_FAR *PCBS3CPUINSTR2SHIFT8;
90
91typedef struct BS3CPUINSTR2SHIFT16
92{
93 uint16_t uSrc1;
94 uint8_t uSrc2;
95 uint16_t fEflIn;
96 uint16_t uResult;
97 uint16_t fEflOut;
98} BS3CPUINSTR2SHIFT16;
99typedef BS3CPUINSTR2SHIFT16 const RT_FAR *PCBS3CPUINSTR2SHIFT16;
100
101typedef struct BS3CPUINSTR2SHIFT32
102{
103 uint32_t uSrc1;
104 uint8_t uSrc2;
105 uint16_t fEflIn;
106 uint32_t uResult;
107 uint16_t fEflOut;
108} BS3CPUINSTR2SHIFT32;
109typedef BS3CPUINSTR2SHIFT32 const RT_FAR *PCBS3CPUINSTR2SHIFT32;
110
111typedef struct BS3CPUINSTR2SHIFT64
112{
113 uint64_t uSrc1;
114 uint8_t uSrc2;
115 uint16_t fEflIn;
116 uint64_t uResult;
117 uint16_t fEflOut;
118} BS3CPUINSTR2SHIFT64;
119typedef BS3CPUINSTR2SHIFT64 const RT_FAR *PCBS3CPUINSTR2SHIFT64;
120
121#pragma pack()
122
123/** Using unused EFLAGS bit 3 for alternative OF value for reg,Ib. */
124#define BS3CPUINSTR2SHIFT_EFL_IB_OVERFLOW_OUT_BIT 3
125
126#endif /* !VBOX_INCLUDED_SRC_bootsectors_bs3_cpu_instr_2_h */
127
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette