bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

as aborts after buffer overflow


From: Peter Kozich (GM)
Subject: as aborts after buffer overflow
Date: Thu, 26 Sep 2024 16:18:52 +0200
User-agent: Evolution 3.52.4 (3.52.4-1.fc40)

Dear,

compiling the attached example fails with this error message:

*** buffer overflow detected ***: terminated
/tmp/ccyb3JRr.s: Assembler messages:
/tmp/ccyb3JRr.s: Internal error (Aborted).
Please report this bug.


Environment:

$ uname -a
Linux gygv 6.10.10-200.fc40.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Sep 12
18:26:09 UTC 2024 x86_64 GNU/Linux

$ gcc --version
gcc (GCC) 14.2.1 20240912 (Red Hat 14.2.1-3)
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is
NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE.

$ as --version
GNU assembler version 2.41-37.fc40
Copyright (C) 2023 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms
of
the GNU General Public License version 3 or later.
This program has absolutely no warranty.
This assembler was configured for a target of `x86_64-redhat-linux'.



The command line is this:

gcc -c -O1 -ggdb -masm=intel -Wa,-acdhlgn=gfp_library.lst -Wa,--
listing-lhs-width=4,--listing-rhs-width=132 -o gfp_library.o
gfp_library.c


There are a number of ways to get it compiled: -O0 instead of -O1,  or
omitting  ,--listing-rhs-width=132,  or omittig -ggdb,  or eliminating
the get_realloc() function and replacing its call with its return
expression in the caller.

But the problem is that such solutions don't always work: the original
gfp_library.c is more complex and the simple solution of using -O0
didn't help.

br
PK


Attachment: gfp_library.c
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]