This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 2/4] Implements aarch64 process record and reverse debugging support
- From: Yao Qi <qiyaoltc at gmail dot com>
- To: Edjunior Barbosa Machado <emachado at linux dot vnet dot ibm dot com>
- Cc: Yao Qi <qiyaoltc at gmail dot com>, Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org
- Date: Wed, 27 May 2015 09:21:47 +0100
- Subject: Re: [PATCH 2/4] Implements aarch64 process record and reverse debugging support
- Authentication-results: sourceware.org; auth=none
- References: <1432041752-4638-1-git-send-email-yao dot qi at linaro dot org> <1432041752-4638-3-git-send-email-yao dot qi at linaro dot org> <555E3EAE dot 2080107 at redhat dot com> <86h9qzr2g2 dot fsf at gmail dot com> <5564D0E9 dot 3000402 at linux dot vnet dot ibm dot com>
Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com> writes:
> noticed this commit (99afc8) introduced this issue when checking for uninitialized vars:
>
Sorry for breaking the build.
> gcc -g -O2 -mminimal-toc -I. -I../../gdb -I../../gdb/common -I../../gdb/config -DLOCALEDIR="\"/usr/local/share/locale\"" -DHAVE_CONFIG_H -I../../gdb/../include/opcode -I../../gdb/../opcodes/.. -I../../gdb/../readline/.. -I../../gdb/../zlib -I../bfd -I../../gdb/../bfd -I../../gdb/../include -I../libdecnumber -I../../gdb/../libdecnumber -I../../gdb/gnulib/import -Ibuild-gnulib/import -DTUI=1 -I/usr/include/python2.7 -I/usr/include/python2.7 -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wpointer-sign -Wmissing-prototypes -Wdeclaration-after-statement -Wmissing-parameter-type -Wold-style-declaration -Wold-style-definition -Wformat-nonliteral -Werror -c -o aarch64-tdep.o -MT aarch64-tdep.o -MMD -MP -MF .deps/aarch64-tdep.Tpo ../../gdb/aarch64-tdep.c
> ../../gdb/aarch64-tdep.c: In function âaarch64_process_recordâ:
> ../../gdb/aarch64-tdep.c:2823:23: error: ârecord_buf[0]â may be used uninitialized in this function [-Werror=maybe-uninitialized]
> memcpy(®S[0], &RECORD_BUF[0], sizeof(uint32_t)*LENGTH); \
> ^
> ../../gdb/aarch64-tdep.c:3529:12: note: ârecord_buf[0]â was declared here
> uint32_t record_buf[2];
> ^
>
> The simple patch below intends to fix this. Ok?
This build error reveals some logic error inside function
aarch64_record_data_proc_simd_fp on decoding instructions. I'll take a look.
What is your gcc version? I use gcc-4.9 and gcc-5, but unable to
reproduce this compilation error.
--
Yao (éå)