Skip to content
  1. Mar 04, 2014
    • Chandler Carruth's avatar
      [Modules] Move the ConstantRange class into the IR library. This is · 8cd041ef
      Chandler Carruth authored
      a bit surprising, as the class is almost entirely abstracted away from
      any particular IR, however it encodes the comparsion predicates which
      mutate ranges as ICmp predicate codes. This is reasonable as they're
      used for both instructions and constants. Thus, it belongs in the IR
      library with instructions and constants.
      
      llvm-svn: 202838
      8cd041ef
    • Chandler Carruth's avatar
      [Modules] Move ValueHandle into the IR library where Value itself lives. · 4220e9c1
      Chandler Carruth authored
      Move the test for this class into the IR unittests as well.
      
      This uncovers that ValueMap too is in the IR library. Ironically, the
      unittest for ValueMap is useless in the Support library (honestly, so
      was the ValueHandle test) and so it already lives in the IR unittests.
      Mmmm, tasty layering.
      
      llvm-svn: 202821
      4220e9c1
  2. Mar 02, 2014
  3. Mar 01, 2014
  4. Feb 26, 2014
  5. Feb 24, 2014
  6. Feb 23, 2014
    • Rafael Espindola's avatar
      Simplify remove, create_directory and create_directories. · 5c20ac01
      Rafael Espindola authored
      Before this patch they would take an boolean argument to say if the path
      already existed. This was redundant with the returned error_code which is able
      to represent that. This allowed for callers to incorrectly check only the
      existed flag instead of first checking the error code.
      
      Instead, pass in a boolean flag to say if the previous (non-)existence should be
      an error or not.
      
      Callers of the of the old simple versions are not affected. They still ignore
      the previous (non-)existence as they did before.
      
      llvm-svn: 201979
      5c20ac01
  7. Feb 22, 2014
    • Logan Chien's avatar
      Move get[S|U]LEB128Size() to LEB128.h. · 5b776b72
      Logan Chien authored
      This commit moves getSLEB128Size() and getULEB128Size() from
      MCAsmInfo to LEB128.h and removes some copy-and-paste code.
      
      Besides, this commit also adds some unit tests for the LEB128
      functions.
      
      llvm-svn: 201937
      5b776b72
  8. Feb 11, 2014
  9. Feb 05, 2014
  10. Feb 04, 2014
    • Chandler Carruth's avatar
      Silence a warning: · f6ae4922
      Chandler Carruth authored
      In file included from ../unittests/Support/ProcessTest.cpp:11:
      ../utils/unittest/googletest/include/gtest/gtest.h:1448:28: warning: comparison of integers of different signs: 'const unsigned int' and 'const int' [-Wsign-compare]
      GTEST_IMPL_CMP_HELPER_(NE, !=);
      ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
      ../utils/unittest/googletest/include/gtest/gtest.h:1433:12: note: expanded from macro 'GTEST_IMPL_CMP_HELPER_'
        if (val1 op val2) {\
                 ^
      ../unittests/Support/ProcessTest.cpp:46:3: note: in instantiation of function template specialization 'testing::internal::CmpHelperNE<unsigned int, int>' requested here
        EXPECT_NE((r1 | r2), 0);
        ^
      
      llvm-svn: 200801
      f6ae4922
    • Aaron Ballman's avatar
      Implemented support for Process::GetRandomNumber on Windows. · 78440734
      Aaron Ballman authored
      Patch thanks to Stephan Tolksdorf!
      
      llvm-svn: 200767
      78440734
  11. Feb 01, 2014
  12. Jan 29, 2014
  13. Jan 28, 2014
  14. Jan 24, 2014
    • Alp Toker's avatar
      Fix known typos · cb402911
      Alp Toker authored
      Sweep the codebase for common typos. Includes some changes to visible function
      names that were misspelt.
      
      llvm-svn: 200018
      cb402911
  15. Jan 17, 2014
  16. Jan 10, 2014
  17. Jan 09, 2014
    • Rafael Espindola's avatar
      Add a unit test for the copy constructor. · cd56deb6
      Rafael Espindola authored
      I would not normally add tests like these, but the copy constructor is not
      used at all in our codebase with c++11, so having this tests might prevent
      breaking the c++03 build again.
      
      llvm-svn: 198886
      cd56deb6
  18. Jan 08, 2014
  19. Jan 07, 2014
  20. Jan 02, 2014
  21. Dec 27, 2013
    • Chandler Carruth's avatar
      Introduce a simple line-by-line iterator type into the Support library. · f8c5281c
      Chandler Carruth authored
      This is an iterator which you can build around a MemoryBuffer. It will
      iterate through the non-empty, non-comment lines of the buffer as
      a forward iterator. It should be small and reasonably fast (although it
      could be made much faster if anyone cares, I don't really...).
      
      This will be used to more simply support the text-based sample
      profile file format, and is largely based on the original patch by
      Diego. I've re-worked the style of it and separated it from the work of
      producing a MemoryBuffer from a file which both simplifies the interface
      and makes it easier to test.
      
      The style of the API follows the C++ standard naming conventions to fit
      in better with iterators in general, much like the Path and FileSystem
      interfaces follow standard-based naming conventions.
      
      llvm-svn: 198068
      f8c5281c
  22. Dec 25, 2013
  23. Dec 19, 2013
    • Hans Wennborg's avatar
      Make sys::ThreadLocal<> zero-initialized on non-thread builds (PR18205) · fabf8bfd
      Hans Wennborg authored
      According to the docs, ThreadLocal<>::get() should return NULL
      if no object has been set. This patch makes that the case also for non-thread
      builds and adds a very basic unit test to check it.
      
      (This was causing PR18205 because PrettyStackTraceHead didn't get zero-
      initialized and we'd crash trying to read past the end of that list. We didn't
      notice this so much on Linux since we'd crash after printing all the entries,
      but on Mac we print into a SmallString, and would crash before printing that.)
      
      llvm-svn: 197718
      fabf8bfd
  24. Dec 14, 2013
  25. Dec 12, 2013
  26. Nov 22, 2013
  27. Nov 21, 2013
  28. Nov 19, 2013
  29. Nov 18, 2013
  30. Nov 17, 2013
    • Michael Gottesman's avatar
      [block-freq] Add BlockFrequency::scale that returns a remainder from the... · 4d078a3d
      Michael Gottesman authored
      [block-freq] Add BlockFrequency::scale that returns a remainder from the division and make the private scale in BlockFrequency more performant.
      
      This change is the first in a series of changes improving LLVM's Block
      Frequency propogation implementation to not lose probability mass in
      branchy code when propogating block frequency information from a basic
      block to its successors. This patch is a simple infrastructure
      improvement that does not actually modify the block frequency
      algorithm. The specific changes are:
      
      1. Changes the division algorithm used when scaling block frequencies by
      branch probabilities to a short division algorithm. This gives us the
      remainder for free as well as provides a nice speed boost. When I
      benched the old routine and the new routine on a Sandy Bridge iMac with
      disabled turbo mode performing 8192 iterations on an array of length
      32768, I saw ~600% increase in speed in mean/median performance.
      
      2. Exposes a scale method that returns a remainder. This is important so
      we can ensure that when we scale a block frequency by some branch
      probability BP = N/D, the remainder from the division by D can be
      retrieved and propagated to other children to ensure no probability mass
      is lost (more to come on this).
      
      llvm-svn: 194950
      4d078a3d
  31. Nov 15, 2013
  32. Nov 14, 2013
Loading