forked from OSchip/llvm-project
[Hexagon] Fix isTypeForHVX to recognize floating point types
Co-authored-by: Sumanth Gundapaneni <sgundapa@quicinc.com>
This commit is contained in:
parent
4a8cef157b
commit
cd997689f2
|
@ -228,7 +228,9 @@ bool HexagonSubtarget::isTypeForHVX(Type *VecTy, bool IncludeBool) const {
|
|||
if (!VecTy->isVectorTy() || isa<ScalableVectorType>(VecTy))
|
||||
return false;
|
||||
// Avoid types like <2 x i32*>.
|
||||
if (!cast<VectorType>(VecTy)->getElementType()->isIntegerTy())
|
||||
Type *ScalTy = VecTy->getScalarType();
|
||||
if (!ScalTy->isIntegerTy() &&
|
||||
!(ScalTy->isFloatingPointTy() && useHVXFloatingPoint()))
|
||||
return false;
|
||||
// The given type may be something like <17 x i32>, which is not MVT,
|
||||
// but can be represented as (non-simple) EVT.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
|
||||
; RUN: llc -march=hexagon < %s | FileCheck %s
|
||||
; RUN: llc -march=hexagon -hexagon-vector-combine=false < %s | FileCheck %s
|
||||
|
||||
define void @f0(<128 x i8> %a0, <128 x i8>* %a1) #0 {
|
||||
; CHECK-LABEL: f0:
|
||||
|
|
Loading…
Reference in New Issue