llvm-project/llvm/test/CodeGen/SPIRV
Ilia Diachkov 3544d200d9 [SPIRV] add IR regularization pass
The patch adds the regularization pass that prepare LLVM IR for
the IR translation. It also contains following changes:
- reduce indentation, make getNonParametrizedType, getSamplerType,
getPipeType, getImageType, getSampledImageType static in SPIRVBuiltins,
- rename mayBeOclOrSpirvBuiltin to getOclOrSpirvBuiltinDemangledName,
- move isOpenCLBuiltinType, isSPIRVBuiltinType, isSpecialType from
SPIRVGlobalRegistry.cpp to SPIRVUtils.cpp, renaming isSpecialType to
isSpecialOpaqueType,
- implment getTgtMemIntrinsic() in SPIRVISelLowering,
- add hasSideEffects = 0 in Pseudo (SPIRVInstrFormats.td),
- add legalization rule for G_MEMSET, correct G_BRCOND rule,
- add capability processing for OpBuildNDRange in SPIRVModuleAnalysis,
- don't correct types of registers holding constants and used in
G_ADDRSPACE_CAST (SPIRVPreLegalizer.cpp),
- lower memset/bswap intrinsics to functions in SPIRVPrepareFunctions,
- change TargetLoweringObjectFileELF to SPIRVTargetObjectFile
in SPIRVTargetMachine.cpp,
- correct comments.
5 LIT tests are added to show the improvement.

Differential Revision: https://reviews.llvm.org/D133253

Co-authored-by: Aleksandr Bezzubikov <zuban32s@gmail.com>
Co-authored-by: Michal Paszkowski <michal.paszkowski@outlook.com>
Co-authored-by: Andrey Tretyakov <andrey1.tretyakov@intel.com>
Co-authored-by: Konrad Trifunovic <konrad.trifunovic@intel.com>
2022-09-15 15:53:44 +03:00
..
SpecConstants [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
branching [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
constant [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
extensions [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
function [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
instructions [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
llvm-intrinsics [SPIRV] add IR regularization pass 2022-09-15 15:53:44 +03:00
opencl [SPIRV] add IR regularization pass 2022-09-15 15:53:44 +03:00
transcoding [SPIRV] add IR regularization pass 2022-09-15 15:53:44 +03:00
AtomicCompareExchange.ll [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
CheckCapKernelWithoutKernel.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
ComparePointers.ll [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
ExecutionMode.ll [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
FOrdGreaterThanEqual_bool.ll [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
FOrdGreaterThanEqual_int.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
LinkOnceODR.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
OpVectorInsertDynamic.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
SampledImageRetType.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
TruncToBool.ll [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
atomicrmw.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
builtin_vars-decorate.ll [SPIRV] support builtin functions 2022-08-25 00:30:33 +03:00
capability-Int64Atomics-store.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
capability-Int64Atomics.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
capability-integers.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
capability-kernel.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
empty-module.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
empty-opencl32.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
empty-opencl64.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
empty.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
event_no_group_cap.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
exec_mode_float_control_khr.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
half_extension.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
half_no_extension.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
image-unoptimized.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
image.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
image_decl_func_arg.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
image_dim.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
image_store.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
link-attribute.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
linkage-types.ll [SPIRV] Add tests to improve test coverage 2022-08-28 22:18:11 +03:00
linked-list.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
lit.local.cfg
literal-struct.ll [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
lshr-constexpr.ll [SPIRV] add IR regularization pass 2022-09-15 15:53:44 +03:00
mangled_function.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
memory_model_md.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
metadata-opencl.ll [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
multi_md.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
no_capability_shader.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
opaque_pointers.ll [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
opencl.queue_t.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
optnone.ll [SPIRV] Add simple tests to improve test coverage 2022-05-19 01:44:38 +03:00
preprocess-metadata.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
pstruct.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
read_image.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
relationals.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
select.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
simple.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
sitofp-with-bool.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
spec_const_decoration.ll [SPIRV] Add tests to improve test coverage 2022-09-05 15:52:01 +03:00
spirv-tools-dis.ll [SPIRV] Add tests to improve test coverage 2022-09-02 11:59:18 +03:00
spirv.Queue.ll [SPIRV] Add tests to improve test coverage 2022-09-02 13:19:28 +03:00
spirv_param_decorations.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
spirv_param_decorations_quals.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
store.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00
struct.ll [SPIRV] Fix style of LIT tests and remove metadata 2022-08-03 02:33:24 +03:00
uitofp-with-bool.ll [SPIRV] Add tests to improve test coverage 2022-08-02 20:22:40 +03:00