fhahn added a comment. Probably would be good to split this up in separate LLVM/Clang parts. Do we need to auto-upgrade calls to `llvm.powi`?
================ Comment at: llvm/docs/LangRef.rst:13280 +floating-point or vector of floating-point type. The type of the exponent +should typically match the size of ``int``, at least when the intrinsic maps +to one of the ``__powi*`` functions in compiler-rt. Not all targets support ---------------- Not sure about the sentence about the size of the exponent. It refers to `int` and `__powi`, both of which are not really defined in the LangRef and it is not clear to what they are referring to here. ================ Comment at: llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp:573 unsigned Offset = IsStrict ? 1 : 0; - assert(N->getOperand(1 + Offset).getValueType() == MVT::i32 && + assert((N->getOperand(1 + Offset).getValueType() == MVT::i16 || + N->getOperand(1 + Offset).getValueType() == MVT::i32) && ---------------- Why just allow i32 and i16 here? Could we restrict the supported offset types to i32 or smaller? ================ Comment at: llvm/test/Transforms/InstCombine/pow_fp_int16.ll:1 -; NOTE: Assertions have been autogenerated by utils/update_test_checks.py -; RUN: opt -mtriple unknown -instcombine -S < %s | FileCheck %s +; RUN: opt -mtriple msp430 -instcombine -S < %s | FileCheck %s ---------------- I don't think we can rely on any specific triple here. If a triple is needed it should be in a sub-directory. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99439/new/ https://reviews.llvm.org/D99439 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits