From 5482a4237e45196c25f0e7d3cbcc8dfcae30d96f Mon Sep 17 00:00:00 2001 From: Rahul Garg Date: Fri, 16 Mar 2018 12:35:25 +0530 Subject: [PATCH] Fixed function not found issue [ROCm/hip-tests commit: 01ee90d564b2f762000241ad23b38de5581e8268] --- .../samples/2_Cookbook/11_texture_driver/tex2dKernel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip-tests/samples/2_Cookbook/11_texture_driver/tex2dKernel.cpp b/projects/hip-tests/samples/2_Cookbook/11_texture_driver/tex2dKernel.cpp index c817f4e42c..ed223efedf 100644 --- a/projects/hip-tests/samples/2_Cookbook/11_texture_driver/tex2dKernel.cpp +++ b/projects/hip-tests/samples/2_Cookbook/11_texture_driver/tex2dKernel.cpp @@ -23,7 +23,7 @@ THE SOFTWARE. #include "hip/hip_runtime.h" extern texture tex; -__global__ void tex2dKernel(hipLaunchParm lp, float* outputData, int width, int height) { +extern "C" __global__ void tex2dKernel(hipLaunchParm lp, float* outputData, int width, int height) { int x = hipBlockIdx_x * hipBlockDim_x + hipThreadIdx_x; int y = hipBlockIdx_y * hipBlockDim_y + hipThreadIdx_y; outputData[y * width + x] = tex2D(tex, x, y);