Se recomienda usar Visual Studio 2017
Esta documentación está archivada y no tiene mantenimiento.


Microsoft Specific

Gets the contents of a register specified with a constant that are the same values as declared in the header file intrin.h.

unsigned __int64 __getReg(
   int Register

[in] Register

A constant specifying the desired processor register.

The contents of the register indicated.





Header file <intrin.h>

This routine is only available as an intrinsic. Not all registers are readable. If you call this with an invalid register, a compile time error results.

// getReg.cpp
// processor: IPF
#include <cstdio>
#include <stdio.h>
#include <intrin.h>
#define __REG_IA64_IntR1 1025

#pragma intrinsic(__getReg)

int main()
    unsigned __int64 reg;
    reg = __getReg(__REG_IA64_IntR1);
    printf_s("%I64d\n", reg);
    return 0;