[PATCH 0/2] s390: Fix memory leaks in assembler and linker

Jens Remus jremus@linux.ibm.com
Wed Jan 22 13:39:30 GMT 2025


Motivated by Alan's recent work I ran the assembler and linker test
suites on s390x with ASAN enabled as follows and fixed the reported
memory leaks in s390-specific code.

$ ../configure --disable-gdb --disable-gdbserver --disable-gold \
--disable-sim --disable-readline --disable-nls --disable-werror \
CFLAGS="-g -O2 -fsanitize=address,undefined" \
CXXFLAGS="-g -O2 -fsanitize=address,undefined"
$ make -j $(nproc)
$ ASAN_OPTIONS=fast_unwind_on_malloc=false make check-gas
$ ASAN_OPTIONS=fast_unwind_on_malloc=false make check-ld

Regards,
Jens

Jens Remus (2):
  s390: s390_machinemode leak
  s390: s390_machine leak

 gas/config/tc-s390.c                       | 39 +++++++++-------------
 gas/testsuite/gas/s390/machine-parsing-1.l |  3 +-
 gas/testsuite/gas/s390/machine-parsing-1.s |  3 ++
 3 files changed, 20 insertions(+), 25 deletions(-)

-- 
2.45.2



More information about the Binutils mailing list