OSDN Git Service

[mips][msa] Implement f16 support
authorSimon Dardis <simon.dardis@imgtec.com>
Fri, 18 Nov 2016 16:17:44 +0000 (16:17 +0000)
committerSimon Dardis <simon.dardis@imgtec.com>
Fri, 18 Nov 2016 16:17:44 +0000 (16:17 +0000)
commita60ff0d03cfd964ae7726a653269187b0da07fe2
treedc4857ca03fc52cfa7318ffe727f87256db4cf49
parent0f37c5c43a1b76a4d40ffdd9a8a45812e21a6a47
[mips][msa] Implement f16 support

The MIPS MSA ASE provides instructions to convert to and from half precision
floating point. This patch teaches the MIPS backend to treat f16 as a legal
type and how to promote such values to f32 for the usual set of operations.

As a result of this, the fexup[lr].w intrinsics no longer crash LLVM during
type legalization.

Reviewers: zoran.jovanvoic, vkalintiris

Differential Revision: https://reviews.llvm.org/D26398

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287349 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/Mips/MipsMSAInstrInfo.td
lib/Target/Mips/MipsRegisterInfo.td
lib/Target/Mips/MipsSEISelLowering.cpp
lib/Target/Mips/MipsSEISelLowering.h