[PATCH] D63691: [APInt] Fix getBitsNeeded for INT_MIN values

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 27 09:43:26 PDT 2019


RKSimon added inline comments.


================
Comment at: unittests/ADT/APIntTest.cpp:1269
+  EXPECT_EQ(9U, APInt::getBitsNeeded("-255", 10));
+  EXPECT_EQ(9U, APInt::getBitsNeeded("-256", 10));
 }
----------------
Please can you add a few other INT_MIN cases - regular and irregular sizes (e.g. i1, i23, i32, i64)


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D63691/new/

https://reviews.llvm.org/D63691





More information about the llvm-commits mailing list