Mesa (master): gallivm: replace sub/floor/ifloor combo with ifloor_fract
Roland Scheidegger
sroland at kemper.freedesktop.org
Fri Oct 8 22:37:05 UTC 2010
Module: Mesa
Branch: master
Commit: 1e17e0c4ffc0f1d1b9170c5574606172998c8917
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=1e17e0c4ffc0f1d1b9170c5574606172998c8917
Author: Roland Scheidegger <sroland at vmware.com>
Date: Fri Oct 8 18:43:49 2010 +0200
gallivm: replace sub/floor/ifloor combo with ifloor_fract
---
src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c | 6 +-----
1 files changed, 1 insertions(+), 5 deletions(-)
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
index b8cf938..90fd990 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
@@ -202,11 +202,7 @@ lp_build_coord_mirror(struct lp_build_sample_context *bld,
struct lp_build_context *int_coord_bld = &bld->int_coord_bld;
LLVMValueRef fract, flr, isOdd;
- /* fract = coord - floor(coord) */
- fract = lp_build_sub(coord_bld, coord, lp_build_floor(coord_bld, coord));
-
- /* flr = ifloor(coord); */
- flr = lp_build_ifloor(coord_bld, coord);
+ lp_build_ifloor_fract(coord_bld, coord, &flr, &fract);
/* isOdd = flr & 1 */
isOdd = LLVMBuildAnd(bld->builder, flr, int_coord_bld->one, "");
More information about the mesa-commit
mailing list