GCC: v850-elf

Nick Clifton nickc@redhat.com
Tue Mar 16 11:32:29 GMT 2021


Hi Jan-Benedict,

> With my re-started testing efforts, I've got another one for you I
> guess (`./configure --target=v850-elf && make all-gcc`):
> 
> ../.././gcc/config/v850/v850.c: In function ‘char* construct_restore_jr(rtx)’:
> ../.././gcc/config/v850/v850.c:2260:22: error: ‘%s’ directive writing up to 39 bytes into a region of size between 32 and 71 [-Werror=format-overflow=]
>   2260 |       sprintf (buff, "movhi hi(%s), r0, r6\n\tmovea lo(%s), r6, r6\n\tjmp r6",
>        |                      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>   2261 |         name, name);
>        |               ~~~~

I could not reproduce these in my local environment, but I suspect that
you are using a more recent version of gcc than me.  The fix looks obvious
however, so please could you try out the attached patch and let me know
if it resolves the problem ?

Cheers
   Nick
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v850.c.patch
Type: text/x-patch
Size: 378 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20210316/e0b9cee6/attachment.bin>


More information about the Gcc-patches mailing list