32-Bit Instruction Set

WRCTL

Write Control Register

Operation:

 

 

 

CTLk RA

 

 

 

 

 

 

 

 

 

 

 

 

Assembler Syntax:

 

WRCTL %rA

 

 

 

 

 

 

 

 

 

 

 

 

Example:

 

 

 

Not preceded by PFX:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

WRCTL %g7 ; writes %g7 to STATUS reg

 

 

 

 

 

 

 

 

 

NOP ; required

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Preceded by PFX:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

PFX 1

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

WRCTL %g7 ; writes %g7 to ISTATUS reg

 

 

 

 

Description:

 

 

 

Not preceded by PFX:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Loads the STATUS register with RA. WRTCL to STATUS must be followed by a

 

 

 

 

 

NOP instruction.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Preceded by PFX:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Writes the value in RA to the machine-control register selected by K. See the

 

 

 

 

 

programmer’s model for a list of the machine-control registers and their indices.

Condition Codes:

 

If the target of WRCTL is the STATUS register, then the condition-code flags are

 

 

 

 

 

directly set by the WRCTL operation from bits RA[3..0]. For any other WRCTL

 

 

 

 

 

target register, the condition codes are unaffected.

 

 

 

 

Instruction Format:

 

Rw

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Instruction Fields:

 

A = Register index of operand RA

 

 

 

 

 

 

 

15

14

13

 

12

11

10

 

9

 

8

7

 

6

5

4

3

2

1

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0

1

1

 

1

1

1

 

1

 

1

0

 

0

0

 

 

A

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

104

Altera Corporation

Page 116
Image 116
Excalibur electronic A-MNL-NIOSPROG-01.1 manual Wrctl, Write Control Register