[PATCH] D51753: [DAGCombiner] try to convert pow(x, 1/3) to cbrt(x)

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 7 06:29:35 PDT 2018


spatel added inline comments.


================
Comment at: test/CodeGen/X86/pow.ll:2
 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
 ; RUN: llc < %s -mtriple=x86_64-- | FileCheck %s
 
----------------
lebedev.ri wrote:
> There is `_mm_pow_ps()` and `_mm_cbrt_ps()` in SSE.
> Maybe there should be an `-mattr=+sse` runline?
I didn't know about those. They're SVML library calls, right? Or is there an x86 hardware target somewhere out there?

There is support for the pow SVML call in LLVM, but I don't see cbrt anywhere. Either way, I'm not sure how that's testable here because SVML transforms happen in IR currently ( related discussion in: https://bugs.llvm.org/show_bug.cgi?id=38528 )

mattr=+sse is a requirement of x86-64, so how does making that explicit change things?


https://reviews.llvm.org/D51753





More information about the llvm-commits mailing list