Commit Graph

14503 Commits

Author SHA1 Message Date
Duncan Sands 5710211af0 This file was moved from Support to ADT. Correct a comment.
llvm-svn: 136344
2011-07-28 08:36:22 +00:00
Nick Lewycky 3255d1d25f In DenseMapInfo<pair<T, U>> tombstone key, use the tombstone for T and U instead
of the empty key for U. This shouldn't really matter because the tombstone key
for the pair was still distinct from every other key, but it is odd. Patch by
Michael Ilseman!

llvm-svn: 136336
2011-07-28 06:48:33 +00:00
Bill Wendling 4c93488999 Make sure that the landingpad instruction takes a Constant* as the clause's value.
llvm-svn: 136326
2011-07-28 02:27:12 +00:00
Bill Wendling a8f04e3034 Add a couple of convenience functions:
* InvokeInst: Get the landingpad instruction associated with this invoke.
* LandingPadInst: A method to reserve extra space for clauses.

llvm-svn: 136325
2011-07-28 02:15:52 +00:00
Argyrios Kyrtzidis 348937de07 Add an optional 'bool makeAbsolute' in llvm::sys::fs::unique_file function.
If true and 'model' parameter is not an absolute path, a temp directory will be prepended.
Make it true by default to match current behaviour.

llvm-svn: 136310
2011-07-28 00:29:20 +00:00
Eli Friedman 26a484852e Code generation for 'fence' instruction.
llvm-svn: 136283
2011-07-27 22:21:52 +00:00
Jakub Staszak da3df4302a Use BlockFrequency instead of uint32_t in BlockFrequencyInfo.
llvm-svn: 136278
2011-07-27 22:05:51 +00:00
Bill Wendling 2641d132d1 Keep enums stable. Append EH stuff to the end.
llvm-svn: 136263
2011-07-27 21:00:28 +00:00
Bill Wendling 6c923bb8d9 Merge the contents from exception-handling-rewrite to the mainline.
This adds the new instructions 'landingpad' and 'resume'.

llvm-svn: 136253
2011-07-27 20:18:04 +00:00
Eli Friedman 4fc946cc71 The numbering of LLVMOpcode is supposed to be stable; revert my earlier change, and append Fence onto the end.
llvm-svn: 136245
2011-07-27 18:59:19 +00:00
Ted Kremenek 666bec46a0 Add a generic 'capacity_in_bytes' function to allow inspection of memory usage of various data structures.
llvm-svn: 136233
2011-07-27 18:40:45 +00:00
Jakub Staszak a9e8aa0482 Move static methods to the anonymous namespace.
llvm-svn: 136221
2011-07-27 15:51:51 +00:00
Jakub Staszak 107339e31a Edge to itself is backedge as well.
llvm-svn: 136219
2011-07-27 15:42:09 +00:00
Eli Friedman 89b694b096 Misc mid-level changes for new 'fence' instruction.
llvm-svn: 136205
2011-07-27 01:08:30 +00:00
Eli Friedman ae8161e774 Fix AliasSetTracker so that it doesn't make any assumptions about instructions it doesn't know about (like the atomic instructions I'm adding).
llvm-svn: 136198
2011-07-27 00:46:46 +00:00
Evan Cheng 481ebb0133 Support .code32 and .code64 in X86 assembler.
llvm-svn: 136197
2011-07-27 00:38:12 +00:00
Eli Friedman 4e8e257d58 Fix a couple minor mistakes pointed out by Bill in adding 'fence' instruction.
llvm-svn: 136124
2011-07-26 20:24:06 +00:00
Andrew Trick 3ca3f98c2c SCEV: Added a data structure for storing not-taken info per loop
exit. Added an interfaces for querying either the loop's exact/max
backedge taken count or a specific loop exit's not-taken count.

llvm-svn: 136100
2011-07-26 17:19:55 +00:00
Duncan Sands 6d473aa378 Strip trailing whitespace.
llvm-svn: 136099
2011-07-26 17:19:30 +00:00
Duncan Sands fe44f67d43 Teach the Triple class about kfreebsd (FreeBSD kernel with
a GNU userspace).

llvm-svn: 136085
2011-07-26 15:30:04 +00:00
Rafael Espindola b84dc6bca8 Add LLVMAddAlwaysInlinerPass to the C API.
llvm-svn: 136083
2011-07-26 15:23:23 +00:00
Rafael Espindola be2fe29f9c LLVM 3.0 is here, remove old do nothing method.
llvm-svn: 136082
2011-07-26 15:17:32 +00:00
Jay Foad 6a51402a8a Fix typo in comment.
llvm-svn: 136068
2011-07-26 09:36:52 +00:00
Evan Cheng 3a79225b4c Rename createCodeEmitter to createMCCodeEmitter; createObjectStreamer to createMCObjectStreamer.
llvm-svn: 136031
2011-07-26 00:42:34 +00:00
Evan Cheng 1142444565 Rename TargetAsmParser to MCTargetAsmParser and TargetAsmLexer to MCTargetAsmLexer; rename createAsmLexer to createMCAsmLexer and createAsmParser to createMCAsmParser.
llvm-svn: 136027
2011-07-26 00:24:13 +00:00
Evan Cheng 5928e69d20 Rename TargetAsmBackend to MCAsmBackend; rename createAsmBackend to createMCAsmBackend.
llvm-svn: 136010
2011-07-25 23:24:55 +00:00
Eli Friedman fee02c6c13 Initial implementation of 'fence' instruction, the new C++0x-style replacement for llvm.memory.barrier.
This is just a LangRef entry and reading/writing/memory representation; optimizer+codegen support coming soon.

llvm-svn: 136009
2011-07-25 23:16:38 +00:00
Evan Cheng 1740a97734 Fix include guards.
llvm-svn: 135998
2011-07-25 22:52:04 +00:00
Jakub Staszak e92d047b51 BranchProbability::print returns void now.
llvm-svn: 135994
2011-07-25 22:27:42 +00:00
Jakub Staszak 49993f26bf Add BlockFrequency class.
llvm-svn: 135992
2011-07-25 22:24:51 +00:00
Rafael Espindola e96fd5a4fe Add LLVMAddTargetLibraryInfo to the C API.
llvm-svn: 135975
2011-07-25 21:20:54 +00:00
Rafael Espindola 7281395c8c Add LLVMAddLowerExpectIntrinsicPass to the C API.
llvm-svn: 135966
2011-07-25 20:57:59 +00:00
Evan Cheng f60768a14e Fix last bits of MC layer issues. llvm-mc doesn't need to initialize TargetMachine's anymore.
llvm-svn: 135963
2011-07-25 20:53:02 +00:00
Jakub Staszak 12bc09c843 Fix class description.
llvm-svn: 135948
2011-07-25 20:08:58 +00:00
Jakub Staszak 4e48f3df16 Fix #include guard directive.
llvm-svn: 135947
2011-07-25 20:08:00 +00:00
Jakub Staszak 875ebd5f5d Rename BlockFrequency to BlockFrequencyInfo and MachineBlockFrequency to
MachineBlockFrequencyInfo.

llvm-svn: 135937
2011-07-25 19:25:40 +00:00
Jay Foad a9f7959897 Remove uses of std::vector from TypeBuilder.
llvm-svn: 135906
2011-07-25 10:32:27 +00:00
Jay Foad 89d9b81a3a Use ArrayRef in the (protected) constructors of ConstantArray, ConstantStruct and ConstantVector.
llvm-svn: 135905
2011-07-25 10:14:44 +00:00
Jay Foad d1b7849d49 Convert GetElementPtrInst to use ArrayRef.
llvm-svn: 135904
2011-07-25 09:48:08 +00:00
Chris Lattner d757d3f5c2 switch Triple to take twines instead of stringrefs.
llvm-svn: 135889
2011-07-24 20:45: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
Frits van Bommel ba50c2b55c Omit explicit length here, now that I've had a chance to test this with gcc.
llvm-svn: 135867
2011-07-24 09:53:46 +00:00
Benjamin Kramer 8957aaa2d2 Fix a silly off by one.
llvm-svn: 135842
2011-07-23 03:04:46 +00:00
Benjamin Kramer eeddeb9601 Add more constness.
llvm-svn: 135838
2011-07-23 01:40:15 +00:00
Benjamin Kramer 346f3a3b8c Turn the DenseSet in MCRegisterClass into a tblgenerated bit field. This should be faster and smaller.
Goodbye static ctors and dtors!

llvm-svn: 135836
2011-07-23 00:47:49 +00:00
Benjamin Kramer 2754ca1e10 Give TargetRegisterClass a pointer to the MCRegisterClass and use it to access its data.
This makes TargetRegisterClass slightly slower. Next step will be making contains faster.
Eventually TargetRegisterClass will be killed entirely.

llvm-svn: 135835
2011-07-23 00:47:46 +00:00
Evan Cheng f2596bc62a Move TargetAsmParser.h TargetAsmBackend.h and TargetAsmLexer.h to MC where they belong.
llvm-svn: 135833
2011-07-23 00:45:41 +00:00
NAKAMURA Takumi 61a38c7f7f CMake: Fix LLVM_NATIVE_TARGETMC in config.h.cmake.
llvm-svn: 135832
2011-07-23 00:45:23 +00:00
NAKAMURA Takumi b8851ee6aa config.h.cmake: Reorder along config.h.in.
llvm-svn: 135831
2011-07-23 00:45:16 +00:00
Andrew Trick 1cabe54fab Move trip count discovery outside of the generic LoopUnroll helper. This
removes its dependence on canonical induction variables.

llvm-svn: 135829
2011-07-23 00:33:05 +00:00