[llvm-commits] Fix K&R prototype handling

Evan Cheng evan.cheng at apple.com
Fri Jan 5 10:54:11 PST 2007


This has been backed out due to buginess.

Evan
On Jan 4, 2007, at 3:25 PM, Chris Lattner wrote:

> This patch causes us to compile functions like:
>
> p1 (f2, l)
> float f2; short l;  {
>   printf("%d\n", l);
> }
>
> into:
>
> define i32 %p1(double %f2, i32 %l) {
>
> instead of:
>
> define i32 %p1(float %f2, i16 %l) {
>
> due to K&R promotion rules.  This fixes a miscompilation of  
> SingleSource/UnitTests/2007-01-04-KNR-Args.c on PowerPC at -O0.
>
> -Chris
>
>
> <patch.txt>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list