This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c++/8706: gcc cannot generate __cdel functions that can be called by Visual C if that function returns >8 byte strucutres by value
- From: cgf at gcc dot gnu dot org
- To: cgf at gcc dot gnu dot org, cheng at powertv dot com, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org
- Date: 28 Nov 2002 05:24:26 -0000
- Subject: Re: c++/8706: gcc cannot generate __cdel functions that can be called by Visual C if that function returns >8 byte strucutres by value
- Reply-to: cgf at gcc dot gnu dot org, cgf at gcc dot gnu dot org, cheng at powertv dot com, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, gcc-gnats at gcc dot gnu dot org
Synopsis: gcc cannot generate __cdel functions that can be called by Visual C if that function returns >8 byte strucutres by value
Responsible-Changed-From-To: unassigned->cgf
Responsible-Changed-By: cgf
Responsible-Changed-When: Wed Nov 27 21:24:26 2002
Responsible-Changed-Why:
investigated the problem
State-Changed-From-To: open->feedback
State-Changed-By: cgf
State-Changed-When: Wed Nov 27 21:24:26 2002
State-Changed-Why:
I don't see any obvious evidence of stack corruption in the assembly that you produced. It seems like gcc and msvc produce the same structure layout and return the address of the structure in the EAX register.
I tried compiling your test case with one function in MSVC and another in gcc and the structure was always correctly initialized and reported.
So, unless you can provide further details, I will close this PR.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8706