diff --git a/src/panfrost/compiler/valhall/ISA.xml b/src/panfrost/compiler/valhall/ISA.xml index 4d5e74893c4..2ad636d662b 100644 --- a/src/panfrost/compiler/valhall/ISA.xml +++ b/src/panfrost/compiler/valhall/ISA.xml @@ -1433,6 +1433,23 @@ Index + + + Load from memory with data conversion. The address to load from is given in + the first source, which must be a 64-bit register (a pair of 32-bit + registers). The other source is the conversion descriptor used for the load. + + + + + + + + 64-bit address to load from + + Internal conversion descriptor + + Store to memory with data conversion. The address to store to is given in diff --git a/src/panfrost/compiler/valhall/va_pack.c b/src/panfrost/compiler/valhall/va_pack.c index 4f3caa83e8f..6bcaae9fab3 100644 --- a/src/panfrost/compiler/valhall/va_pack.c +++ b/src/panfrost/compiler/valhall/va_pack.c @@ -975,6 +975,15 @@ va_pack_instr(const bi_instr *I, unsigned arch) break; + case BI_OPCODE_LD_CVT: + hex |= (uint64_t)va_pack_src(I, 0); + hex |= va_pack_byte_offset(I); + + /* Conversion descriptor */ + hex |= (uint64_t)va_pack_src(I, 2) << 16; + hex |= va_pack_memory_access(I) << 37; + break; + case BI_OPCODE_ST_CVT: /* Staging read */ hex |= va_pack_store(I);