brintos

brintos / llvm-project-archived public Read only

0
0
Text · 9.4 KiB · 8de520a Raw
201 lines · plain
1# RUN: llvm-mc -triple=riscv32 -show-encoding --mattr=+xsfmmbase, \2# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \3# RUN:        | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST4# RUN: llvm-mc -triple=riscv64 -show-encoding --mattr=+xsfmmbase, \5# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \6# RUN:        | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST7# RUN: not llvm-mc -triple=riscv32 -show-encoding %s 2>&1 \8# RUN:        | FileCheck %s --check-prefix=CHECK-ERROR9# RUN: not llvm-mc -triple=riscv64 -show-encoding %s 2>&1 \10# RUN:        | FileCheck %s --check-prefix=CHECK-ERROR11# RUN: llvm-mc -triple=riscv32 -filetype=obj --mattr=+xsfmmbase, \12# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \13# RUN:        | llvm-objdump -d  --mattr=+xsfmmbase, \14# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f --no-print-imm-hex - \15# RUN:        | FileCheck %s --check-prefix=CHECK-INST16# RUN: llvm-mc -triple=riscv64 -filetype=obj --mattr=+xsfmmbase, \17# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \18# RUN:        | llvm-objdump -d  --mattr=+xsfmmbase, \19# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f --no-print-imm-hex - \20# RUN:        | FileCheck %s --check-prefix=CHECK-INST21# RUN: llvm-mc -triple=riscv32 -filetype=obj --mattr=+xsfmmbase, \22# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \23# RUN:        | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN24# RUN: llvm-mc -triple=riscv64 -filetype=obj --mattr=+xsfmmbase, \25# RUN:     --mattr=+xsfmm32a32f,+xsfmm32a8i,+xsfmm32a8f,+xsfmm64a64f %s \26# RUN:        | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN27 28# CHECK-INST: sf.vsettnt a0, a1, e8, w129# CHECK-ENCODING: [0x57,0xf5,0x05,0x20]30# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}31# CHECK-UNKNOWN: 2005f557 <unknown>32sf.vsettnt a0, a1, e8, w133 34# CHECK-INST: sf.vsettnt a0, a1, e16alt, w135# CHECK-ENCODING: [0x57,0xf5,0x85,0x30]36# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}37# CHECK-UNKNOWN: 3085f557 <unknown>38sf.vsettnt a0, a1, e16alt, w139 40# CHECK-INST: sf.vsettnt a0, a1, e8, w141# CHECK-ENCODING: [0x57,0xf5,0x05,0x20]42# CHECK-ERROR: instruction requires the following: 'V' (Vector Extension for Application Processors), 'Zve32x' (Vector Extensions for Embedded Processors)43# CHECK-UNKNOWN: 2005f557 <unknown>44vsetvli a0, a1, 0x20045 46# CHECK-INST: sf.vsettnt a0, a1, e16alt, w147# CHECK-ENCODING: [0x57,0xf5,0x85,0x30]48# CHECK-ERROR: instruction requires the following: 'V' (Vector Extension for Application Processors), 'Zve32x' (Vector Extensions for Embedded Processors)49# CHECK-UNKNOWN: 3085f557 <unknown>50vsetvli a0, a1, 0x30851 52# CHECK-INST: sf.vsettn a0, a153# CHECK-ENCODING: [0x57,0xf5,0x05,0x84]54# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}55# CHECK-UNKNOWN: 8405f557 <unknown>56sf.vsettn a0, a157 58# CHECK-INST: sf.vsettm a0, a159# CHECK-ENCODING: [0x57,0xf5,0x15,0x84]60# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}61# CHECK-UNKNOWN: 8415f557 <unknown>62sf.vsettm a0, a163 64# CHECK-INST: sf.vsettk a0, a165# CHECK-ENCODING: [0x57,0xf5,0x25,0x84]66# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}67# CHECK-UNKNOWN: 8425f557 <unknown>68sf.vsettk a0, a169 70# CHECK-INST: sf.vlte8  a0, (a1)71# CHECK-ENCODING: [0x07,0xf0,0xa5,0x12]72# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}73# CHECK-UNKNOWN: 12a5f007 <unknown>74sf.vlte8  a0, (a1)75 76# CHECK-INST: sf.vlte16 a0, (a1)77# CHECK-ENCODING: [0x07,0xf0,0xa5,0x32]78# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}79# CHECK-UNKNOWN: 32a5f007 <unknown>80sf.vlte16 a0, (a1)81 82# CHECK-INST: sf.vlte32 a0, (a1)83# CHECK-ENCODING: [0x07,0xf0,0xa5,0x52]84# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}85# CHECK-UNKNOWN: 52a5f007 <unknown>86sf.vlte32 a0, (a1)87 88# CHECK-INST: sf.vlte64 a0, (a1)89# CHECK-ENCODING: [0x07,0xf0,0xa5,0x72]90# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}91# CHECK-UNKNOWN: 72a5f007 <unknown>92sf.vlte64 a0, (a1)93 94# CHECK-INST: sf.vste8  a0, (a1)95# CHECK-ENCODING: [0x27,0xf0,0xa5,0x12]96# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}97# CHECK-UNKNOWN: 12a5f027 <unknown>98sf.vste8  a0, (a1)99 100# CHECK-INST: sf.vste16 a0, (a1)101# CHECK-ENCODING: [0x27,0xf0,0xa5,0x32]102# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}103# CHECK-UNKNOWN: 32a5f027 <unknown>104sf.vste16 a0, (a1)105 106# CHECK-INST: sf.vste32 a0, (a1)107# CHECK-ENCODING: [0x27,0xf0,0xa5,0x52]108# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}109# CHECK-UNKNOWN: 52a5f027 <unknown>110sf.vste32 a0, (a1)111 112# CHECK-INST: sf.vste64 a0, (a1)113# CHECK-ENCODING: [0x27,0xf0,0xa5,0x72]114# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}115# CHECK-UNKNOWN: 72a5f027 <unknown>116sf.vste64 a0, (a1)117 118# CHECK-INST: sf.vtmv.v.t v8, a0119# CHECK-ENCODING: [0x57,0x64,0xf5,0x43]120# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}121# CHECK-UNKNOWN: 43f56457 <unknown>122sf.vtmv.v.t v8, a0123 124# CHECK-INST: sf.vtmv.t.v a0, v8125# CHECK-ENCODING: [0x57,0x60,0x85,0x5e]126# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}127# CHECK-UNKNOWN: 5e856057 <unknown>128sf.vtmv.t.v a0, v8129 130# CHECK-INST: sf.mm.f.f mt2, v8, v9131# CHECK-ENCODING: [0x77,0x92,0x84,0xf2]132# CHECK-ERROR: instruction requires the following: 'XSfmm32a16f' (TEW=32-bit accumulation, operands - float: 16b, widen=2 (IEEE, BF)), or 'XSfmm32a32f' (TEW=32-bit accumulation, operands - float: 32b), or 'XSfmm64a64f' (TEW=64-bit accumulation, operands - float: fp64){{$}}133# CHECK-UNKNOWN: f2849277 <unknown>134sf.mm.f.f mt2, v8, v9135 136# CHECK-INST: sf.mm.e5m2.e5m2 mt0, v8, v9137# CHECK-ENCODING: [0x77,0x90,0x84,0xfa]138# CHECK-ERROR: instruction requires the following: 'XSfmm32a8f' (TEW=32-bit accumulation, operands - float: fp8){{$}}139# CHECK-UNKNOWN: fa849077 <unknown>140sf.mm.e5m2.e5m2 mt0, v8, v9141 142# CHECK-INST: sf.mm.e5m2.e4m3 mt4, v8, v9143# CHECK-ENCODING: [0xf7,0x94,0x84,0xfa]144# CHECK-ERROR: instruction requires the following: 'XSfmm32a8f' (TEW=32-bit accumulation, operands - float: fp8){{$}}145# CHECK-UNKNOWN: fa8494f7 <unknown>146sf.mm.e5m2.e4m3 mt4, v8, v9147 148# CHECK-INST: sf.mm.e4m3.e5m2 mt8, v8, v9149# CHECK-ENCODING: [0x77,0x98,0x84,0xfe]150# CHECK-ERROR: instruction requires the following: 'XSfmm32a8f' (TEW=32-bit accumulation, operands - float: fp8){{$}}151# CHECK-UNKNOWN: fe849877 <unknown>152sf.mm.e4m3.e5m2 mt8, v8, v9153 154# CHECK-INST: sf.mm.e4m3.e4m3 mt12, v8, v9155# CHECK-ENCODING: [0xf7,0x9c,0x84,0xfe]156# CHECK-ERROR: instruction requires the following: 'XSfmm32a8f' (TEW=32-bit accumulation, operands - float: fp8){{$}}157# CHECK-UNKNOWN: fe849cf7 <unknown>158sf.mm.e4m3.e4m3 mt12, v8, v9159 160# CHECK-INST: sf.mm.u.u mt0, v8, v9161# CHECK-ENCODING: [0x77,0x80,0x84,0xf2]162# CHECK-ERROR: instruction requires the following: 'XSfmm32a8i' (TEW=32-bit accumulation, operands - int: 8b){{$}}163# CHECK-UNKNOWN: f2848077 <unknown>164sf.mm.u.u mt0, v8, v9165 166# CHECK-INST: sf.mm.s.u mt4, v8, v9167# CHECK-ENCODING: [0x77,0x84,0x84,0xf6]168# CHECK-ERROR: instruction requires the following: 'XSfmm32a8i' (TEW=32-bit accumulation, operands - int: 8b){{$}}169# CHECK-UNKNOWN: f6848477 <unknown>170sf.mm.s.u mt4, v8, v9171 172# CHECK-INST: sf.mm.u.s mt8, v8, v9173# CHECK-ENCODING: [0xf7,0x88,0x84,0xf2]174# CHECK-ERROR: instruction requires the following: 'XSfmm32a8i' (TEW=32-bit accumulation, operands - int: 8b){{$}}175# CHECK-UNKNOWN: f28488f7 <unknown>176sf.mm.u.s mt8, v8, v9177 178# CHECK-INST: sf.mm.s.s mt12, v8, v9179# CHECK-ENCODING: [0xf7,0x8c,0x84,0xf6]180# CHECK-ERROR: instruction requires the following: 'XSfmm32a8i' (TEW=32-bit accumulation, operands - int: 8b){{$}}181# CHECK-UNKNOWN: f6848cf7 <unknown>182sf.mm.s.s mt12, v8, v9183 184# CHECK-INST: sf.vtzero.t mt15185# CHECK-ENCODING: [0x57,0x6f,0xe0,0x43]186# CHECK-ERROR: instruction requires the following: 'XSfmmbase' (All non arithmetic instructions for all TEWs and sf.vtzero){{$}}187# CHECK-UNKNOWN: 43e06f57 <unknown>188sf.vtzero.t mt15189 190# CHECK-INST: vsetvl a2, a0, a1191# CHECK-ENCODING: [0x57,0x76,0xb5,0x80]192# CHECK-ERROR: instruction requires the following: 'V' (Vector Extension for Application Processors), 'Zve32x' (Vector Extensions for Embedded Processors)193# CHECK-UNKNOWN: 80b57657 <unknown>194vsetvl a2, a0, a1195 196# CHECK-INST:  vsetvli a0, a1, e8, m1, tu, mu197# CHECK-ENCODING: [0x57,0xf5,0x05,0x00]198# CHECK-ERROR: instruction requires the following: 'V' (Vector Extension for Application Processors), 'Zve32x' (Vector Extensions for Embedded Processors)199# CHECK-UNKNOWN: 0005f557 <unknown>200vsetvli a0, a1, e8, m1, tu, mu201