[all-commits] [llvm/llvm-project] f6aa50: [SPIR-V]: Fix creation of constants of array types...
Vyacheslav Levytskyy via All-commits
all-commits at lists.llvm.org
Tue Jun 25 01:57:17 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: f6aa50873463ebd9a459b7ccd4989460175a6e7f
https://github.com/llvm/llvm-project/commit/f6aa50873463ebd9a459b7ccd4989460175a6e7f
Author: Vyacheslav Levytskyy <vyacheslav.levytskyy at intel.com>
Date: 2024-06-25 (Tue, 25 Jun 2024)
Changed paths:
M llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp
M llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
M llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
M llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp
M llvm/lib/Target/SPIRV/SPIRVUtils.cpp
A llvm/test/CodeGen/SPIRV/var-uniform-const.ll
Log Message:
-----------
[SPIR-V]: Fix creation of constants of array types in SPIRV Backend (#96514)
This PR fixes https://github.com/llvm/llvm-project/issues/96513.
The way of creation of array type constant was incorrect: instead of
creating [1, 1, 1] or [1, 1, 1, 1, 1, ....] constants, the same [1]
constant was always created, substituting original composite constants.
This in its turn led to a situation when only one of constants might
exist in the code without emitting invalid code, the second constant
would be eventually rewritten to the first constant, because a key to
address both was an array of a single element (like [1]).
This PR fixes the issue and purges from the code unneeded copy/pasted
clone of the function that creates an array constant.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list