cell: Specify constant as float for CEILF().
authorJonathan Adamczewski <jadamcze@utas.edu.au>
Wed, 14 Jan 2009 01:37:46 +0000 (12:37 +1100)
committerJonathan Adamczewski <jadamcze@utas.edu.au>
Wed, 14 Jan 2009 01:49:28 +0000 (12:49 +1100)
Without the f, the constant is treated as a double, resulting in
slower arithmetic and libgcc conversion calls each time CEILF()
is used.

src/gallium/drivers/cell/spu/spu_tri.c

index 322be12..0d9fcb9 100644 (file)
@@ -57,7 +57,7 @@ struct vertex_header {
 
 /* XXX fix this */
 #undef CEILF
-#define CEILF(X) ((float) (int) ((X) + 0.99999))
+#define CEILF(X) ((float) (int) ((X) + 0.99999f))
 
 
 #define QUAD_TOP_LEFT     0