https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85718

            Bug ID: 85718
           Summary: Incorrect name mangling for va_list on mipsel
           Product: gcc
           Version: 7.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: roliver at roku dot com
  Target Milestone: ---

--------------------
#include <stdarg.h>

extern void log(char const* fmt, ...);
extern void log(char const* fmt, va_list args);

int main() {
    int i = 5;
    log("Location of i: %p", &i);
    return 0;
}
--------------------

On mipsel, 'log(char const* fmt, va_list args)' is incorrectly mangled to
_Z3logPKcPv rather than _Z3logPKcSt9__va_list which is used on other platforms.

In the above example, code is incorrectly generated to call _Z3logPKcPv on
mipsel whereas the correct code to call _Z3logPKcz is generated on other
platforms. (i.e. the generated code attempts to call the 'va_list'
implementation rather than '...').

Reply via email to