Kajetan Johannes Hammerle 3 месяцев назад
Родитель
Сommit
c95d256d94
7 измененных файлов с 4 добавлено и 29 удалено
  1. 1 8
      CMakeLists.txt
  2. 0 1
      coverageFunctions
  3. 0 1
      src/BitArray.c
  4. 0 1
      src/ReadLine.c
  5. 0 1
      src/Vector.c
  6. 3 7
      tasks
  7. 0 10
      valgrind.supp

+ 1 - 8
CMakeLists.txt

@@ -60,7 +60,7 @@ else()
         set(COMPILE_OPTIONS --coverage)
         set(LINK_OPTIONS gcov)
     elseif(CMAKE_C_COMPILER_ID STREQUAL "Clang")
-        set(COMPILE_OPTIONS -fprofile-instr-generate -fcoverage-mapping -gdwarf-4)
+        set(COMPILE_OPTIONS -fprofile-instr-generate -fcoverage-mapping)
         set(LINK_OPTIONS ${COMPILE_OPTIONS})
     endif()
     set(LOG_LEVEL 4)
@@ -69,13 +69,6 @@ endif()
 
 if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
     include("cmake/gcc_warnings.cmake")
-    set(DEFINITIONS ${DEFINITIONS}
-        bool=_Bool
-        true=1
-        false=0
-        nullptr=0
-        static_assert=_Static_assert
-    )
 elseif(CMAKE_C_COMPILER_ID STREQUAL "Clang")
     include("cmake/clang_warnings.cmake")
 endif()

+ 0 - 1
coverageFunctions

@@ -1 +0,0 @@
-allowlist_fun:.*

+ 0 - 1
src/BitArray.c

@@ -2,7 +2,6 @@
 
 #include <assert.h>
 #include <inttypes.h>
-#include <stdio.h>
 #include <string.h>
 
 #include "core/ToString.h"

+ 0 - 1
src/ReadLine.c

@@ -5,7 +5,6 @@
 #include <stdatomic.h>
 #include <stdint.h>
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 #include <termios.h>
 #include <threads.h>

+ 0 - 1
src/Vector.c

@@ -1,7 +1,6 @@
 #include "core/Vector.h"
 
 #include <math.h>
-#include <stdio.h>
 
 #include "core/ToString.h"
 #include "core/Utility.h"

+ 3 - 7
tasks

@@ -102,11 +102,7 @@ elif [ "$task" = "valgrind" ]; then
         echo "Valid valgrind types are: debug, release, all"
         printHelpExit
     fi
-    valgrind="valgrind \
-        --leak-check=full \
-        --show-leak-kinds=all \
-        --suppressions=../valgrind.supp
-        "
+    valgrind="valgrind --leak-check=full --show-leak-kinds=all"
 elif [ "$task" = "performance" ]; then
     build_profile=true
     performance=true
@@ -225,8 +221,8 @@ if $coverage; then
             --exclude-lines-by-pattern ".*CoverageIgnore.*"
     else
         files=$(find build_debug -name *.profraw)
-        llvm-profdata-16 merge -sparse $files -o build_debug/default.profdata
+        llvm-profdata-17 merge -sparse $files -o build_debug/default.profdata
 	generateCoverageFunctions
-	llvm-cov-16 show ./build_debug/test -instr-profile=build_debug/default.profdata --ignore-filename-regex="test/" -line-coverage-lt=100 --name-allowlist=build_debug/coverageFunctions
+	llvm-cov-17 show ./build_debug/test -instr-profile=build_debug/default.profdata --ignore-filename-regex="test/" -line-coverage-lt=100 --name-allowlist=build_debug/coverageFunctions
     fi
 fi

+ 0 - 10
valgrind.supp

@@ -1,10 +0,0 @@
-{
-  glfwInit 1
-  Memcheck:Leak
-  match-leak-kinds: reachable
-  fun:malloc
-  ...
-  fun:__llvm_profile_initialize
-  ...
-  fun:call_init
-}