summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2016-07-15 21:33:06 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2016-07-15 21:33:06 +0000
commitc7536a5d60aa1568b0014dc9da3214d62b26e808 (patch)
tree22e9f1edc6a26279d529340e14378ba43d49a1eb
parentc86671da09b79feef15c2167441e19bda59559fb (diff)
downloadbcm5719-llvm-c7536a5d60aa1568b0014dc9da3214d62b26e808.tar.gz
bcm5719-llvm-c7536a5d60aa1568b0014dc9da3214d62b26e808.zip
AMDGPU: Remove legacy ldexp builtin
llvm-svn: 275623
-rw-r--r--clang/include/clang/Basic/BuiltinsAMDGPU.def7
-rw-r--r--clang/lib/CodeGen/CGBuiltin.cpp8
-rw-r--r--clang/test/CodeGenOpenCL/builtins-amdgcn.cl16
-rw-r--r--clang/test/CodeGenOpenCL/builtins-r600.cl16
4 files changed, 0 insertions, 47 deletions
diff --git a/clang/include/clang/Basic/BuiltinsAMDGPU.def b/clang/include/clang/Basic/BuiltinsAMDGPU.def
index 4656677e7c9..ea63ea10f84 100644
--- a/clang/include/clang/Basic/BuiltinsAMDGPU.def
+++ b/clang/include/clang/Basic/BuiltinsAMDGPU.def
@@ -99,12 +99,5 @@ BUILTIN(__builtin_r600_read_tidig_z, "Ui", "nc")
BUILTIN(__builtin_r600_recipsqrt_ieee, "dd", "nc")
BUILTIN(__builtin_r600_recipsqrt_ieeef, "ff", "nc")
-//===----------------------------------------------------------------------===//
-// Legacy names with amdgpu prefix
-//===----------------------------------------------------------------------===//
-
-BUILTIN(__builtin_amdgpu_ldexp, "ddi", "nc")
-BUILTIN(__builtin_amdgpu_ldexpf, "ffi", "nc")
-
#undef BUILTIN
#undef TARGET_BUILTIN
diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp
index dbff809ab5e..c74e53ea84e 100644
--- a/clang/lib/CodeGen/CGBuiltin.cpp
+++ b/clang/lib/CodeGen/CGBuiltin.cpp
@@ -7690,14 +7690,6 @@ Value *CodeGenFunction::EmitAMDGPUBuiltinExpr(unsigned BuiltinID,
return emitRangedBuiltin(*this, Intrinsic::r600_read_tidig_y, 0, 1024);
case AMDGPU::BI__builtin_r600_read_tidig_z:
return emitRangedBuiltin(*this, Intrinsic::r600_read_tidig_z, 0, 1024);
-
- // Legacy amdgpu prefix
- case AMDGPU::BI__builtin_amdgpu_ldexp:
- case AMDGPU::BI__builtin_amdgpu_ldexpf: {
- if (getTarget().getTriple().getArch() == Triple::amdgcn)
- return emitFPIntBuiltin(*this, E, Intrinsic::amdgcn_ldexp);
- return emitFPIntBuiltin(*this, E, Intrinsic::AMDGPU_ldexp);
- }
default:
return nullptr;
}
diff --git a/clang/test/CodeGenOpenCL/builtins-amdgcn.cl b/clang/test/CodeGenOpenCL/builtins-amdgcn.cl
index 51f15866070..6cac2a44bc7 100644
--- a/clang/test/CodeGenOpenCL/builtins-amdgcn.cl
+++ b/clang/test/CodeGenOpenCL/builtins-amdgcn.cl
@@ -268,22 +268,6 @@ void test_read_exec(global ulong* out) {
// CHECK: declare i64 @llvm.read_register.i64(metadata) #[[NOUNWIND_READONLY:[0-9]+]]
-// Legacy intrinsics with AMDGPU prefix
-
-// CHECK-LABEL: @test_legacy_ldexp_f32
-// CHECK: call float @llvm.amdgcn.ldexp.f32
-void test_legacy_ldexp_f32(global float* out, float a, int b)
-{
- *out = __builtin_amdgpu_ldexpf(a, b);
-}
-
-// CHECK-LABEL: @test_legacy_ldexp_f64
-// CHECK: call double @llvm.amdgcn.ldexp.f64
-void test_legacy_ldexp_f64(global double* out, double a, int b)
-{
- *out = __builtin_amdgpu_ldexp(a, b);
-}
-
// CHECK-LABEL: @test_kernarg_segment_ptr
// CHECK: call i8 addrspace(2)* @llvm.amdgcn.kernarg.segment.ptr()
void test_kernarg_segment_ptr(__attribute__((address_space(2))) unsigned char ** out)
diff --git a/clang/test/CodeGenOpenCL/builtins-r600.cl b/clang/test/CodeGenOpenCL/builtins-r600.cl
index 0951ff8182e..027a54a6bce 100644
--- a/clang/test/CodeGenOpenCL/builtins-r600.cl
+++ b/clang/test/CodeGenOpenCL/builtins-r600.cl
@@ -17,22 +17,6 @@ void test_recipsqrt_ieee_f64(global double* out, double a)
}
#endif
-// CHECK-LABEL: @test_legacy_ldexp_f32
-// CHECK: call float @llvm.AMDGPU.ldexp.f32
-void test_legacy_ldexp_f32(global float* out, float a, int b)
-{
- *out = __builtin_amdgpu_ldexpf(a, b);
-}
-
-#if cl_khr_fp64
-// XCHECK-LABEL: @test_legacy_ldexp_f64
-// XCHECK: call double @llvm.AMDGPU.ldexp.f64
-void test_legacy_ldexp_f64(global double* out, double a, int b)
-{
- *out = __builtin_amdgpu_ldexp(a, b);
-}
-#endif
-
// CHECK-LABEL: @test_implicitarg_ptr
// CHECK: call i8 addrspace(7)* @llvm.r600.implicitarg.ptr()
void test_implicitarg_ptr(__attribute__((address_space(7))) unsigned char ** out)
OpenPOWER on IntegriCloud