[Bug c/12425] New: Incorrect function argument promotion
rtag at cadence dot com
gcc-bugzilla@gcc.gnu.org
Fri Sep 26 21:33:00 GMT 2003
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12425
Summary: Incorrect function argument promotion
Product: gcc
Version: 3.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rtag at cadence dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: ia64-unknown-linux-gnu
GCC host triplet: ia64-unknown-linux-gnu
GCC target triplet: ia64-unknown-linux-gnu
In the absence of a prototype, passing 8 arguments of type long and
1 argument of type int in this order to a function which declares all
9 arguments to be of type long results in the value of the passed
int type argument being incorrect in the called function.
I'm not sure what the standards say about promoting an int to a long
when operating in a 64bit environment; but GCC 3.3 for sparc-sun-solaris2.8
(as well as other compilers) seem to correctly handle this case.
More information about the Gcc-bugs
mailing list