On Fri, Sep 23, 2022 at 2:27 PM Alistair Francis <alistai...@gmail.com> wrote: > > On Fri, Aug 26, 2022 at 1:26 PM Yang Liu <liuyan...@iscas.ac.cn> wrote: > > > > Tested with https://github.com/ksco/rvv-decoder-tests > > > > Expected checkpatch errors for consistency and brevity reasons: > > > > ERROR: line over 90 characters > > ERROR: trailing statements should be on next line > > ERROR: braces {} are necessary for all arms of this statement > > > > Signed-off-by: Yang Liu <liuyan...@iscas.ac.cn> > > Thanks! > > Applied to riscv-to-apply.next
This patch fails to build with this error: ../disas/riscv.c: In function 'print_insn_riscv': ../disas/riscv.c:4513:30: error: '__builtin___sprintf_chk' may write a terminating nul past the end of the destination [-Werror=format-overflow=] 4513 | sprintf(nbuf, "%d", sew); | ^ In file included from /usr/include/stdio.h:906, from /scratch/jenkins-tmp/workspace/QEMU-Multi-Config-Build/BUILD_OPTIONS/GCC/include/qemu/osdep.h:97, from ../disas/riscv.c:20: In function 'sprintf', inlined from 'format_inst' at ../disas/riscv.c:4513:13, inlined from 'disasm_inst' at ../disas/riscv.c:4640:5, inlined from 'print_insn_riscv' at ../disas/riscv.c:4690:5: /usr/include/bits/stdio2.h:30:10: note: '__builtin___sprintf_chk' output between 2 and 5 bytes into a destination of size 4 30 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 31 | __glibc_objsize (__s), __fmt, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 32 | __va_arg_pack ()); | ~~~~~~~~~~~~~~~~~ Alistair > > decode_inst_operands(&dec); > > decode_inst_decompress(&dec, isa); > > decode_inst_lift_pseudo(&dec); > > - format_inst(buf, buflen, 16, &dec); > > + format_inst(buf, buflen, 24, &dec); > > } > > > > #define INST_FMT_2 "%04" PRIx64 " " > > -- > > 2.30.1 (Apple Git-130) > > > >