Product Documentation
Cadence SKILL Language Reference
Product Version IC23.1, November 2023

setqbitfield

setqbitfield( 
s_var 
x_val 
x_msb 
x_lsb 
) 
=> x_result

Description

Sets a value into a set of bits in the bit field specified by the variable s_var, stores the new value back into the variable, and then returns the new value. Prefix form of the <:>= operator.

Arguments

s_var

Variable representing the bit field whose value is to be changed.

x_val

New value of the bit.

x_msb

Leftmost bit of the set of bits whose value is to be changed.

x_lsb

Rightmost bit of the set of bits whose value is to be changed.

Value Returned

x_result

New value of s_var.

Examples

x = 0
setqbitfield(x 0b1001 3 0) 
=> 9
x => 9
setqbitfield(x 1 2 1) 
=> 11
x => 11
setqbitfield(x 0 3 2) 
=> 3
x => 3

Related Topics

bitfield

setqbitfield1


Return to top
 ⠀
X