How do RV32 and RV64 results differ?
RV64 C/Zca writes one 64-bit register. RV32 requires Zclsd and writes an even/odd pair; the lower register receives the low 32 bits regardless of endianness.
RV64 C/Zca: load a 64-bit doubleword from sp/x2 plus offset; RV32 Zclsd: load into an even/odd register pair.
C.LDSP uses CI format with base sp/x2. The byte offset is 0–504 in multiples of eight, already including scaling; add its zero-extended value to the old base. On RV64 C/Zca, a completed access writes 64 bits to rd. On RV32 Zclsd, the even destination and following odd register receive the low/high 32 bits. rd is a full five-bit field; x0 is reserved.
Shows only official 16-bit fields, address/immediate calculation, and architectural state; it does not simulate a pipeline, cache, endianness implementation, or timing.
RV64 C / Zca
An address divisible by 8 is naturally aligned, so the address-misaligned option does not apply; access faults remain possible. The EEI defines misaligned completion. Memory values are already interpreted using EEI endianness.
RV64 C/Zca: load a 64-bit doubleword from sp/x2 plus offset; RV32 Zclsd: load into an even/odd register pair.
RV64 C/Zca, old sp=0x2000 and mem64[0x2010] = 0x0123456789abcdef, with a completed access: c.ldsp x10, 16(sp) writes x10. RV32 Zclsd writes x10=0x89abcdef and x11=0x01234567, leaving sp unchanged.
RV64 C/Zca writes one 64-bit register. RV32 requires Zclsd and writes an even/odd pair; the lower register receives the low 32 bits regardless of endianness.
RV32 Zclsd makes no such guarantee: the base retains its original value, but other destinations may have been updated. Only a completed load delivers the full pair result.