Chris Lattner
7b6a968f5d
enhance vmcore to know that udiv's can be exact, and add a trivial
...
instcombine xform to exercise this.
Nothing forms exact udivs yet though. This is progress on PR8862
llvm-svn: 124992
2011-02-06 21:44:57 +00:00
Michael J. Spencer
861d5122e2
UnRevert "Revert "Archive: Replace all internal uses of PathV1 with PathV2. The external API still uses PathV1.""
...
llvm-svn: 123605
2011-01-16 23:39:59 +00:00
Michael J. Spencer
76f1706025
Revert "Archive: Replace all internal uses of PathV1 with PathV2. The external API still uses PathV1."
...
llvm-svn: 123557
2011-01-16 01:43:22 +00:00
Michael J. Spencer
927075c958
Archive: Fix spelling.
...
llvm-svn: 123552
2011-01-15 21:43:45 +00:00
Michael J. Spencer
303c304f0d
Archive: Replace all internal uses of PathV1 with PathV2. The external API still uses PathV1.
...
llvm-svn: 123551
2011-01-15 21:43:37 +00:00
Michael J. Spencer
d5ec932c3a
Merge System into Support.
...
llvm-svn: 120298
2010-11-29 18:16:10 +00:00
Bill Wendling
179ecd5159
Remove tabs.
...
llvm-svn: 115764
2010-10-06 07:19:18 +00:00
Bill Wendling
ef718b99d4
Provide a fast "get me the target triple from the module" API. This can
...
drastically reduce the linking time during LTO.
Patch by Shantonu Sen!
llvm-svn: 115728
2010-10-06 01:22:42 +00:00
Dale Johannesen
b3df2ff13d
Add X86 MMX type to bitcode and Type.
...
(The Ada bindings probably need it too, but all the
obvious places to change say "do not edit this file".)
llvm-svn: 113618
2010-09-10 20:55:01 +00:00
Dan Gohman
a9936d3f97
Discard metadata produced by LLVM 2.7. The value enumeration it used
...
is different from what the code now uses in a two ways: NamedMDNodes
were considered Values and included in the numbering, and the
function-local metadata counter wasn't reset between functions.
The later problem breaks lazy deserialization, so instead of trying
to emulate the old numbering, just drop the old metadata. The only
in-tree use case is debug info with LTO, where the QOI loss is
considered acceptable.
llvm-svn: 113557
2010-09-09 23:12:39 +00:00
Dan Gohman
81f9434e99
Remove obsolete comments about throwing exceptions.
...
llvm-svn: 112874
2010-09-02 22:14:51 +00:00
Chris Lattner
ecf276b787
remove unions from LLVM IR. They are severely buggy and not
...
being actively maintained, improved, or extended.
llvm-svn: 112356
2010-08-28 04:09:24 +00:00
Chris Lattner
25446ccf9f
don't emit zero bit fields with Emit, fixing undefined behavior,
...
PR7778
llvm-svn: 111336
2010-08-18 00:29:18 +00:00
Dan Gohman
d13e45d0ec
Don't special-case stdout in llvm::WriteBitcodeToFile; just consider
...
it to be the caller's responsibility to provide a stream in binary
mode. This fixes a layering violation and avoids an outs() call.
llvm-svn: 104878
2010-05-27 20:06:51 +00:00
Benjamin Kramer
96b4f6c003
Don't write into MemoryBuffers.
...
llvm-svn: 101783
2010-04-19 16:15:31 +00:00
Chris Lattner
c2f273b52d
Add special case bitcode support for DebugLoc. This avoids
...
having the bitcode writer materialize mdnodes for all the
debug location tuples when writing out the bc file and
stores the information in a more compact form. For example,
the -O0 -g bc file for combine.c in 176.gcc shrinks from
739392 to 512096 bytes.
This concludes my planned short-term debug info work.
llvm-svn: 100261
2010-04-03 02:17:50 +00:00
Chris Lattner
2265d6280b
Add support for a union type in LLVM IR. Patch by Talin!
...
llvm-svn: 96011
2010-02-12 20:49:41 +00:00
Dan Gohman
92b6122204
Fix "the the" and similar typos.
...
llvm-svn: 95781
2010-02-10 16:03:48 +00:00
Jeffrey Yasskin
fb10587e50
Kill ModuleProvider and ghost linkage by inverting the relationship between
...
Modules and ModuleProviders. Because the "ModuleProvider" simply materializes
GlobalValues now, and doesn't provide modules, it's renamed to
"GVMaterializer". Code that used to need a ModuleProvider to materialize
Functions can now materialize the Functions directly. Functions no longer use a
magic linkage to record that they're materializable; they simply ask the
GVMaterializer.
Because the C ABI must never change, we can't remove LLVMModuleProviderRef or
the functions that refer to it. Instead, because Module now exposes the same
functionality ModuleProvider used to, we store a Module* in any
LLVMModuleProviderRef and translate in the wrapper methods. The bindings to
other languages still use the ModuleProvider concept. It would probably be
worth some time to update them to follow the C++ more closely, but I don't
intend to do it.
Fixes http://llvm.org/PR5737 and http://llvm.org/PR5735 .
llvm-svn: 94686
2010-01-27 20:34:15 +00:00
Victor Hernandez
f4272b50d6
Compute isFunctionLocal in MDNode ctor or via argument in new function getWhenValsUnresolved().
...
Document PFS argument to ParseValID() and ConvertGlobalOrMetadataValIDToValue().
llvm-svn: 93108
2010-01-10 07:14:18 +00:00
Ted Kremenek
73df1b5d05
Remove old header.
...
llvm-svn: 92378
2010-01-01 00:04:49 +00:00
Ted Kremenek
15f320fa10
Remove derelict serialization code.
...
llvm-svn: 92374
2009-12-31 23:40:17 +00:00
Chris Lattner
587962c667
Remove isPod() from DenseMapInfo, splitting it out to its own
...
isPodLike type trait. This is a generally useful type trait for
more than just DenseMap, and we really care about whether something
acts like a pod, not whether it really is a pod.
llvm-svn: 91421
2009-12-15 07:26:43 +00:00
Daniel Dunbar
4daaf9d3f4
Pass StringRef by value.
...
llvm-svn: 86251
2009-11-06 10:58:06 +00:00
Chris Lattner
075e225442
bitcode writer support for blockaddress.
...
llvm-svn: 85376
2009-10-28 05:24:40 +00:00
Chris Lattner
2bc8002f4c
rename indbr -> indirectbr to appease the residents of #llvm.
...
llvm-svn: 85351
2009-10-28 00:19:10 +00:00
Chris Lattner
665b9e2a3c
Random updates to passes for indbr, I need blockaddress before I can do much more.
...
llvm-svn: 85316
2009-10-27 21:27:42 +00:00
Chris Lattner
fdda543cea
add enough support for indirect branch for the feature test to pass
...
(assembler,asmprinter, bc reader+writer) and document it. Codegen
currently aborts on it.
llvm-svn: 85274
2009-10-27 19:13:16 +00:00
Chandler Carruth
766362c707
Move DataTypes.h to include/llvm/System, update all users. This breaks the last
...
direct inclusion edge from System to Support.
llvm-svn: 85086
2009-10-26 01:35:46 +00:00
Devang Patel
c195f74dee
Write and read metadata attachments.
...
llvm-svn: 82259
2009-09-18 19:26:43 +00:00
Dan Gohman
6166bac383
Add const qualifiers for isBitcodeWrapper, and add new functions
...
isRawBitcode and isBitcode to allow clients to test whether a given
memory buffer holds a bitcode image.
llvm-svn: 80804
2009-09-02 17:21:29 +00:00
Gabor Greif
cc8681cea3
Clean up the minor mess I caused with removing iterator.h. I shall take care of 80-col violations and the FIXME later. (Thanks goodness that I live in another continent, so the monkeypox did not strike me :-)
...
llvm-svn: 80224
2009-08-27 06:41:46 +00:00
Daniel Dunbar
b98f0e9942
Add StringRef based APIs to BitstreamWriter.
...
llvm-svn: 79904
2009-08-24 09:29:31 +00:00
Chris Lattner
0c7ea3d3cc
remove the last *stream> #include from a public header.
...
llvm-svn: 79892
2009-08-24 04:14:03 +00:00
Chris Lattner
b0478019b4
eliminate the std::ostream forms of the bitcode writing APIs.
...
llvm-svn: 79840
2009-08-23 07:49:08 +00:00
Dan Gohman
6ec8176e22
Rename hasNoUnsignedOverflow and hasNoSignedOverflow to hasNoUnsignedWrap
...
and hasNoSignedWrap, for consistency with the nuw and nsw properties.
llvm-svn: 79539
2009-08-20 17:11:38 +00:00
Benjamin Kramer
9a590500ea
Make LLVMContext and LLVMContextImpl classes instead of structs.
...
llvm-svn: 78690
2009-08-11 17:45:13 +00:00
Owen Anderson
cf2c39dc30
Factor some of the constants+context related code out into a separate header, to make LLVMContextImpl.h
...
not hideous. Also, fix some MSVC compile errors.
llvm-svn: 78115
2009-08-04 22:41:48 +00:00
Devang Patel
d5b7c64109
Read and write NamedMDNode.
...
llvm-svn: 77517
2009-07-29 22:34:41 +00:00
Dan Gohman
490eb36e1d
Add a new keyword 'inbounds' for use with getelementptr. See the
...
LangRef.html changes for details.
llvm-svn: 77259
2009-07-27 21:53:46 +00:00
Devang Patel
6b2162686a
Derive MDNode from MetadataBase instead of Constant. Emit MDNodes into METADATA_BLOCK in bitcode file.
...
llvm-svn: 76834
2009-07-23 01:07:34 +00:00
Devang Patel
5794cb80ad
Introduce MetadataBase, a base class for MDString and MDNode.
...
Derive MDString directly from MetadataBase.
Introduce new bitcode block to hold metadata.
llvm-svn: 76759
2009-07-22 17:43:22 +00:00
Dan Gohman
d2ad3e183b
Assembly and Bitcode support for unsigned/signed overflow flags and
...
exact sdiv flags.
llvm-svn: 76475
2009-07-20 21:19:07 +00:00
Nick Lewycky
d46a7b2d22
Remove the vicmp and vfcmp instructions. Because we never had a release with
...
these instructions, no autoupgrade or backwards compatibility support is
provided.
llvm-svn: 74991
2009-07-08 03:04:38 +00:00
Chris Lattner
2bbbcbca79
fix some type confusion in ReadVBR64: "Piece" should be only 32 bits,
...
not 64, because we read at most 32 bits at a time. OTOH, "Result" must
be 64-bits and insertion into it must be 64-bit clean. Thanks to Ivan
Sorokin for bringing this up.
llvm-svn: 74932
2009-07-07 18:39:49 +00:00
Owen Anderson
4fa7e54329
Make the use of const with respect to LLVMContext sane. Hopefully this is the last time, for the
...
moment, that I will need to make far-reaching changes.
llvm-svn: 74655
2009-07-01 23:13:44 +00:00
Owen Anderson
cf112e59c3
Hold the LLVMContext by reference rather than by pointer.
...
llvm-svn: 74640
2009-07-01 21:22:36 +00:00
Owen Anderson
81b8dabb53
Add a pointer to the owning LLVMContext to Module. This requires threading LLVMContext through a lot
...
of the bitcode reader and ASM parser APIs, as well as supporting it in all of the tools.
Patches for Clang and LLVM-GCC to follow.
llvm-svn: 74614
2009-07-01 16:58:40 +00:00
Sebastian Redl
51473d2434
Fix three MSVC 2008 warnings that completely clutter the build output.
...
llvm-svn: 74430
2009-06-29 17:12:06 +00:00
Nick Lewycky
a9de2f1c81
Give embedded metadata its own type instead of relying on EmptyStructTy.
...
llvm-svn: 72610
2009-05-30 05:06:04 +00:00