llvm/include
Craig Topper 34adcf1189 [APInt] Add a utility method to change the bit width and storage size of an APInt.
Summary:
This adds a resize method to APInt that manages deleting/allocating storage for an APInt and changes its bit width. Use this to simplify code in copy assignment and divide.

The assignment code in particular was overly complicated. Treating every possible case as a separate implementation. I'm also pretty sure the clearUnusedBits code at the end was unnecessary. Since we always copying whole words from the source APInt. All unused bits should be clear in the source.

Reviewers: hans, RKSimon

Reviewed By: RKSimon

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@302863 91177308-0d34-0410-b5e6-96231b3b80d8
2017-05-12 01:46:01 +00:00
..
llvm [APInt] Add a utility method to change the bit width and storage size of an APInt. 2017-05-12 01:46:01 +00:00
llvm-c Introduce LLVMDIBuilderRef 2017-04-20 14:22:47 +00:00