Is it always equivalent to a same-named 32-bit instruction?
Not always. Some C/Zc instructions compress common 32-bit operations, while others have dedicated stack-frame or table-jump semantics.
Restore registers, deallocate frame, and ret
CM.POPRET (Zcmp) pops registers in {reg_list}, adjusts sp, then executes ret. It does not write a0. It reuses c.fsdsp encoding and is therefore incompatible with Zcd. After the loads complete, the final atomic section commits the sp adjustment and ret. It is part of Zcmp and depends on Zca.
Shows only Zcmp architectural sequences and conditions; access order, grouping, or replay does not imply implementation detail.
Zcmp depends on Zca and is incompatible with Zcd. Correct execution requires idempotent memory at sp; RV32E permits rlist=4-6 only.
CM.POPRET is the 16-bit encoding form for compressed pop and return; its semantics and encodable register/immediate ranges must be read from the official Zc extension rules.
Understand this scenario with real code like «cm.popret {ra, s0-s3}, 32 # pop ra,s0-s3, sp+=32, ret».
Understand this scenario with real code like «cm.popret {ra, s0-s3}, 32 # pop ra,s0-s3, sp+=32, ret».
Understand this scenario with real code like «cm.popret {ra, s0-s3}, 32 # pop ra,s0-s3, sp+=32, ret».
Not always. Some C/Zc instructions compress common 32-bit operations, while others have dedicated stack-frame or table-jump semantics.
Many 16-bit encodings can represent only a compressed register subset or fixed registers such as sp, ra, a0/a1.