/*
 * Copyright (C) 2017-2021 Intel Corporation.
 * SPDX-License-Identifier: MIT
 */

// <COMPONENT>: debugger-protocol
// <FILE-TYPE>: component public header

#ifndef DEBUGGER_PROTOCOL_REGS_WINDOWS_AVX512_64_HPP
#define DEBUGGER_PROTOCOL_REGS_WINDOWS_AVX512_64_HPP

#include "debugger-protocol.hpp"

namespace DEBUGGER_PROTOCOL
{
#if defined(DEBUGGER_PROTOCOL_BUILD) // Library clients should NOT define this.

/*!
 * This is the register set the Windows debuggers use for 64-bit AVX512.
 */
DEBUGGER_PROTOCOL_API REG_DESCRIPTION RegsWindowsAvx512_64[] = {
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RAX
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RBX
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RCX
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RDX
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RSI
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_RDI
    {64, REG_INVALID, true},   // REG_WINDOWS_AVX512_64_RBP
    {64, REG_INVALID, true},   // REG_WINDOWS_AVX512_64_RSP
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R8
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R9
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R10
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R11
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R12
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R13
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R14
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_R15
    {64, REG_PC, true},        // REG_WINDOWS_AVX512_64_PC
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_EFLAGS
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_CS
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_SS
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_DS
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ES
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FS
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_GS
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST0
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST1
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST2
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST3
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST4
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST5
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST6
    {80, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_ST7
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FCTRL
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FSTAT
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FTAG_FULL
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FISEG
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FIOFF
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FOSEG
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FOOFF
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_FOP
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM0
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM1
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM2
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM3
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM4
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM5
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM6
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM7
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM8
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM9
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM10
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM11
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM12
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM13
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM14
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM15
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_MXCSR
    {32, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_MXCSRMASK
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM0H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM1H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM2H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM3H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM4H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM5H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM6H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM7H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM8H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM9H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM10H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM11H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM12H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM13H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM14H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM15H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM16
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM17
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM18
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM19
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM20
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM21
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM22
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM23
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM24
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM25
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM26
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM27
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM28
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM29
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM30
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_XMM31
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM16H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM17H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM18H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM19H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM20H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM21H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM22H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM23H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM24H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM25H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM26H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM27H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM28H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM29H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM30H
    {128, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_YMM31H
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K0
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K1
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K2
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K3
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K4
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K5
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K6
    {64, REG_INVALID, false},  // REG_WINDOWS_AVX512_64_K7
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM0H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM1H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM2H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM3H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM4H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM5H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM6H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM7H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM8H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM9H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM10H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM11H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM12H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM13H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM14H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM15H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM16H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM17H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM18H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM19H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM20H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM21H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM22H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM23H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM24H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM25H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM26H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM27H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM28H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM29H
    {256, REG_INVALID, false}, // REG_WINDOWS_AVX512_64_ZMM30H
    {256, REG_INVALID, false}  // REG_WINDOWS_AVX512_64_ZMM31H
};

/*!
 * Number of entries in RegsWindowsAvx512_64.
 */
DEBUGGER_PROTOCOL_API unsigned RegsWindowsAvx512_64Count = sizeof(RegsWindowsAvx512_64) / sizeof(RegsWindowsAvx512_64[0]);

#else

DEBUGGER_PROTOCOL_API extern REG_DESCRIPTION RegsWindowsAvx512_64[]; ///< 64-bit AVX512 register set on Windows.
DEBUGGER_PROTOCOL_API extern unsigned RegsWindowsAvx512_64Count;     ///< Number of entries in RegsWindowsAvx512_64.

#endif /*DEBUGGER_PROTOCOL_BUILD*/

/*!
 * Convenient identifiers for the registers in this set.
 */
enum REG_WINDOWS_AVX512_64
{
    REG_WINDOWS_AVX512_64_FIRST = REG_END,
    REG_WINDOWS_AVX512_64_RAX   = REG_WINDOWS_AVX512_64_FIRST,
    REG_WINDOWS_AVX512_64_RBX,
    REG_WINDOWS_AVX512_64_RCX,
    REG_WINDOWS_AVX512_64_RDX,
    REG_WINDOWS_AVX512_64_RSI,
    REG_WINDOWS_AVX512_64_RDI,
    REG_WINDOWS_AVX512_64_RBP,
    REG_WINDOWS_AVX512_64_RSP,
    REG_WINDOWS_AVX512_64_R8,
    REG_WINDOWS_AVX512_64_R9,
    REG_WINDOWS_AVX512_64_R10,
    REG_WINDOWS_AVX512_64_R11,
    REG_WINDOWS_AVX512_64_R12,
    REG_WINDOWS_AVX512_64_R13,
    REG_WINDOWS_AVX512_64_R14,
    REG_WINDOWS_AVX512_64_R15,
    REG_WINDOWS_AVX512_64_PC,
    REG_WINDOWS_AVX512_64_EFLAGS,
    REG_WINDOWS_AVX512_64_CS,
    REG_WINDOWS_AVX512_64_SS,
    REG_WINDOWS_AVX512_64_DS,
    REG_WINDOWS_AVX512_64_ES,
    REG_WINDOWS_AVX512_64_FS,
    REG_WINDOWS_AVX512_64_GS,
    REG_WINDOWS_AVX512_64_ST0,
    REG_WINDOWS_AVX512_64_ST1,
    REG_WINDOWS_AVX512_64_ST2,
    REG_WINDOWS_AVX512_64_ST3,
    REG_WINDOWS_AVX512_64_ST4,
    REG_WINDOWS_AVX512_64_ST5,
    REG_WINDOWS_AVX512_64_ST6,
    REG_WINDOWS_AVX512_64_ST7,
    REG_WINDOWS_AVX512_64_FCTRL,
    REG_WINDOWS_AVX512_64_FSTAT,
    REG_WINDOWS_AVX512_64_FTAG_FULL, // 16-bit "full" encoding
    REG_WINDOWS_AVX512_64_FISEG,
    REG_WINDOWS_AVX512_64_FIOFF,
    REG_WINDOWS_AVX512_64_FOSEG,
    REG_WINDOWS_AVX512_64_FOOFF,
    REG_WINDOWS_AVX512_64_FOP,
    REG_WINDOWS_AVX512_64_XMM0,
    REG_WINDOWS_AVX512_64_XMM1,
    REG_WINDOWS_AVX512_64_XMM2,
    REG_WINDOWS_AVX512_64_XMM3,
    REG_WINDOWS_AVX512_64_XMM4,
    REG_WINDOWS_AVX512_64_XMM5,
    REG_WINDOWS_AVX512_64_XMM6,
    REG_WINDOWS_AVX512_64_XMM7,
    REG_WINDOWS_AVX512_64_XMM8,
    REG_WINDOWS_AVX512_64_XMM9,
    REG_WINDOWS_AVX512_64_XMM10,
    REG_WINDOWS_AVX512_64_XMM11,
    REG_WINDOWS_AVX512_64_XMM12,
    REG_WINDOWS_AVX512_64_XMM13,
    REG_WINDOWS_AVX512_64_XMM14,
    REG_WINDOWS_AVX512_64_XMM15,
    REG_WINDOWS_AVX512_64_MXCSR,
    REG_WINDOWS_AVX512_64_MXCSRMASK,
    REG_WINDOWS_AVX512_64_YMM0H,
    REG_WINDOWS_AVX512_64_YMM1H,
    REG_WINDOWS_AVX512_64_YMM2H,
    REG_WINDOWS_AVX512_64_YMM3H,
    REG_WINDOWS_AVX512_64_YMM4H,
    REG_WINDOWS_AVX512_64_YMM5H,
    REG_WINDOWS_AVX512_64_YMM6H,
    REG_WINDOWS_AVX512_64_YMM7H,
    REG_WINDOWS_AVX512_64_YMM8H,
    REG_WINDOWS_AVX512_64_YMM9H,
    REG_WINDOWS_AVX512_64_YMM10H,
    REG_WINDOWS_AVX512_64_YMM11H,
    REG_WINDOWS_AVX512_64_YMM12H,
    REG_WINDOWS_AVX512_64_YMM13H,
    REG_WINDOWS_AVX512_64_YMM14H,
    REG_WINDOWS_AVX512_64_YMM15H,
    REG_WINDOWS_AVX512_64_XMM16,
    REG_WINDOWS_AVX512_64_XMM17,
    REG_WINDOWS_AVX512_64_XMM18,
    REG_WINDOWS_AVX512_64_XMM19,
    REG_WINDOWS_AVX512_64_XMM20,
    REG_WINDOWS_AVX512_64_XMM21,
    REG_WINDOWS_AVX512_64_XMM22,
    REG_WINDOWS_AVX512_64_XMM23,
    REG_WINDOWS_AVX512_64_XMM24,
    REG_WINDOWS_AVX512_64_XMM25,
    REG_WINDOWS_AVX512_64_XMM26,
    REG_WINDOWS_AVX512_64_XMM27,
    REG_WINDOWS_AVX512_64_XMM28,
    REG_WINDOWS_AVX512_64_XMM29,
    REG_WINDOWS_AVX512_64_XMM30,
    REG_WINDOWS_AVX512_64_XMM31,
    REG_WINDOWS_AVX512_64_YMM16H,
    REG_WINDOWS_AVX512_64_YMM17H,
    REG_WINDOWS_AVX512_64_YMM18H,
    REG_WINDOWS_AVX512_64_YMM19H,
    REG_WINDOWS_AVX512_64_YMM20H,
    REG_WINDOWS_AVX512_64_YMM21H,
    REG_WINDOWS_AVX512_64_YMM22H,
    REG_WINDOWS_AVX512_64_YMM23H,
    REG_WINDOWS_AVX512_64_YMM24H,
    REG_WINDOWS_AVX512_64_YMM25H,
    REG_WINDOWS_AVX512_64_YMM26H,
    REG_WINDOWS_AVX512_64_YMM27H,
    REG_WINDOWS_AVX512_64_YMM28H,
    REG_WINDOWS_AVX512_64_YMM29H,
    REG_WINDOWS_AVX512_64_YMM30H,
    REG_WINDOWS_AVX512_64_YMM31H,
    REG_WINDOWS_AVX512_64_K0,
    REG_WINDOWS_AVX512_64_K1,
    REG_WINDOWS_AVX512_64_K2,
    REG_WINDOWS_AVX512_64_K3,
    REG_WINDOWS_AVX512_64_K4,
    REG_WINDOWS_AVX512_64_K5,
    REG_WINDOWS_AVX512_64_K6,
    REG_WINDOWS_AVX512_64_K7,
    REG_WINDOWS_AVX512_64_ZMM0H,
    REG_WINDOWS_AVX512_64_ZMM1H,
    REG_WINDOWS_AVX512_64_ZMM2H,
    REG_WINDOWS_AVX512_64_ZMM3H,
    REG_WINDOWS_AVX512_64_ZMM4H,
    REG_WINDOWS_AVX512_64_ZMM5H,
    REG_WINDOWS_AVX512_64_ZMM6H,
    REG_WINDOWS_AVX512_64_ZMM7H,
    REG_WINDOWS_AVX512_64_ZMM8H,
    REG_WINDOWS_AVX512_64_ZMM9H,
    REG_WINDOWS_AVX512_64_ZMM10H,
    REG_WINDOWS_AVX512_64_ZMM11H,
    REG_WINDOWS_AVX512_64_ZMM12H,
    REG_WINDOWS_AVX512_64_ZMM13H,
    REG_WINDOWS_AVX512_64_ZMM14H,
    REG_WINDOWS_AVX512_64_ZMM15H,
    REG_WINDOWS_AVX512_64_ZMM16H,
    REG_WINDOWS_AVX512_64_ZMM17H,
    REG_WINDOWS_AVX512_64_ZMM18H,
    REG_WINDOWS_AVX512_64_ZMM19H,
    REG_WINDOWS_AVX512_64_ZMM20H,
    REG_WINDOWS_AVX512_64_ZMM21H,
    REG_WINDOWS_AVX512_64_ZMM22H,
    REG_WINDOWS_AVX512_64_ZMM23H,
    REG_WINDOWS_AVX512_64_ZMM24H,
    REG_WINDOWS_AVX512_64_ZMM25H,
    REG_WINDOWS_AVX512_64_ZMM26H,
    REG_WINDOWS_AVX512_64_ZMM27H,
    REG_WINDOWS_AVX512_64_ZMM28H,
    REG_WINDOWS_AVX512_64_ZMM29H,
    REG_WINDOWS_AVX512_64_ZMM30H,
    REG_WINDOWS_AVX512_64_ZMM31H,
    REG_WINDOWS_AVX512_64_LAST = REG_WINDOWS_AVX512_64_ZMM31H
};

} // namespace DEBUGGER_PROTOCOL
#endif // file guard
