summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ADT/APIntTest.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* APInt: update asserts for base-36Dylan Noblesmith2011-12-161-3/+3
| | | | | | | | Hexatridecimal was added in r139695. And fix the unittest that now triggers the assert. llvm-svn: 146754
* Fix APInt::operator*= so that it computes the correct result for large ↵Eli Friedman2011-10-071-0/+9
| | | | | | integers where there is unsigned overflow. Fix APFloat::toString so that it doesn't depend on the incorrect behavior in common cases (and computes the correct result in some rare cases). Fixes PR11086. llvm-svn: 141441
* Add APInt support for converting to/from hexatridecimal stringsDouglas Gregor2011-09-141-1/+24
| | | | llvm-svn: 139695
* Add APInt(numBits, ArrayRef<uint64_t> bigVal) constructor to prevent future ↵Jeffrey Yasskin2011-07-181-0/+4
| | | | | | | | | ambiguity errors like the one corrected by r135261. Migrate all LLVM callers of the old constructor to the new one. llvm-svn: 135431
* unittests: add test for APInt::toString()Dylan Noblesmith2011-06-151-0/+46
| | | | | | Follow up to r133032. llvm-svn: 133107
* Add an argument to APInt's magic udiv calculation to specify the number of ↵Benjamin Kramer2011-03-171-0/+2
| | | | | | | | bits that are known zero in the divided number. This will come in handy soon. llvm-svn: 127828
* The signed version of our "magic number" computation for the integer ↵Cameron Zwarich2011-02-211-0/+18
| | | | | | | | | | | | | approximation of a constant had a minor typo introduced when copying it from the book, which caused it to favor negative approximations over positive approximations in many cases. Positive approximations require fewer operations beyond the multiplication. In the case of division by 3, we still generate code that is a single instruction larger than GCC's code. llvm-svn: 126097
* PR5207: Rename overloaded APInt methods set(), clear(), flip() toJay Foad2010-12-011-1/+1
| | | | | | setAllBits(), setBit(unsigned), etc. llvm-svn: 120564
* Attempt to unbreak the FreeBSD buildbot by XFAILing a unit test that seems to beJakob Stoklund Olesen2010-09-141-0/+5
| | | | | | | | miscompiled by the system gcc-4.2.1 The test remains enabled for the second-stage test. llvm-svn: 113824
* Switch from EXPECT_EQ({true,false, ...) to the more canonicalChandler Carruth2010-07-131-2/+2
| | | | | | | EXPECT_{TRUE,FALSE}(...) macros. This also prevents suprious warnings about bool-to-pointer conversion that occurs withit EXPECT_EQ. llvm-svn: 108248
* Fix death tests in -Asserts builds.Jeffrey Yasskin2010-03-171-0/+2
| | | | llvm-svn: 98701
* Pacify the compiler (signed with unsigned comparison) by makingDuncan Sands2009-10-131-6/+6
| | | | | | these constants unsigned. llvm-svn: 83962
* Add a ceilLogBase2 function to APInt.Dan Gohman2009-10-131-0/+11
| | | | llvm-svn: 83932
* Fix a few more conversion warnings on 4.0Daniel Dunbar2009-09-181-5/+5
| | | | llvm-svn: 82232
* Another try at fixing compile warnings on 4.0Daniel Dunbar2009-09-171-18/+18
| | | | llvm-svn: 82148
* Attempt to fix some 4.0.0 build warnings.Daniel Dunbar2009-09-141-23/+23
| | | | llvm-svn: 81752
* Simplify, now that gtest supports raw_ostream directly.Daniel Dunbar2009-09-061-8/+0
| | | | llvm-svn: 81102
* split raw_os_ostream out to its own header and implementation file. ThisChris Lattner2009-08-241-1/+1
| | | | | | | means that raw_ostream no longer has to #include <iosfwd>. Nothing in llvm should use raw_os_ostream.h, but llvm-gcc and some unit tests do. llvm-svn: 79886
* Unbreak unit tests.Daniel Dunbar2009-08-241-0/+7
| | | | llvm-svn: 79879
* Correct for recent assert change.Bill Wendling2009-08-211-1/+1
| | | | llvm-svn: 79601
* Fix bug with APInt::getBitsNeeded with for base 10 numbers 0-9.Erick Tryzelaar2009-08-211-0/+82
| | | | llvm-svn: 79593
* Allow '+' to appear in APInt strings, and add more unit tests.Erick Tryzelaar2009-08-211-8/+72
| | | | llvm-svn: 79592
* Wrap unit test death tests in GTEST_HAS_DEATH_TESTErick Tryzelaar2009-08-171-0/+2
| | | | llvm-svn: 79218
* Add failure tests to APInt unit test.Erick Tryzelaar2009-08-161-0/+11
| | | | llvm-svn: 79209
* Convert APint::{fromString,APInt,getBitsNeeded} to use StringRef.Daniel Dunbar2009-08-131-6/+6
| | | | | | - Patch by Erick Tryzelaar, with some edits (and a bug fix) from me. llvm-svn: 78885
* Reapply 74494, this time removing the conflicting definition of operator<<Dan Gohman2009-06-301-13/+0
| | | | | | in APIntTest.cpp. llvm-svn: 74550
* Fix PR4040: APInt's string constructor is too strictChris Lattner2009-04-251-0/+9
| | | | | | patch by Jeff Yasskin! llvm-svn: 70058
* * Fixed calls to APInt ctor to work for negative values on Darwin/x86Misha Brukman2009-04-081-6/+6
| | | | | | * Converted C-style casts to C++-style casts llvm-svn: 68613
* Converted a1.ll to unittests.Misha Brukman2009-03-241-4/+83
| | | | llvm-svn: 67652
* Renamed unittest files to have a consistent {Tt}est suffix.Misha Brukman2009-03-191-0/+100
llvm-svn: 67326
OpenPOWER on IntegriCloud