mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-03 10:05:29 +00:00
Remove more warnings from tests
GCC12 catches various issues in tests at compile time that we want to catch at runtime. Also glibc 2.34 deprecated various mallinfo related functions. Add the relevant -Wno-foobar flags to those tests. In one case, unit_oset.c, the warning was correct and the uninitialized variable was explicitly set.
This commit is contained in:
parent
7b1a2b1edd
commit
bfd28bb9f8
@ -26,5 +26,6 @@ check_PROGRAMS = \
|
||||
AM_CFLAGS += $(AM_FLAG_M3264_PRI)
|
||||
AM_CXXFLAGS += $(AM_FLAG_M3264_PRI)
|
||||
|
||||
# We don't care about unused malloc results
|
||||
# We don't care about uninitialized or unused malloc results
|
||||
basic_CFLAGS = $(AM_CFLAGS) -Wno-uninitialized
|
||||
big_CFLAGS = $(AM_CFLAGS) -Wno-unused-result
|
||||
|
||||
@ -100,3 +100,4 @@ insig_CFLAGS = $(AM_CFLAGS) -Wno-unused-result
|
||||
long_names_CFLAGS = $(AM_CFLAGS) -Wno-unused-result
|
||||
one_CFLAGS = $(AM_CFLAGS) -Wno-unused-result
|
||||
thresholds_CFLAGS = $(AM_CFLAGS) -Wno-unused-result
|
||||
realloc_CFLAGS = $(AM_CFLAGS) -Wno-free-nonheap-object
|
||||
|
||||
@ -508,13 +508,17 @@ demangle_SOURCES = demangle.cpp
|
||||
# Suppress various gcc warnings which are correct, but for things
|
||||
# we are actually testing for at runtime.
|
||||
accounting_CFLAGS = $(AM_CFLAGS) -Wno-alloc-size-larger-than
|
||||
badfree_CFLAGS = $(AM_CFLAGS) -Wno-free-nonheap-object
|
||||
bug155125_CFLAGS = $(AM_CFLAGS) -Wno-unused-result -Wno-alloc-size-larger-than
|
||||
mallinfo_CFLAGS = $(AM_CFLAGS) -Wno-deprecated-declarations
|
||||
malloc3_CFLAGS = $(AM_CFLAGS) -Wno-alloc-size-larger-than
|
||||
sbfragment_CFLAGS = $(AM_CFLAGS) -Wno-deprecated-declarations
|
||||
strchr_CFLAGS = $(AM_CFLAGS) -Wno-uninitialized
|
||||
|
||||
big_debuginfo_symbol_SOURCES = big_debuginfo_symbol.cpp
|
||||
big_debuginfo_symbol_CXXFLAGS = $(AM_CXXFLAGS) -std=c++0x
|
||||
|
||||
bug340392_CFLAGS = $(AM_CFLAGS) -O3
|
||||
bug340392_CFLAGS = $(AM_CFLAGS) -O3 -Wno-maybe-uninitialized
|
||||
dw4_CFLAGS = $(AM_CFLAGS) -gdwarf-4 -fdebug-types-section
|
||||
|
||||
descr_belowsp_LDADD = -lpthread
|
||||
@ -535,7 +539,7 @@ execve1_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
|
||||
|
||||
execve2_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
|
||||
|
||||
fprw_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
|
||||
fprw_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@ -Wno-free-nonheap-object
|
||||
|
||||
inits_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@
|
||||
|
||||
@ -647,7 +651,7 @@ else
|
||||
varinfo5so_so_LDFLAGS = -fpic $(AM_FLAG_M3264_PRI) -shared \
|
||||
-Wl,-soname -Wl,varinfo5so.so
|
||||
endif
|
||||
varinforestrict_CFLAGS = $(AM_CFLAGS) -O0 -g
|
||||
varinforestrict_CFLAGS = $(AM_CFLAGS) -O0 -g -Wno-maybe-uninitialized
|
||||
|
||||
# Build shared object for wrap7
|
||||
wrap7_SOURCES = wrap7.c
|
||||
|
||||
@ -92,6 +92,7 @@ void example1singleset(OSet* oset, char *descr)
|
||||
UWord sorted_elts[NN]; // Used to test VG_(OSetGen_ResetIterAt)
|
||||
|
||||
// Try some operations on an empty OSet to ensure they don't screw up.
|
||||
v = 0;
|
||||
vg_assert( ! VG_(OSetGen_Contains)(oset, &v) );
|
||||
vg_assert( ! VG_(OSetGen_Lookup)(oset, &v) );
|
||||
vg_assert( ! VG_(OSetGen_Remove)(oset, &v) );
|
||||
|
||||
@ -28,3 +28,4 @@ AM_CFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
|
||||
AM_CXXFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
|
||||
AM_CCASFLAGS += @FLAG_M32@
|
||||
|
||||
scalar_supp_CFLAGS = $(AM_CFLAGS) -Wno-uninitialized
|
||||
|
||||
@ -52,6 +52,7 @@ AM_CCASFLAGS += @FLAG_M32@
|
||||
|
||||
# fpeflags must use these flags -- bug only occurred with them.
|
||||
fpeflags_CFLAGS = $(AM_CFLAGS) -march=i686
|
||||
pushfpopf_CFLAGS = $(AM_CFLAGS) -Wno-uninitialized
|
||||
pushfpopf_SOURCES = pushfpopf_c.c pushfpopf_s.S
|
||||
if VGCONF_OS_IS_DARWIN
|
||||
pushpopmem_CFLAGS = $(AM_CFLAGS) -mdynamic-no-pic
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user