Intel® C++ Compiler Classic Developer Guide and Reference

ID 767249
Date 3/31/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

_xend

Specifies the end of a restricted transactional memory (RTM) code region. The corresponding Intel® AVX2 instruction is XEND.

Syntax

void _xend(void);

Arguments

None.

Description

Specifies the end of restricted transactional memory code region. If this is the outermost transaction (including this xend instruction, the number of xbegin matches the number of xend instructions) then the processor will attempt to commit processor state automatically.

If the commit fails, the processor will rollback all register and memory updates performed during the RTM execution.

The logical processor will resume execution at the fallback address computed from the outermost xbegin instruction. The EAX register is updated to reflect RTM abort information. When xend is executed outside a transaction will cause a general protection fault (#GP).

The model instruction sequence for xend support is:

__inline void _xend() { 
  __asm { xend }
}

Returns

Result of the query.