[Openmp-commits] [openmp] ad3d021 - [libomptarget][nfc][amdgcn] Simplify assert_fail implementation

Jon Chesterfield via Openmp-commits openmp-commits at lists.llvm.org
Tue Mar 3 10:25:08 PST 2020


Author: Jon Chesterfield
Date: 2020-03-03T18:24:51Z
New Revision: ad3d021b9e5a8d927bc1ddbc6e2a34ba2ff31e8f

URL: https://github.com/llvm/llvm-project/commit/ad3d021b9e5a8d927bc1ddbc6e2a34ba2ff31e8f
DIFF: https://github.com/llvm/llvm-project/commit/ad3d021b9e5a8d927bc1ddbc6e2a34ba2ff31e8f.diff

LOG: [libomptarget][nfc][amdgcn] Simplify assert_fail implementation

Added: 
    

Modified: 
    openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h

Removed: 
    


################################################################################
diff  --git a/openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h b/openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h
index 827e230a5c36..b3c892323b74 100644
--- a/openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h
+++ b/openmp/libomptarget/deviceRTLs/amdgcn/src/target_impl.h
@@ -142,11 +142,9 @@ DEVICE void *__kmpc_impl_malloc(size_t x);
 DEVICE void __kmpc_impl_free(void *x);
 
 // DEVICE versions of part of libc
-EXTERN __attribute__((noreturn)) void
-__assertfail(const char *, const char *, unsigned, const char *, size_t);
-INLINE void __assert_fail(const char *__message, const char *__file,
-                          unsigned int __line, const char *__function) {
-  __assertfail(__message, __file, __line, __function, sizeof(char));
+INLINE void __assert_fail(const char *, const char *, unsigned int,
+                          const char *) {
+  __builtin_trap();
 }
 EXTERN int printf(const char *, ...);
 


        


More information about the Openmp-commits mailing list