Why does c.andi have register restrictions?
Many C formats encode registers with shorter fields, so some forms can access only x8..x15 or fixed registers.
Bitwise AND of rd' with sign-extended 6-bit imm. CB format.
c.andi ANDs rd' with a sign-extended 6-bit immediate and writes rd'.
c.andi ANDs rd' with a sign-extended 6-bit immediate and writes rd'.
Understand this scenario with real code like «c.andi x8, 0xF # x8 &= 0xF».
Many C formats encode registers with shorter fields, so some forms can access only x8..x15 or fixed registers.
No. It is a 16-bit encoded instruction defined by the C extension.