]> granicus.if.org Git - clang/commitdiff
revert r354615: [HIP] change kernel stub name
authorYaxun Liu <Yaxun.Liu@amd.com>
Fri, 22 Feb 2019 04:20:12 +0000 (04:20 +0000)
committerYaxun Liu <Yaxun.Liu@amd.com>
Fri, 22 Feb 2019 04:20:12 +0000 (04:20 +0000)
It caused regressions.

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@354651 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGCUDANV.cpp
test/CodeGenCUDA/device-stub.cu

index 6f7295bf4b39c64295c077909a684f78acfe4a81..62661039a32a1a089b287d44cbb17aa41b807482 100644 (file)
@@ -227,12 +227,6 @@ void CGNVCUDARuntime::emitDeviceStub(CodeGenFunction &CGF,
     emitDeviceStubBodyNew(CGF, Args);
   else
     emitDeviceStubBodyLegacy(CGF, Args);
-
-  // Postfix kernel stub names with .stub to differentiate them from kernel
-  // names in device binaries. This is to facilitate the debugger to find
-  // the correct symbols for kernels in the device binary.
-  if (CGF.getLangOpts().HIP)
-    CGF.CurFn->setName(CGF.CurFn->getName() + ".stub");
 }
 
 // CUDA 9.0+ uses new way to launch kernels. Parameters are packed in a local
index 3be0e7b2ec4b3dd987533243b77dd681b825dc87..387a787cceb80905676c01cdeeb5307c9148b528 100644 (file)
@@ -145,8 +145,7 @@ void use_pointers() {
 // Test that we build the correct number of calls to cudaSetupArgument followed
 // by a call to cudaLaunch.
 
-// CUDA-LABEL: define{{.*}}kernelfunc
-// HIP-LABEL: define{{.*}}@_Z10kernelfunciii.stub
+// LNX: define{{.*}}kernelfunc
 
 // New launch sequence stores arguments into local buffer and passes array of
 // pointers to them directly to cudaLaunchKernel