Commit Graph

536 Commits

Author SHA1 Message Date
John McCall e83797c3aa The 'expected' argument to EXPECT_EQ is actually the first one;
flip these tests around.

llvm-svn: 138708
2011-08-27 19:23:22 +00:00
Andrew Trick 4f3cb540a6 Excluding ARM JIT tests until someone can fix this compilation path.
llvm-svn: 138676
2011-08-26 23:39:30 +00:00
Evan Cheng 2bb4035707 Move TargetRegistry and TargetSelect from Target to Support where they belong.
These are strictly utilities for registering targets and components.

llvm-svn: 138450
2011-08-24 18:08:43 +00:00
Duncan Sands be64bbf979 Avoid undefined behaviour if somehow NUM_GRAPHS equals 2^32 (or
whatever the size of unsigned is), though this can't actually
occur for any integer value of NUM_NODES.

llvm-svn: 136460
2011-07-29 07:50:02 +00:00
Jakub Staszak 9f56d02e6a Remove extra semicolon.
llvm-svn: 136432
2011-07-29 00:05:35 +00:00
Duncan Sands 251daee2a7 Use unsigned rather than uint16_t in case anyone feels like testing
more graphs, like all graphs with 5 nodes or less.  With a 32 bit
unsigned type, the maximum is graphs with 6 nodes or less, but that
would take a while to test - 5 nodes or less already requires a few
seconds.

llvm-svn: 136354
2011-07-28 14:37:53 +00:00
Duncan Sands 6d0f0ffe83 Check an additional property specific to the way LLVM
iterates over SCC's.

llvm-svn: 136353
2011-07-28 14:33:01 +00:00
Duncan Sands dea551c59a Add a unittest for the simply connected components (SCC) iterator class.
This computes every graph with 4 or fewer nodes, and checks that the SCC
class indeed returns exactly the simply connected components reachable
from the initial node.

llvm-svn: 136351
2011-07-28 14:17:11 +00:00
Jakub Staszak 8a3d4c43b1 Add test cases for BlockFrequency.
llvm-svn: 136244
2011-07-27 18:57:40 +00:00
Jay Foad 4b27333440 Remove some code that is no longer needed now that googletest knows how
to print STL containers.

llvm-svn: 136213
2011-07-27 09:26:13 +00:00
Jeffrey Yasskin 6381c0100b Explicitly cast narrowing conversions inside {}s that will become errors in
C++0x.

llvm-svn: 136211
2011-07-27 06:22:51 +00:00
Jay Foad d1b7849d49 Convert GetElementPtrInst to use ArrayRef.
llvm-svn: 135904
2011-07-25 09:48:08 +00:00
Chris Lattner 9650f0678c Add Twine support for characters, and switch twine to use a union internally
to eliminate some casting.

llvm-svn: 135888
2011-07-24 20:44:30 +00:00
Jeffrey Yasskin 7a16288157 Add APInt(numBits, ArrayRef<uint64_t> bigVal) constructor to prevent future ambiguity
errors like the one corrected by r135261.  Migrate all LLVM callers of the old
constructor to the new one.

llvm-svn: 135431
2011-07-18 21:45:40 +00:00
Chris Lattner 229907cd11 land David Blaikie's patch to de-constify Type, with a few tweaks.
llvm-svn: 135375
2011-07-18 04:54:35 +00:00
Jeffrey Yasskin 03b81a2eb4 Add an APFloat::convertToInt(APSInt) function that automatically manages the
memory for the result.

llvm-svn: 135259
2011-07-15 07:04:56 +00:00
Chris Lattner 7c37b1cf51 The key of a StringMap can contain nul's in it, so having first() return
const char* doesn't make sense.  Have it return StringRef instead.

llvm-svn: 135167
2011-07-14 18:31:43 +00:00
Jay Foad b804a2b751 Second attempt at de-constifying LLVM Types in FunctionType::get(),
StructType::get() and TargetData::getIntPtrType().

llvm-svn: 134982
2011-07-12 14:06:48 +00:00
Bill Wendling a78cd228c2 Revert r134893 and r134888 (and related patches in other trees). It was causing
an assert on Darwin llvm-gcc builds.

Assertion failed: (castIsValid(op, S, Ty) && "Invalid cast!"), function Create, file /Users/buildslave/zorg/buildbot/smooshlab/slave-0.8/build.llvm-gcc-i386-darwin9-RA/llvm.src/lib/VMCore/Instructions.cpp, li\
ne 2067.
etc.

http://smooshlab.apple.com:8013/builders/llvm-gcc-i386-darwin9-RA/builds/2354

--- Reverse-merging r134893 into '.':
U    include/llvm/Target/TargetData.h
U    include/llvm/DerivedTypes.h
U    tools/bugpoint/ExtractFunction.cpp
U    unittests/Support/TypeBuilderTest.cpp
U    lib/Target/ARM/ARMGlobalMerge.cpp
U    lib/Target/TargetData.cpp
U    lib/VMCore/Constants.cpp
U    lib/VMCore/Type.cpp
U    lib/VMCore/Core.cpp
U    lib/Transforms/Utils/CodeExtractor.cpp
U    lib/Transforms/Instrumentation/ProfilingUtils.cpp
U    lib/Transforms/IPO/DeadArgumentElimination.cpp
U    lib/CodeGen/SjLjEHPrepare.cpp
--- Reverse-merging r134888 into '.':
G    include/llvm/DerivedTypes.h
U    include/llvm/Support/TypeBuilder.h
U    include/llvm/Intrinsics.h
U    unittests/Analysis/ScalarEvolutionTest.cpp
U    unittests/ExecutionEngine/JIT/JITTest.cpp
U    unittests/ExecutionEngine/JIT/JITMemoryManagerTest.cpp
U    unittests/VMCore/PassManagerTest.cpp
G    unittests/Support/TypeBuilderTest.cpp
U    lib/Target/MBlaze/MBlazeIntrinsicInfo.cpp
U    lib/Target/Blackfin/BlackfinIntrinsicInfo.cpp
U    lib/VMCore/IRBuilder.cpp
G    lib/VMCore/Type.cpp
U    lib/VMCore/Function.cpp
G    lib/VMCore/Core.cpp
U    lib/VMCore/Module.cpp
U    lib/AsmParser/LLParser.cpp
U    lib/Transforms/Utils/CloneFunction.cpp
G    lib/Transforms/Utils/CodeExtractor.cpp
U    lib/Transforms/Utils/InlineFunction.cpp
U    lib/Transforms/Instrumentation/GCOVProfiling.cpp
U    lib/Transforms/Scalar/ObjCARC.cpp
U    lib/Transforms/Scalar/SimplifyLibCalls.cpp
U    lib/Transforms/Scalar/MemCpyOptimizer.cpp
G    lib/Transforms/IPO/DeadArgumentElimination.cpp
U    lib/Transforms/IPO/ArgumentPromotion.cpp
U    lib/Transforms/InstCombine/InstCombineCompares.cpp
U    lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
U    lib/Transforms/InstCombine/InstCombineCalls.cpp
U    lib/CodeGen/DwarfEHPrepare.cpp
U    lib/CodeGen/IntrinsicLowering.cpp
U    lib/Bitcode/Reader/BitcodeReader.cpp

llvm-svn: 134949
2011-07-12 01:15:52 +00:00
Jay Foad 7c57be3e2b De-constify Types in StructType::get() and TargetData::getIntPtrType().
llvm-svn: 134893
2011-07-11 09:56:20 +00:00
Jay Foad 56cc1530ee De-constify Types in FunctionType::get().
llvm-svn: 134888
2011-07-11 07:56:41 +00:00
Chris Lattner b1ed91f397 Land the long talked about "type system rewrite" patch. This
patch brings numerous advantages to LLVM.  One way to look at it
is through diffstat:
 109 files changed, 3005 insertions(+), 5906 deletions(-)

Removing almost 3K lines of code is a good thing.  Other advantages
include:

1. Value::getType() is a simple load that can be CSE'd, not a mutating
   union-find operation.
2. Types a uniqued and never move once created, defining away PATypeHolder.
3. Structs can be "named" now, and their name is part of the identity that
   uniques them.  This means that the compiler doesn't merge them structurally
   which makes the IR much less confusing.
4. Now that there is no way to get a cycle in a type graph without a named
   struct type, "upreferences" go away.
5. Type refinement is completely gone, which should make LTO much MUCH faster
   in some common cases with C++ code.
6. Types are now generally immutable, so we can use "Type *" instead 
   "const Type *" everywhere.

Downsides of this patch are that it removes some functions from the C API,
so people using those will have to upgrade to (not yet added) new API.  
"LLVM 3.0" is the right time to do this.

There are still some cleanups pending after this, this patch is large enough
as-is.

llvm-svn: 134829
2011-07-09 17:41:24 +00:00
Owen Anderson 145a260f75 Fix a subtle issue in SmallVector. The following code did not work as expected:
vec.insert(vec.begin(), vec[3]);
The issue was that vec[3] returns a reference into the vector, which is invalidated when insert() memmove's the elements down to make space.  The method needs to specifically detect and handle this case to correctly match std::vector's semantics.

Thanks to Howard Hinnant for clarifying the correct behavior, and explaining how std::vector solves this problem.

llvm-svn: 134554
2011-07-06 22:36:59 +00:00
Nick Lewycky 5dc6b794b1 Fix the implementation of ConstantRange::sub(ConstantRange). Patch by Xi Wang!
llvm-svn: 133648
2011-06-22 21:13:46 +00:00
Chris Lattner cc19efaa97 Revamp the "ConstantStruct::get" methods. Previously, these were scattered
all over the place in different styles and variants.  Standardize on two
preferred entrypoints: one that takes a StructType and ArrayRef, and one that
takes StructType and varargs.

In cases where there isn't a struct type convenient, we now add a
ConstantStruct::getAnon method (whose name will make more sense after a few
more patches land).  

It would be "really really nice" if the ConstantStruct::get and 
ConstantVector::get methods didn't make temporary std::vectors.

llvm-svn: 133412
2011-06-20 04:01:31 +00:00
Chris Lattner f3f545ea8a fix the varargs version of StructType::get to not require an LLVMContext, making usage
much cleaner.

llvm-svn: 133364
2011-06-18 22:48:56 +00:00
Chris Lattner 3e9f21f739 add some #includes that will soon be needed.
llvm-svn: 133195
2011-06-16 21:36:36 +00:00
Dylan Noblesmith c8c184d2f8 unittests: add test for APInt::toString()
Follow up to r133032.

llvm-svn: 133107
2011-06-15 23:36:34 +00:00
Argyrios Kyrtzidis 5d525568e0 Try fixing http://google1.osuosl.org:8011/builders/clang-i686-freebsd/builds/3548
llvm-svn: 133081
2011-06-15 20:39:05 +00:00
Argyrios Kyrtzidis 59d8c60719 Add unit tests for ADT/PackedVector
llvm-svn: 133075
2011-06-15 19:19:09 +00:00
Nick Lewycky babca9aee9 Add CreateLifetimeStart and CreateLifetimeEnd to the IRBuilder, with plans to
use these soon.

llvm-svn: 131812
2011-05-21 23:14:36 +00:00
Duncan Sands a8514535a4 Teach getCastOpcode about element-by-element vector casts. For example, "trunc"
can be used to turn a <4 x i64> into a <4 x i32> but getCastOpcode would assert
if you passed these types to it.  Note that this strictly extends the previous
functionality: if getCastOpcode previously accepted two vector types (i.e. didn't
assert) then it still will and returns the same opcode (BitCast).  That's because
before it would only accept vectors with the same bitwidth, and the new code only
touches vectors with the same length.  However if two vectors have both the same
bitwidth and the same length then their element types have the same bitwidth, so
the new logic will return BitCast as before.

llvm-svn: 131530
2011-05-18 07:13:41 +00:00
Oscar Fuentes ab84a7bf73 Handle gcc-compatible compilers (such as clang) the same way we handle
gcc.

Fixes PR9886.

llvm-svn: 131181
2011-05-11 13:53:08 +00:00
Lenny Maiorani 367342e209 Remove bounded StringRef::compare() since nothing but Clang SA was using it and it is just as easy to use StringRef::substr() preceding StringRef::compare() to achieve the same thing.
llvm-svn: 130430
2011-04-28 20:20:12 +00:00
Jay Foad 5514afe6b2 PR9214: Convert Metadata API to use ArrayRef.
llvm-svn: 129932
2011-04-21 19:59:31 +00:00
Lenny Maiorani fad9d95722 Implements StringRef::compare with bounds. It is behaves similarly to strncmp(). Unit tests also included.
llvm-svn: 129582
2011-04-15 17:56:50 +00:00
Jay Foad 7c14a558fe Don't include Operator.h from InstrTypes.h.
llvm-svn: 129271
2011-04-11 09:35:34 +00:00
Duncan Sands 2d3cdd686b While testing dragonegg I noticed that isCastable and getCastOpcode
had gotten out of sync: isCastable didn't think it was possible to
cast the x86_mmx type to anything, while it did think it possible
to cast an i64 to x86_mmx.

llvm-svn: 128705
2011-04-01 03:34:54 +00:00
Duncan Sands 6ae98633dd Strip trailing whitespace.
llvm-svn: 128622
2011-03-31 09:58:51 +00:00
Benjamin Kramer af0ed953c5 Avoid turning a floating point division with a constant power of two into a denormal multiplication.
Some platforms may treat denormals as zero, on other platforms multiplication
with a subnormal is slower than dividing by a normal.

llvm-svn: 128555
2011-03-30 17:02:54 +00:00
Benjamin Kramer 03fd672609 Add APFloat::getExactInverse.
The idea is, that if an ieee 754 float is divided by a power of two, we can
turn the division into a cheaper multiplication. This function sees if we can
get an exact multiplicative inverse for a divisor and returns it if possible.

This is the hard part of PR9587.

I tested many inputs against llvm-gcc's frotend implementation of this
optimization and didn't find any difference. However, floating point is the
land of weird edge cases, so any review would be appreciated.

llvm-svn: 128545
2011-03-30 15:42:27 +00:00
Jay Foad 52131344a2 Remove PHINode::reserveOperandSpace(). Instead, add a parameter to
PHINode::Create() giving the (known or expected) number of operands.

llvm-svn: 128537
2011-03-30 11:28:46 +00:00
Jay Foad e0938d8a87 (Almost) always call reserveOperandSpace() on newly created PHINodes.
llvm-svn: 128535
2011-03-30 11:19:20 +00:00
Benjamin Kramer 09a51bab5d Add an argument to APInt's magic udiv calculation to specify the number of bits that are known zero in the divided number.
This will come in handy soon.

llvm-svn: 127828
2011-03-17 20:39:06 +00:00
Oscar Fuentes 98a3c80a3e Fixes warnings emitted by Visual Studio 2010 compiler.
Patch by Erik Olofsson!

llvm-svn: 126796
2011-03-01 23:11:57 +00:00
Duncan Sands 6dcd49bc2b Simplify RecursivelyDeleteDeadPHINode. The only functionality change
should be that if the phi is used by a side-effect free instruction with
no uses then the phi and the instruction now get zapped (checked by the
unittest).

llvm-svn: 126124
2011-02-21 16:27:36 +00:00
Cameron Zwarich 8731d0cc83 The signed version of our "magic number" computation for the integer 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
2011-02-21 00:22:02 +00:00
Oscar Fuentes 3145e923c1 Put targets on folders, if the IDE supports the feature.
Requires CMake 2.8.3 or newer.

llvm-svn: 126092
2011-02-20 22:06:10 +00:00
Nick Lewycky 183c24c51b Make RecursivelyDeleteDeadPHINode delete a phi node that has no users and add a
test for that. With this change, test/CodeGen/X86/codegen-dce.ll no longer finds
any instructions to DCE, so delete the test.

Also renamed J and JP to I and IP in RecursivelyDeleteDeadPHINode.

llvm-svn: 126088
2011-02-20 18:05:56 +00:00
Nick Lewycky c8a1569950 Teach RecursivelyDeleteDeadPHINodes to handle multiple self-references. Patch
by Andrew Clinton!

llvm-svn: 126077
2011-02-20 08:38:20 +00:00
Zhanyong Wan 606bb1a2dc Adds llvm::sys::path::is_separator() to test whether a char is a path separator
on the host OS.  Reviewed by dgregor.

llvm-svn: 125406
2011-02-11 21:24:40 +00:00
Daniel Dunbar 38992cc9df build: Add MAKEFILE_UNITTEST_NO_INCLUDE_COMMON build variable, to be leveraged
by Clang.

llvm-svn: 124871
2011-02-04 17:12:18 +00:00
Duncan Sands 981ca313d7 Part of this test is invariant inside the inner loop - move it outside
the loop.

llvm-svn: 124784
2011-02-03 08:14:04 +00:00
Duncan Sands fdfdbd091d Remove NoVendor and NoOS, added in commit 123990, from Triple. While it
may be useful to understand "none", this is not the place for it.  Tweak
the fix to Normalize while there: the fix added in 123990 works correctly,
but I like this way better.  Finally, now that Triple understands some
non-trivial environment values, teach the unittests about them.

llvm-svn: 124720
2011-02-02 10:08:38 +00:00
Chris Lattner 2114b762de Don't infinitely recurse! Patch by Marius Wachtler!
llvm-svn: 124366
2011-01-27 07:35:27 +00:00
Renato Golin 83758d5cd7 Clang was not parsing target triples involving EABI and was generating wrong IR (wrong PCS) and passing the wrong information down llc via the target-triple printed in IR. I've fixed this by adding the parsing of EABI into LLVM's Triple class and using it to choose the correct PCS in Clang's Tools. A Clang patch is on its way to use this infrastructure.
llvm-svn: 123990
2011-01-21 18:25:47 +00:00
Michael J. Spencer b587180fa7 Unittests/Support/Path: Tweak test.
llvm-svn: 123546
2011-01-15 18:52:49 +00:00
Rafael Espindola 489e505adf Allow unnamed_addr on declarations.
llvm-svn: 123529
2011-01-15 08:15:00 +00:00
Oscar Fuentes b7c43b8c59 Disable RTTI when building unit tests. This avoids errors at link time.
llvm-svn: 123377
2011-01-13 15:31:45 +00:00
Rafael Espindola 026d152e58 Reject uses of unnamed_addr in declarations.
llvm-svn: 123358
2011-01-13 01:30:30 +00:00
Rafael Espindola 45e6c195d7 First step in fixing PR8927:
Add a unnamed_addr bit to global variables and functions. This will be used
to indicate that the address is not significant and therefore the constant
or function can be merged with others.

If an optimization pass can show that an address is not used, it can set this.

Examples of things that can have this set by the FE are globals created to
hold string literals and C++ constructors.

Adding unnamed_addr to a non-const global should have no effect unless
an optimization can transform that global into a constant.

Aliases are not allowed to have unnamed_addr since I couldn't figure
out any use for it.

llvm-svn: 123063
2011-01-08 16:42:36 +00:00
Jay Foad 814f1bb8e3 Remove the "ugly" method BranchInst::setUnconditionalDest().
llvm-svn: 123026
2011-01-07 20:26:51 +00:00
Michael J. Spencer 1d3c4a7b94 UnitTests/Path: Add magical tests. This will also test identify_magic.
llvm-svn: 122948
2011-01-06 05:58:02 +00:00
Michael J. Spencer 1f06360002 UnitTests/Path: More ASSERT_NO_ERROR cleanup.
llvm-svn: 122947
2011-01-06 05:57:54 +00:00
Michael J. Spencer 42368cc15f UnitTests/Path: Fix typo, add error number, and enable the directory cleanup code.
llvm-svn: 122885
2011-01-05 16:39:46 +00:00
Michael J. Spencer 346a13381a UnitTests/PathV2: Setup a test fixture to make tracking created file system
entities easier.

llvm-svn: 122880
2011-01-05 16:39:05 +00:00
Michael J. Spencer 52714863db Support/PathV2: Implement directory iteration on POSIX.
llvm-svn: 122879
2011-01-05 16:38:57 +00:00
Michael J. Spencer 3b264ba91a UnitTests/Path: Produce useful diagnostics on error.
llvm-svn: 122812
2011-01-04 17:00:18 +00:00
Chris Lattner 1be1fe033c fix PR8867: a crash handling fp128. Thanks to Nick for the testcase.
llvm-svn: 122613
2010-12-29 01:33:36 +00:00
Jeffrey Yasskin 9b43f33620 Change all self assignments X=X to (void)X, so that we can turn on a
new gcc warning that complains on self-assignments and
self-initializations.

llvm-svn: 122458
2010-12-23 00:58:24 +00:00
Jakob Stoklund Olesen baee655c5e Add ADT/IntEqClasses.h as a light-weight implementation of EquivalenceClasses.h.
This implementation already exists as ConnectedVNInfoEqClasses in
LiveInterval.cpp, and it seems to be generally useful to have a light-weight way
of forming equivalence classes of small integers.

IntEqClasses doesn't allow enumeration of the elements in a class.

llvm-svn: 122293
2010-12-21 00:04:46 +00:00
Jakob Stoklund Olesen 00b29fbdec Add more checks to IntervalMapOverlaps::advance() to ensure that advanceTo sees
monotonic keys.

llvm-svn: 122093
2010-12-17 22:07:54 +00:00
Jakob Stoklund Olesen 54912ed921 It is allowed to call IntervalMap::const_iterator::advanceTo() with a key that
moves the iterator to end(), and it is valid to call it on end().

That means it is valid to call advanceTo() with any monotonic key sequence.

llvm-svn: 122092
2010-12-17 22:07:51 +00:00
Jakob Stoklund Olesen 213de04d75 Fix crash when IntervalMapOverlaps::advanceTo moves past the last overlap.
llvm-svn: 122081
2010-12-17 19:18:38 +00:00
Jakob Stoklund Olesen 649a72b94e Complete tests for IntervalMapOverlaps.
llvm-svn: 122019
2010-12-17 01:31:49 +00:00
Jakob Stoklund Olesen af49e9774a Add basic test exposing many bugs.
llvm-svn: 121995
2010-12-16 19:46:09 +00:00
Michael J. Spencer f616b218c8 Support/PathV2: Change most functions in the path namespace to return their work
via their return value instead of an out parameter.

llvm-svn: 121149
2010-12-07 17:04:04 +00:00
Frits van Bommel 716f34c6fb CMake: Fix warning in gtest header used by unit tests.
llvm-svn: 121127
2010-12-07 10:22:07 +00:00
Jay Foad 583abbc4df PR5207: Change APInt methods trunc(), sext(), zext(), sextOrTrunc() and
zextOrTrunc(), and APSInt methods extend(), extOrTrunc() and new method
trunc(), to be const and to return a new value instead of modifying the
object in place.

llvm-svn: 121120
2010-12-07 08:25:19 +00:00
NAKAMURA Takumi 7291ebc353 unittests/CMakeLists.txt: Tweak unittests' layout to be identical to GNU build.
llvm-svn: 121117
2010-12-07 07:41:23 +00:00
Michael J. Spencer 1e090f0b8f Support/PathV2: Remove the error_code return type from all functions in the path
namespace. None of them return anything except for success anyway. These will be
converted to returning their result soon.

llvm-svn: 121109
2010-12-07 03:57:37 +00:00
Michael J. Spencer 92903a3339 Support/PathV2: Move make_absolute from path to fs.
llvm-svn: 121108
2010-12-07 03:57:17 +00:00
Michael J. Spencer 7ecd94cc0b Support/FileSystem: Add directory_iterator implementation.
llvm-svn: 120989
2010-12-06 04:28:42 +00:00
Michael J. Spencer 4fb115d2f3 Unittests/Support/PathV2: Add FileSystem tests.
llvm-svn: 120888
2010-12-04 03:18:42 +00:00
Jakob Stoklund Olesen e7ed7b6cfd Add IntervalMap::iterator::set{Start,Stop,Value} methods that allow limited
editing of the current interval.

These methods may cause coalescing, there are corresponding set*Unchecked
methods for editing without coalescing. The non-coalescing methods are useful
for applying monotonic transforms to all keys or values in a map without
accidentally coalescing transformed and untransformed intervals.

llvm-svn: 120829
2010-12-03 19:02:00 +00:00
Michael J. Spencer 6e74e11c85 Support/FileSystem: Add remove implementation.
llvm-svn: 120817
2010-12-03 17:53:43 +00:00
Benjamin Kramer 23e6bdf1ae unittests/Support/PathV2: remove(3) requires a terminated string.
llvm-svn: 120803
2010-12-03 12:33:32 +00:00
Michael J. Spencer b5ca6447bb Unittests/Support/PathV2: Cleanup and remove output.
llvm-svn: 120785
2010-12-03 02:22:34 +00:00
Michael J. Spencer ab16054770 unittests/Support/PathV2: Comment out test because some systems are saying that
a file exists when it shouldn't.

llvm-svn: 120784
2010-12-03 02:10:30 +00:00
Michael J. Spencer 4571040ea1 Support/FileSystem: Add unique_file and exists implementations.
llvm-svn: 120776
2010-12-03 01:21:28 +00:00
Michael J. Spencer 75942f9d93 Make valgrind happy.
llvm-svn: 120616
2010-12-01 22:28:42 +00:00
Michael J. Spencer f2cc8287ed Support/ADT/Twine: Add toNullTerminatedStringRef.
llvm-svn: 120600
2010-12-01 20:37:30 +00:00
Michael J. Spencer 9ceae88ffc unittests/Support/PathV2: Fix -pedantic warning.
llvm-svn: 120590
2010-12-01 19:23:49 +00:00
Jay Foad 25a5e4ca1f PR5207: Rename overloaded APInt methods set(), clear(), flip() to
setAllBits(), setBit(unsigned), etc.

llvm-svn: 120564
2010-12-01 08:53:58 +00:00
Michael J. Spencer a72df5fae8 Support/PathV2: Add is_{absolute,relative} implementation.
llvm-svn: 120560
2010-12-01 06:21:53 +00:00
Michael J. Spencer 112a769379 Support/PathV2: Add has_{root_path,root_name,root_directory,parent_path,filename,stem,extension} implementation.
llvm-svn: 120559
2010-12-01 06:03:50 +00:00
Michael J. Spencer 4d0c6fdda6 unittests/Support/PathV2: Make tests much shorter; although harder to understand.
I'm going to replace this all anyway with a proper table and separated tests
when done.

llvm-svn: 120558
2010-12-01 06:03:33 +00:00
Michael J. Spencer 87106c59ed Support/PathV2: Add extension implementation.
llvm-svn: 120550
2010-12-01 03:37:41 +00:00
Michael J. Spencer 956955ed8b Support/PathV2: Add stem implementation.
llvm-svn: 120547
2010-12-01 03:18:33 +00:00
Michael J. Spencer 142692006b Support/PathV2: Add filename implementation.
llvm-svn: 120546
2010-12-01 03:18:17 +00:00