This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

c++/1482: va_start generates call to memcpy



>Number:         1482
>Category:       c++
>Synopsis:       va_start generates call to memcpy
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Dec 20 14:16:00 PST 2000
>Closed-Date:
>Last-Modified:
>Originator:     E. Andrew Johnson
>Release:        g++-2.95.2
>Organization:
>Environment:
target=powerpc with Altivec 2.95.2 patches
>Description:
The expansion of va_start includes a call to _builtin_memcpy.  When compiling with the gcc-2.95.2 C compiler, this generates the inline expansion of the code.  When compiling with the gcc-2.95.2 C++ compiler, it generates an external call to memcpy.  The problem is that the type.align for "va_list ap" is set to 1, whereas it is
set to 8 (1 byte) in C.  Why does it behave differently
with the C++ compiler?
>How-To-Repeat:
gcc -O2 -c tstdarg.ippc
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]