Skip to content

Commit 6356b15

Browse files
committed
update comment
1 parent f6e7a29 commit 6356b15

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

llvm/lib/Target/SPIRV/SPIRVTargetMachine.cpp

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -192,12 +192,10 @@ void SPIRVPassConfig::addIRPasses() {
192192
TargetPassConfig::addIRPasses();
193193

194194
if (TM.getSubtargetImpl()->isVulkanEnv()) {
195-
// The frontend has a tendency to quickly addrspacecast pointers to the
196-
// default address space, and relies on addrspacecast instructions at the
197-
// boundaries. Vulkan does not allow such things, and we must keep the
198-
// pointer address space stable.
199-
// This pass will determine real address space of a pointer, and patch
200-
// instructions removing Addrspacecasts.
195+
// Vulkan does not allow address space casts. This pass is run to remove
196+
// address space casts that can be removed.
197+
// If an address space cast is not removed while targeting Vulkan, lowering
198+
// will fail during MIR lowering.
201199
addPass(createInferAddressSpacesPass(/* AddressSpace= */ 0));
202200

203201
// 1. Simplify loop for subsequent transformations. After this steps, loops

0 commit comments

Comments
 (0)