summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2016-11-15 02:00:59 -0800
committerKenneth Graunke <[email protected]>2016-11-19 11:39:59 -0800
commit74d8612eedb67b3e39b6ba3b7d4d85d93a3153cd (patch)
treec0e97bf459cab636900a340116385197bcb07552
parentc87b5dee119da9696d9c1897dc7c96144b9ced7a (diff)
i965: Switch to roundf in HS/DS URB code.
Matt intentionally switched the VS calculation to be float-based in commit c1da15709a0c0c2775bd9e534f67c60f7dc95ce8. Tessellation support was written before this and rebased forward, and missed the change. Now it's consistent. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Topi Pohjolainen <[email protected]>
-rw-r--r--src/mesa/drivers/dri/i965/gen7_urb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/gen7_urb.c b/src/mesa/drivers/dri/i965/gen7_urb.c
index 983078837ac..eca03366f24 100644
--- a/src/mesa/drivers/dri/i965/gen7_urb.c
+++ b/src/mesa/drivers/dri/i965/gen7_urb.c
@@ -356,7 +356,7 @@ gen7_upload_urb(struct brw_context *brw, unsigned vs_size,
if (total_wants > 0) {
unsigned hs_additional = (unsigned)
- round(hs_wants * (((double) remaining_space) / total_wants));
+ roundf(hs_wants * (((float) remaining_space) / total_wants));
hs_chunks += hs_additional;
remaining_space -= hs_additional;
total_wants -= hs_wants;
@@ -364,7 +364,7 @@ gen7_upload_urb(struct brw_context *brw, unsigned vs_size,
if (total_wants > 0) {
unsigned ds_additional = (unsigned)
- round(ds_wants * (((double) remaining_space) / total_wants));
+ roundf(ds_wants * (((float) remaining_space) / total_wants));
ds_chunks += ds_additional;
remaining_space -= ds_additional;
total_wants -= ds_wants;