[IR][BFloat] Add BFloat IR type
authorTies Stuij <ties.stuij@arm.com>
Tue, 31 Mar 2020 22:49:38 +0000 (23:49 +0100)
committerTies Stuij <ties.stuij@arm.com>
Fri, 15 May 2020 13:43:43 +0000 (14:43 +0100)
commit8c24f33158d81d5f4b0c5d27c2f07396f0f1484b
treeb78f8dec4d437ddaad0c62f98ef087f19da271bf
parent7063a83a7cca45a9b12a7e447c90abe681f6ebaf
[IR][BFloat] Add BFloat IR type

Summary:
The BFloat IR type is introduced to provide support for, initially, the BFloat16
datatype introduced with the Armv8.6 architecture (optional from Armv8.2
onwards). It has an 8-bit exponent and a 7-bit mantissa and behaves like an IEEE
754 floating point IR type.

This is part of a patch series upstreaming Armv8.6 features. Subsequent patches
will upstream intrinsics support and C-lang support for BFloat.

Reviewers: SjoerdMeijer, rjmccall, rsmith, liutianle, RKSimon, craig.topper, jfb, LukeGeeson, sdesmalen, deadalnix, ctetreau

Subscribers: hiraditya, llvm-commits, danielkiss, arphaman, kristof.beyls, dexonsmith

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D78190
28 files changed:
clang/lib/Sema/SemaOpenMP.cpp
llvm/docs/BitCodeFormat.rst
llvm/docs/LangRef.rst
llvm/include/llvm-c/Core.h
llvm/include/llvm/ADT/APFloat.h
llvm/include/llvm/Bitcode/LLVMBitCodes.h
llvm/include/llvm/IR/Constants.h
llvm/include/llvm/IR/DataLayout.h
llvm/include/llvm/IR/IRBuilder.h
llvm/include/llvm/IR/Type.h
llvm/lib/AsmParser/LLLexer.cpp
llvm/lib/AsmParser/LLParser.cpp
llvm/lib/Bitcode/Reader/BitcodeReader.cpp
llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
llvm/lib/CodeGen/MIRParser/MILexer.cpp
llvm/lib/IR/AsmWriter.cpp
llvm/lib/IR/Constants.cpp
llvm/lib/IR/Core.cpp
llvm/lib/IR/DataLayout.cpp
llvm/lib/IR/Function.cpp
llvm/lib/IR/LLVMContextImpl.cpp
llvm/lib/IR/LLVMContextImpl.h
llvm/lib/IR/Type.cpp
llvm/lib/Support/APFloat.cpp
llvm/lib/Target/Hexagon/HexagonTargetObjectFile.cpp
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/Assembler/bfloat.ll [new file with mode: 0644]
llvm/tools/llvm-c-test/echo.cpp