radeonsi: make use of ac_build_fdiv()
And move the comment to amd/common. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
This commit is contained in:
@@ -439,6 +439,7 @@ ac_build_fdiv(struct ac_llvm_context *ctx,
|
||||
{
|
||||
LLVMValueRef ret = LLVMBuildFDiv(ctx->builder, num, den, "");
|
||||
|
||||
/* Use v_rcp_f32 instead of precise division. */
|
||||
if (!LLVMIsConstant(ret))
|
||||
LLVMSetMetadata(ret, ctx->fpmath_md_kind, ctx->fpmath_md_2p5_ulp);
|
||||
return ret;
|
||||
|
Reference in New Issue
Block a user