Hi,
In SVA, I see “ASSOCIATIVITY” for different operators.
For example -
Can someone please help me understand this concept?
Thanks in advance.
Regards,
Naveen
Hi,
In SVA, I see “ASSOCIATIVITY” for different operators.
For example -
Can someone please help me understand this concept?
Thanks in advance.
Regards,
Naveen
In reply to naveensv:
A left-associative operator, like subtraction, groups the leftmost elements first. A right-associative operator, like exponentiation, groups the rightmost elements first. An operator is non-associative when it doesn’t make sense to use in succession
The associativity indicates in what order operators of equal precedence in an expression are applied; thus
// and operator has a left associativity
(a and b and c and d) are left associated as
( ( ( (a and b) and c) and d)).
Ben Cohen
http://www.systemverilog.us/ ben@systemverilog.us
For training, consulting, services: contact Home - My cvcblr
Hi @ben@SystemVerilog.us I don’t get clear idea on ur explanation.
Can I pls elaborate it.
Thanks in advance
In reply to VK_18:
The associativity indicates in what order operators of equal precedence in an expression are applied; thus
// and operator has a left associativity
(a and b and c and d) are left associated as
( ( ( (a and b) and c) and d)).
In this case, a tool can short circuit the computation (i. E., go no further evaluation) if (a and b)==0.
Ben Ben@systemverilog.us