Debugging Tools for Windows |
The SetValues2 method sets the value of several of the target's registers.
HRESULT
IDebugRegisters2::SetValues2(
IN ULONG Source,
IN ULONG Count,
IN PULONG Indices,
IN ULONG Start,
IN PDEBUG_VALUE Values
);
The possible values are listed in the following table.
Value | Register source |
---|---|
DEBUG_REGSRC_DEBUGGEE | Fetch register information from the target. |
DEBUG_REGSRC_EXPLICIT | Fetch register information from the current explicit register context. |
DEBUG_REGSRC_FRAME | Fetch register information from the current scope's register context. Note Stack unwinding does not guarantee accurate updating of the register context, so the scope frame's register context might not be accurate in all cases. |
This list does not contain all the errors that might occur. For a list of possible errors, see HRESULT Values.
SetValues2 is available in IDebugRegisters2 and later versions.
The engine does its best to cast the values in Values into the type of the registers; this conversion is the same as that performed by CoerceValue. If the value is larger than what the register can hold, the least significant bits are dropped. Floating-point and integer conversions will also be performed if necessary.
If the return value is not S_OK, some of the registers still might have been set.
When a subregister is altered, the register that contains it is also altered.
The method SetValues performs the same task as this method but always uses the target as the register source.
For an overview of the IDebugRegisters interface and other register-related methods, see Registers.
Headers: Defined in DbgEng.h. Include DbgEng.h.