[PATCH] D31523: [APInt] Add a public typedef for the internal type of APInt use it instead of integerPart. Make APINT_BITS_PER_WORD and APINT_WORD_SIZE public.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 30 21:39:56 PDT 2017


craig.topper created this revision.

This patch is one step to attempt to unify the main APInt interface and the tc functions used by APFloat.

This patch adds a WordType to APInt and uses that in all the tc functions. I've added temporary typedefs to APFloat to alias it to integerPart to keep the patch size down. I'll work on removing that in a future patch.

In future patches I hope to reuse the tc functions to implement some of the main APInt functionality.

I may remove APINT_ from BITS_PER_WORD and WORD_SIZE constants so that we don't have the repetitive APInt::APINT_ externally.


https://reviews.llvm.org/D31523

Files:
  include/llvm/ADT/APFloat.h
  include/llvm/ADT/APInt.h
  lib/Support/APFloat.cpp
  lib/Support/APInt.cpp
  unittests/ADT/APIntTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D31523.93584.patch
Type: text/x-patch
Size: 32111 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170331/57de3a5b/attachment.bin>


More information about the llvm-commits mailing list