From cc6d29d72cd53acd60cc1f32c6dd2d74863e2595 Mon Sep 17 00:00:00 2001 From: Jonas Hahnfeld Date: Wed, 14 Feb 2018 15:15:24 +0000 Subject: [PATCH] [OMPT][test] Correct warning about added wrapper functions This affects all outlined functions, not just tasks! Only show warning when using Clang 5.0 or later. Differential Revision: https://reviews.llvm.org/D43190 llvm-svn: 325131 --- openmp/runtime/test/ompt/callback.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/openmp/runtime/test/ompt/callback.h b/openmp/runtime/test/ompt/callback.h index 3befe7c5d77b..8bb945440727 100755 --- a/openmp/runtime/test/ompt/callback.h +++ b/openmp/runtime/test/ompt/callback.h @@ -74,8 +74,10 @@ do {\ #define print_frame_from_outlined_fn(level) print_frame(level) #endif - #warning "Clang 5.0 and later add an additional wrapper function for tasks when compiling with debug information." - #warning "Please define -DDEBUG iff you manually pass in -g!" + #if defined(__clang__) && __clang_major__ >= 5 + #warning "Clang 5.0 and later add an additional wrapper for outlined functions when compiling with debug information." + #warning "Please define -DDEBUG iff you manually pass in -g to make the tests succeed!" + #endif #endif // This macro helps to define a label at the current position that can be used