Devang Patel
ae097e977b
Add an interface to attach debugging information with an instruction.
...
llvm-svn: 82062
2009-09-16 18:16:11 +00:00
Chris Lattner
5bb0ee8c70
hopefully unbreak the build by making this-> explicit for dependent
...
base class lookup.
llvm-svn: 80499
2009-08-30 17:44:10 +00:00
Chris Lattner
c3deceaf81
some minor cleanups to IRBuilder, factor the insertion
...
hook out of the main IRBuilder class to allow clients to
override it.
llvm-svn: 80479
2009-08-30 05:42:59 +00:00
Dan Gohman
4d20610e6e
Eliminate the unused Context argument on one of the ICmpInst and FCmpInst
...
constructors.
llvm-svn: 80049
2009-08-25 23:17:54 +00:00
Daniel Dunbar
d26934ba4a
Switch IRBuilder to using Twine references for names.
...
llvm-svn: 79482
2009-08-19 22:34:21 +00:00
Erick Tryzelaar
532ab606ff
Add more casts to the IRBuilder.
...
llvm-svn: 79158
2009-08-16 02:19:46 +00:00
Owen Anderson
cc33bb3cdf
Add doxygen comments.
...
llvm-svn: 79027
2009-08-14 19:41:50 +00:00
Erick Tryzelaar
7adf1fa7ad
A couple IRBuilder functions were still using getGlobalContext().
...
llvm-svn: 78997
2009-08-14 06:12:30 +00:00
Owen Anderson
c78a800e7e
Add helpers for fetching basic types.
...
llvm-svn: 78969
2009-08-14 00:30:41 +00:00
Owen Anderson
9df206d02d
Push LLVMContexts through the IntegerType APIs.
...
llvm-svn: 78948
2009-08-13 21:58:54 +00:00
Dan Gohman
9a6b2f19e5
Remove a bunch more now-unnecessary Context arguments.
...
llvm-svn: 78809
2009-08-12 16:23:25 +00:00
Dan Gohman
b0c54f532c
Add convenience functions for creating nsw add operators.
...
llvm-svn: 78707
2009-08-11 20:20:39 +00:00
Dan Gohman
aed57ee5b0
Add convenience functions for creating inbounds GEPs.
...
llvm-svn: 78695
2009-08-11 17:57:01 +00:00
Dan Gohman
cf73a006f0
Use isa instead of dyn_cast when the result is only converted to bool.
...
llvm-svn: 78685
2009-08-11 17:20:16 +00:00
Dan Gohman
82b3823bb7
Add convenience functions for creating exact sdiv operators, and
...
use them in CreatePtrDiff.
llvm-svn: 78682
2009-08-11 17:05:24 +00:00
Dan Gohman
0c6e8e18aa
Add an explicit keyword.
...
llvm-svn: 78675
2009-08-11 15:57:42 +00:00
Owen Anderson
1dc40e205b
Move a few more APIs back to 2.5 forms. The only remaining ones left to change back are
...
metadata related, which I'm waiting on to avoid conflicting with Devang.
llvm-svn: 77721
2009-07-31 20:28:14 +00:00
Owen Anderson
93ccaf5c60
Move more code back to 2.5 APIs.
...
llvm-svn: 77635
2009-07-30 23:03:37 +00:00
Owen Anderson
0ce2151b36
Move ConstantExpr to 2.5 API.
...
llvm-svn: 77494
2009-07-29 18:55:55 +00:00
Owen Anderson
aa8c94b051
Change ConstantArray to 2.5 API.
...
llvm-svn: 77347
2009-07-28 18:32:17 +00:00
Eric Christopher
df9c86fc26
Move ExtractElementInst to ::Create instead of new. Update all uses.
...
llvm-svn: 77044
2009-07-25 02:28:41 +00:00
Owen Anderson
cc33e89571
Revert the ConstantInt constructors back to their 2.5 forms where possible, thanks to contexts-on-types. More to come.
...
llvm-svn: 77011
2009-07-24 23:12:02 +00:00
Owen Anderson
cc287b28c9
Get rid of the Pass+Context magic.
...
llvm-svn: 76702
2009-07-22 00:24:57 +00:00
Owen Anderson
4483fbda5e
Revert yesterday's change by removing the LLVMContext parameter to AllocaInst and MallocInst.
...
llvm-svn: 75863
2009-07-15 23:53:25 +00:00
Owen Anderson
8c85061ee6
Move EVER MORE stuff over to LLVMContext.
...
llvm-svn: 75703
2009-07-14 23:09:55 +00:00
Owen Anderson
1e5155161a
Move more functionality over to LLVMContext.
...
llvm-svn: 75497
2009-07-13 20:58:05 +00:00
Owen Anderson
393d8b0a0c
Begin the painful process of tearing apart the rat'ss nest that is Constants.cpp and ConstantFold.cpp.
...
This involves temporarily hard wiring some parts to use the global context. This isn't ideal, but it's
the only way I could figure out to make this process vaguely incremental.
llvm-svn: 75445
2009-07-13 04:09:18 +00:00
Owen Anderson
1500792c2c
Finish pushing LLVMContext through the IRBuilder/ConstantFolder interface.
...
llvm-svn: 75213
2009-07-10 00:49:53 +00:00
Owen Anderson
49226b1075
This started as a small change, I swear. Unfortunately, lots of things call the [I|F]CmpInst constructors. Who knew!?
...
llvm-svn: 75200
2009-07-09 23:48:35 +00:00
Jeffrey Yasskin
a34904f9f8
Work around an ICE in gcc-4.2.4.
...
llvm-svn: 75084
2009-07-09 00:52:44 +00:00
Owen Anderson
9331034838
Push LLVMContext _back_ through IRBuilder.
...
llvm-svn: 75040
2009-07-08 20:50:47 +00:00
Owen Anderson
332aae685b
Switch GlobalVariable ctors to a sane API, where *either* a context or a module is required.
...
llvm-svn: 75025
2009-07-08 19:03:57 +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
Owen Anderson
7a1f69e433
Push LLVMContext through GlobalVariables and IRBuilder.
...
llvm-svn: 74985
2009-07-08 01:26:06 +00:00
Anton Korobeynikov
fed9dcc88c
Revert IRBuilder CC propagation. Fix SimplifyLibCalls instead.
...
llvm-svn: 73715
2009-06-18 20:05:31 +00:00
Anton Korobeynikov
82ab724191
Forgot to commit this hunk
...
llvm-svn: 73693
2009-06-18 08:30:57 +00:00
Anton Korobeynikov
e492bc7546
Propagate calling conv for invokes too
...
llvm-svn: 73692
2009-06-18 08:13:56 +00:00
Anton Korobeynikov
77a0bd41fc
Honour calling convention and attributes of Callee by default.
...
llvm-svn: 73646
2009-06-17 22:20:46 +00:00
Chris Lattner
ee538a1431
make CreateFMul forward to CreateFMul, not CreateMul.
...
llvm-svn: 73603
2009-06-17 06:31:02 +00:00
Dan Gohman
cccda40191
Add a CreateFNeg function to IRBuilder.
...
llvm-svn: 73437
2009-06-15 22:50:40 +00:00
Dan Gohman
5f6f8101d5
Split the Add, Sub, and Mul instruction opcodes into separate
...
integer and floating-point opcodes, introducing
FAdd, FSub, and FMul.
For now, the AsmParser, BitcodeReader, and IRBuilder all preserve
backwards compatability, and the Core LLVM APIs preserve backwards
compatibility for IR producers. Most front-ends won't need to change
immediately.
This implements the first step of the plan outlined here:
http://nondot.org/sabre/LLVMNotes/IntegerOverflow.txt
llvm-svn: 72897
2009-06-04 22:49:04 +00:00
Dan Gohman
17d7639520
Add an accessor method to return the insertion point.
...
llvm-svn: 72184
2009-05-20 21:45:41 +00:00
Nick Lewycky
e5b361c13a
Cleanup. Remove redundant llvm:: , we don't need them since we're inside
...
namespace llvm already.
llvm-svn: 68774
2009-04-10 06:54:06 +00:00
Nick Lewycky
0f4dbe06e7
Add utility function to IRBuilder that takes the difference between two
...
pointers, taking into account the size of the pointed-to object.
Patch by Jeffrey Yasskin!
llvm-svn: 68768
2009-04-10 05:30:48 +00:00
Chris Lattner
4fe63a51eb
add method to access a template argument.
...
llvm-svn: 67458
2009-03-22 00:18:18 +00:00
Daniel Dunbar
4050346c70
Add IRBuilder::CreateConstGEP{1, 2}_{32, 64}.
...
- Names are lame, but it seems better to be explicit.
llvm-svn: 66295
2009-03-06 22:26:07 +00:00
Misha Brukman
7ee4196e74
Removed trailing whitespace.
...
llvm-svn: 65196
2009-02-20 22:51:36 +00:00
Dan Gohman
8271066844
Tidy up #includes, deleting a bunch of unnecessary #includes.
...
llvm-svn: 61715
2009-01-05 17:59:02 +00:00
Nick Lewycky
3889c7ebf0
Clean up some strange whitespace.
...
llvm-svn: 59373
2008-11-15 20:32:33 +00:00
Daniel Dunbar
553c69eecd
Rename IRBuilder::IsNonNull -> IsNotNull in response to feedback.
...
llvm-svn: 56953
2008-10-02 17:05:03 +00:00