Exportar (0) Imprimir
Expandir todo
Expandir Minimizar

__setReg

Microsoft Specific

Sets the value of a register specified by the first parameter, which are the same values as declared in the header file intrin.h.


void __setReg( 
   int Register, 
   unsigned __int64 Value 
);

[in] Register

A constant specifying the desired processor register.

[in] Value

The value to set in the specified register.

Intrinsic

Architecture

__setReg

IPF

Header file <intrin.h>

Attempting to write directly to processor registers can produce unexpected results. Some registers are not writeable in user mode and might throw a hardware exception or ignore attempts to write to them. For more information, see the processor documentation.

This routine is only available as an intrinsic.

// setReg.cpp
// processor: IPF
#include <cstdio>
#include <intrin.h>
#define __CV_IPF_IntR10 1034

#pragma intrinsic(__setReg)
#pragma intrinsic(__getReg)

int main()
{
    __setReg(__CV_IPF_IntR10, 167);
    printf_s("%I64d\n", __getReg(__CV_IPF_IntR10));
   
    return 0;
}
167

Adiciones de comunidad

AGREGAR
Mostrar:
© 2014 Microsoft