Generate Universal Unique Identifier (GENUUID)


Op Code (Hex) Operand 1


011D
UUID return template



Operand 1: Space pointer.

Bound program access

Built-in number for GENUUID is 461. GENUUID ( UUID_return_template : address )

Description

This instruction generates a universal unique identifier and returns it in the template provided. The UUID is unique as an identifier across all time and space and is consistent with the Open Systems Foundation (OSF) Distributed Computing Environments (DCE) version 1 UUID specification described in the DCE's "Architecture Environment Specification/Distributed Computing: for Remote Procedure Calls", Appendix A. The template identified by operand 1 must be 16 byte aligned. The 16 byte Universal Unique Identifier (UUID) is returned in the UUID return template.

The UUID return template (operand 1) has the following format:

Offset
Dec Hex
Field Name
Data Type and Length
0 0
Return template size specification
Char(8)
0 0
Number of bytes provided
UBin(4)
4 4
Number of bytes available
UBin(4)
8 8
Reserved (binary 0)
Char(8)
16 10
Returned UUID
Char(16)
32 20
--- End ---

The first 4 bytes of the template identify the total number of bytes provided for use by the instruction. The value is supplied as input to the instruction and is not modified by the instruction. A value of less than 32 causes a template size invalid  (hex 3802) exception to be signaled.

The second 4 bytes of the template identify the total number of bytes available to be returned. This value is output. The value is the size of the template.

The reserved field must be set to zeros or a template value invalid  (hex 3801) exception will be signaled.

The returned UUID field contains the generated UUID. The UUID is a DCE version 1 UUID.

Note: There are certain restrictions on the UUID that should be remembered:

Authorization Required

Lock Enforcement

Exceptions

06 Addressing

08 Argument/Parameter

20 Machine Support

24 Pointer Specification

32 Scalar Specification

38 Template Specification

44 Protection Violation