Chris Lattner [Wed, 30 Dec 2009 02:11:14 +0000 (02:11 +0000)]
split t_Metadata into t_MDNode and t_MDString, eliminating some unsafe casting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92287
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 22:40:21 +0000 (22:40 +0000)]
factor code even more.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92280
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 22:35:39 +0000 (22:35 +0000)]
simplify some code and unbreak the build by not consuming an
extra token.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92279
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 29 Dec 2009 22:17:06 +0000 (22:17 +0000)]
remove a really wrong parenthesis.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92277
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 22:01:50 +0000 (22:01 +0000)]
clean up some really strange code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92275
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 21:53:55 +0000 (21:53 +0000)]
change ParseMDString and ParseMDNode to take arguments of the right type.
This exposed a raft of other problems, which I'll deal with in subsequent
patches.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92273
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 21:43:58 +0000 (21:43 +0000)]
switch to TrackingVH instead of WeakVH, since these can never
be RAUW'd and go to null. This also gets us some sorely lacking
type safety.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92272
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 21:25:40 +0000 (21:25 +0000)]
Each instruction is allowed to have *multiple* different
metadata objects on them. Though the entire compiler supports this,
the asmparser didn't.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92270
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 21:17:33 +0000 (21:17 +0000)]
Do not crash when .ll printing metadata that smells like debug info, but isn't.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92268
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 21:09:57 +0000 (21:09 +0000)]
fix indentation, fit in 80 cols.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92267
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 29 Dec 2009 16:57:26 +0000 (16:57 +0000)]
Replace a few more SmallVectors with arrays.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92265
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 29 Dec 2009 11:04:52 +0000 (11:04 +0000)]
Use an array instead of a SmallVector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92264
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 09:32:19 +0000 (09:32 +0000)]
remove a bunch of unneeded functions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92263
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 09:22:47 +0000 (09:22 +0000)]
major cleanups, much of this file was incorrectly indented.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92262
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 09:15:46 +0000 (09:15 +0000)]
one pass of cleanup over DebugInfo.h. Much more is still needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92261
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 09:12:29 +0000 (09:12 +0000)]
prune #includes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92260
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 09:01:33 +0000 (09:01 +0000)]
Final step in the metadata API restructuring: move the
getMDKindID/getMDKindNames methods to LLVMContext (and add
convenience methods to Module), eliminating MetadataContext.
Move the state that it maintains out to LLVMContext.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92259
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 08:06:56 +0000 (08:06 +0000)]
just cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92258
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 08:03:58 +0000 (08:03 +0000)]
remove useless argument.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92256
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:56:15 +0000 (07:56 +0000)]
privatize another interface.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92255
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:50:09 +0000 (07:50 +0000)]
the only call to this function (from clang) has been removed, zap it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92254
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:44:16 +0000 (07:44 +0000)]
remove some unneeded Metadata interfaces.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92252
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:28:33 +0000 (07:28 +0000)]
fix .cpp file to not wrap the entire file in namespace blocks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92250
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:25:48 +0000 (07:25 +0000)]
tidy up debug info comments, use ->isVoidTy() where reasonable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92249
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 07:12:03 +0000 (07:12 +0000)]
sink twine.h down out of Value.h. It is annoying that you need
to #include Twine.h just to give a twine a default value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92247
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjiv Gupta [Tue, 29 Dec 2009 03:24:34 +0000 (03:24 +0000)]
Extern declaration for unordered.f32 libcall was not being emitted. Fixed that.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92242
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 02:53:52 +0000 (02:53 +0000)]
When doing v1->RAUW(v2), don't do anything to metadata. We don't know
why one was replaced with the other. Even in the specific case of
debug information, it doesn't make sense to transfer the location over,
this will just result in jumbled loc info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92241
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 02:46:09 +0000 (02:46 +0000)]
sink the Instruction::HasMetadata bit into SubclassData.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92240
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 29 Dec 2009 02:14:09 +0000 (02:14 +0000)]
add a layer of accessors around the Value::SubClassData member, and use
a convention (shadowing the setter with private forwarding function) to
prevent subclasses from accidentally using it.
This exposed some bogosity in ConstantExprs, which was propaging the
opcode of the constant expr into the NUW/NSW/Exact field in the
getWithOperands/getWithOperandReplaced methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92239
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 23:41:32 +0000 (23:41 +0000)]
This is a major cleanup of the instruction metadata interfaces that
I asked Devang to do back on Sep 27. Instead of going through the
MetadataContext class with methods like getMD() and getMDs(), just
ask the instruction directly for its metadata with getMetadata()
and getAllMetadata().
This includes a variety of other fixes and improvements: previously
all Value*'s were bloated because the HasMetadata bit was thrown into
value, adding a 9th bit to a byte. Now this is properly sunk down to
the Instruction class (the only place where it makes sense) and it
will be folded away somewhere soon.
This also fixes some confusion in getMDs and its clients about
whether the returned list is indexed by the MDID or densely packed.
This is now returned sorted and densely packed and the comments make
this clear.
This introduces a number of fixme's which I'll follow up on.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92235
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:56:07 +0000 (21:56 +0000)]
rearrange some code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92234
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:52:41 +0000 (21:52 +0000)]
add IRBuilder.cpp to cmake
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92233
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:52:06 +0000 (21:52 +0000)]
remove #include that comes in from ConstantFolder.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92232
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:50:56 +0000 (21:50 +0000)]
remove #include of Function.h from IRBuilder
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92231
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:45:40 +0000 (21:45 +0000)]
move debug info stuff out of line, allowing two #includes
to go away from IRBuilder.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92230
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:28:46 +0000 (21:28 +0000)]
split code that doesn't need to be templated out of IRBuilder into a new
non-templated IRBuilderBase class. Move that large CreateGlobalString
out of line, eliminating the need to #include GlobalVariable.h in IRBuilder.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92227
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 21:12:29 +0000 (21:12 +0000)]
rename ivar to be more descriptive.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92226
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 20:45:51 +0000 (20:45 +0000)]
rename getMDKind -> getMDKindID, make it autoinsert if an MD Kind
doesn't exist already, eliminate registerMDKind. Tidy up a bunch
of random stuff.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92225
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 20:10:43 +0000 (20:10 +0000)]
rename getHandlerNames to getMDKindNames, simplify its interface
and simplify all the clients that use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92224
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 19:49:00 +0000 (19:49 +0000)]
tidy up and delete a dead smallvector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92223
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Mon, 28 Dec 2009 12:27:56 +0000 (12:27 +0000)]
Add missing include (for inline PATypeHolder::get).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92222
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 09:32:10 +0000 (09:32 +0000)]
avoid a completely unneeded linear walk.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92221
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 09:24:53 +0000 (09:24 +0000)]
Eliminate two bits of ugliness in MDNode::replaceElement:
eliminate the temporary smallvector, and only do FindNodeOrInsertPos
twice if the first one succeeds and we delete a node.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92220
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 09:12:35 +0000 (09:12 +0000)]
rearrange some methods, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92219
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 09:10:16 +0000 (09:10 +0000)]
avoid temporary CallbackVH's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92218
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 09:07:21 +0000 (09:07 +0000)]
Rewrite the function-local validation logic for MDNodes (most of r91708).
Among other benefits, this doesn't leak the SmallPtrSet, has the verifier
code in the verifier pass, actually does the verification at the end,
and is considerably simpler.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92217
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:48:12 +0000 (08:48 +0000)]
rename MDNode instance variables to something meaningful.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92216
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:30:43 +0000 (08:30 +0000)]
snip one more #include from Metadata.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92214
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:26:43 +0000 (08:26 +0000)]
prune #includes more.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92213
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:24:16 +0000 (08:24 +0000)]
prune some #includes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92212
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:20:46 +0000 (08:20 +0000)]
Metadata.h doesn't need to include ValueHandle.h anymore.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92211
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:14:54 +0000 (08:14 +0000)]
change the strange MetadataContext::getMDs function to expose less
irrelevant internal implementation details to clients.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92210
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 08:07:14 +0000 (08:07 +0000)]
change NamedMDNode to use a pimpl for its operand list instead
of making it a declared part of the value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92209
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 07:57:01 +0000 (07:57 +0000)]
eliminate the elem_* iterator stuff from NamedMDNode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92208
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 07:41:54 +0000 (07:41 +0000)]
move ElementVH out of the MDNode class into the MDNode.cpp file. Among
other things, this avoids vtable and rtti data for it being splatted in
every translation unit that uses it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92207
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 28 Dec 2009 07:41:18 +0000 (07:41 +0000)]
move these out of their own timer groups into the 'uncategorized' groups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92206
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjiv Gupta [Mon, 28 Dec 2009 04:53:24 +0000 (04:53 +0000)]
Fixed llc crash for zext (i1 -> i8) loads.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92201
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjiv Gupta [Mon, 28 Dec 2009 02:40:33 +0000 (02:40 +0000)]
Allow targets to specify the return type of libcalls that are generated for floating point comparisons, rather than hard-coding them as i32.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92199
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 02:07:00 +0000 (02:07 +0000)]
Mark variable used by 'assert' as 'unused'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92198
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 02:05:36 +0000 (02:05 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92197
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 02:04:53 +0000 (02:04 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92196
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 02:01:06 +0000 (02:01 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92195
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 02:00:30 +0000 (02:00 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92194
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:57:39 +0000 (01:57 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92193
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:54:15 +0000 (01:54 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92192
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:53:00 +0000 (01:53 +0000)]
Remove dead store and simplify code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92191
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:51:30 +0000 (01:51 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92190
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:48:56 +0000 (01:48 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92189
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:47:48 +0000 (01:47 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92188
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:44:39 +0000 (01:44 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92187
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:42:12 +0000 (01:42 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92186
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:41:12 +0000 (01:41 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92185
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:36:02 +0000 (01:36 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92184
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:34:57 +0000 (01:34 +0000)]
Mark some debug variables as 'unused' to quiet compiler and analyzer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92183
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:31:11 +0000 (01:31 +0000)]
Remove dead store. The initial value was never used, but always overridden.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92182
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:20:29 +0000 (01:20 +0000)]
Add an "ATTRIBUTE_UNUSED" macro (and use it). It's for variables which are
mainly used in debugging and/or assert situations. It should make the compiler
and the static analyzer stop nagging us about them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92181
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:02:21 +0000 (01:02 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92180
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:01:14 +0000 (01:01 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92179
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 28 Dec 2009 01:00:12 +0000 (01:00 +0000)]
Remove dead variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92178
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 26 Dec 2009 22:58:39 +0000 (22:58 +0000)]
lit: Add setuptools support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92169
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 26 Dec 2009 22:58:23 +0000 (22:58 +0000)]
lit: Sink code into a 'lit' package.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92168
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Sat, 26 Dec 2009 20:08:30 +0000 (20:08 +0000)]
PR5886: Make sure IMUL32m is marked as setting EFLAGS, so scheduling doesn't
do illegal stuff around it. No testcase because the issue is very fragile.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92167
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:50:18 +0000 (13:50 +0000)]
Avoid assigning to Changed when it won't be used after the return.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92160
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:45:50 +0000 (13:45 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92159
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:44:36 +0000 (13:44 +0000)]
Remove dead store from copy-pasto.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92158
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:39:58 +0000 (13:39 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92157
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:37:27 +0000 (13:37 +0000)]
Remove dead store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92156
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 25 Dec 2009 13:35:40 +0000 (13:35 +0000)]
Use the 'MadeChange' variable instead of returning 'false' all of the time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92155
91177308-0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 24 Dec 2009 23:18:09 +0000 (23:18 +0000)]
Implement support for converting to string at "natural precision", and fix some
major bugs in long-precision conversion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92150
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 24 Dec 2009 21:15:37 +0000 (21:15 +0000)]
Move the two definitions of operator<< into namespace llvm, so they
will be found by argument-dependent lookup. As with the previous
commit, GCC is allowing ill-formed code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92146
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Thu, 24 Dec 2009 21:11:45 +0000 (21:11 +0000)]
Define the new operator<< for sets into namespace std, so that
argument-dependent lookup can find it. This is another case where an
LLVM bug (not making operator<< visible) was masked by a GCC bug
(looking in the global namespace when it shouldn't).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92144
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 24 Dec 2009 17:49:28 +0000 (17:49 +0000)]
Don't emit trailing semicolon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92133
91177308-0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 24 Dec 2009 12:16:56 +0000 (12:16 +0000)]
Substantially optimize APFloat::toString() by doing a single large divide to
cut the significand down to the desired precision *before* entering the
core divmod loop. Makes the overall algorithm logarithmic in the exponent.
There's still a lot of room for improvement here, but this gets the
performance back down to acceptable-for-diagnostics levels, even for
long doubles.
negligible, even on long doubles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92130
91177308-0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 24 Dec 2009 08:56:26 +0000 (08:56 +0000)]
Add accessors for the largest-magnitude, smallest-magnitude, and
smallest-normalized-magnitude values in a given FP semantics.
Provide an APFloat-to-string conversion which I am quite ready to admit could
be much more efficient.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92126
91177308-0d34-0410-b5e6-
96231b3b80d8
John McCall [Thu, 24 Dec 2009 08:52:06 +0000 (08:52 +0000)]
Set Remainder before Quotient in case Quotient and LHS alias. The new
order should be immune to such problems.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92124
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Thu, 24 Dec 2009 01:10:43 +0000 (01:10 +0000)]
Testcase for llvm-gcc checkin 92108.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92110
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 24 Dec 2009 01:07:17 +0000 (01:07 +0000)]
handle equality memcmp of 8 bytes on x86-64 with two unaligned loads and a
compare. On other targets we end up with a call to memcmp because we don't
want 16 individual byte loads. We should be able to use movups as well, but
we're failing to select the generated icmp.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92107
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Thu, 24 Dec 2009 00:39:02 +0000 (00:39 +0000)]
Change errs() to dbgs().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92099
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 24 Dec 2009 00:37:38 +0000 (00:37 +0000)]
move an optimization for memcmp out of simplifylibcalls and into
SDISel. This optimization was causing simplifylibcalls to
introduce type-unsafe nastiness. This is the first step, I'll be
expanding the memcmp optimizations shortly, covering things that
we really really wouldn't want simplifylibcalls to do.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92098
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Thu, 24 Dec 2009 00:34:21 +0000 (00:34 +0000)]
Change errs() to dbgs().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92097
91177308-0d34-0410-b5e6-
96231b3b80d8