[all-commits] [llvm/llvm-project] 14a217: [IR] Add Type::getFloatingPointTy.

Bevin Hansson via All-commits all-commits at lists.llvm.org
Fri Oct 9 01:31:36 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 14a217534b791b68ea4e5b85ae98d92846bbd430
      https://github.com/llvm/llvm-project/commit/14a217534b791b68ea4e5b85ae98d92846bbd430
  Author: Bevin Hansson <bevin.hansson at ericsson.com>
  Date:   2020-10-09 (Fri, 09 Oct 2020)

  Changed paths:
    M llvm/include/llvm/IR/Type.h
    M llvm/lib/IR/Constants.cpp

  Log Message:
  -----------
  [IR] Add Type::getFloatingPointTy.

It is possible to get a fltSemantics of a particular Type,
but there is no way to produce a Type based on a
fltSemantics.

This adds the function Type::getFloatingPointTy, which
will return the appropriate floating point Type for a given
fltSemantics.

ConstantFP is modified to use this function instead of
implementing it itself. Also some minor refactors to use
Type::getFltSemantics instead of a hand-rolled version.

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


  Commit: 9c26eb8b915e5e20afa7d3e07996ea112c18ccc3
      https://github.com/llvm/llvm-project/commit/9c26eb8b915e5e20afa7d3e07996ea112c18ccc3
  Author: Bevin Hansson <bevin.hansson at ericsson.com>
  Date:   2020-10-09 (Fri, 09 Oct 2020)

  Changed paths:
    M clang/test/Frontend/fixed_point_conversions.c
    A clang/test/Frontend/fixed_point_conversions_const.c

  Log Message:
  -----------
  Refactor fixed point conversion test.

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


  Commit: dd3014f3dc7c1a42614be0488b0ab79bdcce995c
      https://github.com/llvm/llvm-project/commit/dd3014f3dc7c1a42614be0488b0ab79bdcce995c
  Author: Bevin Hansson <bevin.hansson at ericsson.com>
  Date:   2020-10-09 (Fri, 09 Oct 2020)

  Changed paths:
    M llvm/include/llvm/ADT/APFixedPoint.h
    M llvm/lib/Support/APFixedPoint.cpp
    M llvm/unittests/ADT/APFixedPointTest.cpp

  Log Message:
  -----------
  [Fixed Point] Add floating point methods to APFixedPoint.

This adds methods to APFixedPoint for converting to and from
floating point values.

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


Compare: https://github.com/llvm/llvm-project/compare/6ee47f552ba7...dd3014f3dc7c


More information about the All-commits mailing list