Basic constructor macro for instr-lui structures.
(make-instr-lui [:rd <rd>] [:imm <imm>])
This is the usual way to construct instr-lui structures. It simply conses together a structure with the specified fields.
This macro generates a new instr-lui structure from scratch. See also change-instr-lui, which can "change" an existing structure, instead.
This is an ordinary
Macro:
(defmacro make-instr-lui (&rest args) (std::make-aggregate 'instr-lui args '((:rd) (:imm)) 'make-instr-lui nil))
Function:
(defun instr-lui (rd imm) (declare (xargs :guard (and (ubyte5p rd) (ubyte20p imm)))) (declare (xargs :guard t)) (let ((__function__ 'instr-lui)) (declare (ignorable __function__)) (b* ((rd (mbe :logic (ubyte5-fix rd) :exec rd)) (imm (mbe :logic (ubyte20-fix imm) :exec imm))) (cons :lui (list rd imm)))))