[all-commits] [llvm/llvm-project] 42633c: [SPIR-V] Improve general validity of emitted code ...
Vyacheslav Levytskyy via All-commits
all-commits at lists.llvm.org
Mon Dec 9 12:10:31 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 42633cf27bd2cfb44e9f332c33cfd6750b9d7be4
https://github.com/llvm/llvm-project/commit/42633cf27bd2cfb44e9f332c33cfd6750b9d7be4
Author: Vyacheslav Levytskyy <vyacheslav.levytskyy at intel.com>
Date: 2024-12-09 (Mon, 09 Dec 2024)
Changed paths:
M llvm/lib/Target/SPIRV/SPIRVBuiltins.cpp
M llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
M llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp
M llvm/lib/Target/SPIRV/SPIRVModuleAnalysis.cpp
M llvm/lib/Target/SPIRV/SPIRVPreLegalizer.cpp
M llvm/lib/Target/SPIRV/SPIRVTargetMachine.cpp
M llvm/test/CodeGen/SPIRV/branching/if-merging.ll
M llvm/test/CodeGen/SPIRV/branching/if-non-merging.ll
M llvm/test/CodeGen/SPIRV/branching/switch-range-check.ll
M llvm/test/CodeGen/SPIRV/debug-info/debug-type-basic.ll
M llvm/test/CodeGen/SPIRV/half_no_extension.ll
M llvm/test/CodeGen/SPIRV/keep-tracked-const.ll
M llvm/test/CodeGen/SPIRV/phi-insert-point.ll
M llvm/test/CodeGen/SPIRV/phi-ptrcast-dominate.ll
M llvm/test/CodeGen/SPIRV/phi-spvintrinsic-dominate.ll
M llvm/test/CodeGen/SPIRV/transcoding/OpConstantSampler.ll
M llvm/test/CodeGen/SPIRV/transcoding/OpPhi_ArgumentsPlaceholders.ll
Log Message:
-----------
[SPIR-V] Improve general validity of emitted code between passes (#119202)
This PR improves general validity of emitted code between passes due to
generation of `TargetOpcode::PHI` instead of `SPIRV::OpPhi` after
Instruction Selection, fixing generation of OpTypePointer instructions
and using of proper virtual register classes.
Using `TargetOpcode::PHI` instead of `SPIRV::OpPhi` after Instruction
Selection has a benefit to support existing optimization passes
immediately, as an alternative path to disable those passes that use
`MI.isPHI()`. This PR makes it possible thus to revert
https://github.com/llvm/llvm-project/pull/116060 actions and get back to
use the `MachineSink` pass.
This PR is a solution of the problem discussed in details in
https://github.com/llvm/llvm-project/pull/110507. It accepts an advice
from code reviewers of the PR #110507 to postpone generation of OpPhi
rather than to patch CodeGen. This solution allows to unblock
improvements wrt. expensive checks and makes it unrelated to the general
points of the discussion about OpPhi vs. G_PHI/PHI.
This PR contains numerous small patches of emitted code validity that
allows to substantially pass rate with expensive checks. Namely, the
test suite with expensive checks set ON now has only 12 fails out of 569
total test cases.
FYI @bogner
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