We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc7a605 commit bf5639aCopy full SHA for bf5639a
llvm/lib/Target/NVPTX/SYCL/GlobalOffset.cpp
@@ -321,8 +321,11 @@ class GlobalOffset : public ModulePass {
321
assert(NvvmMetadata && "IR compiled to PTX must have nvvm.annotations");
322
323
SmallPtrSet<GlobalValue *, 8u> Used;
324
- collectUsedGlobalVariables(M, Used, /*CompilerUsed=*/false);
325
- collectUsedGlobalVariables(M, Used, /*CompilerUsed=*/true);
+ SmallVector<GlobalValue *, 4> Vec;
+ collectUsedGlobalVariables(M, Vec, /*CompilerUsed=*/false);
326
+ collectUsedGlobalVariables(M, Vec, /*CompilerUsed=*/true);
327
+ Used = {Vec.begin(), Vec.end()};
328
+
329
auto HasUseOtherThanLLVMUsed = [&Used](GlobalValue *GV) {
330
if (GV->use_empty())
331
return false;
0 commit comments