Nick Lewycky
e6141a5d6f
Oops! Missed a file in my last commit.
...
llvm-svn: 70491
2009-04-30 15:29:26 +00:00
Bill Wendling
9f795134f3
The second part of the change from -fast to -O#. This changes the JIT to accept
...
an optimization level instead of a simple boolean telling it to generate code
"fast" or the other type of "fast".
llvm-svn: 70347
2009-04-29 00:32:19 +00:00
Rafael Espindola
56548523f5
Add LTO_SYMBOL_DEFINITION_WEAKUNDEF, use that on the gold plugin.
...
llvm-svn: 69972
2009-04-24 16:55:21 +00:00
Chris Lattner
2dba0f0d75
add AvailableExternally linkage to C bindings.
...
llvm-svn: 68942
2009-04-13 06:25:37 +00:00
Duncan Sands
4581bebf2a
It makes no sense to have a ODR version of common
...
linkage, so remove it.
llvm-svn: 66690
2009-03-11 20:14:15 +00:00
Duncan Sands
e2881053c9
Remove the one-definition-rule version of extern_weak
...
linkage: this linkage type only applies to declarations,
but ODR is only relevant to globals with definitions.
llvm-svn: 66650
2009-03-11 08:08:06 +00:00
Duncan Sands
12da8ce3d2
Introduce new linkage types linkonce_odr, weak_odr, common_odr
...
and extern_weak_odr. These are the same as the non-odr versions,
except that they indicate that the global will only be overridden
by an *equivalent* global. In C, a function with weak linkage can
be overridden by a function which behaves completely differently.
This means that IP passes have to skip weak functions, since any
deductions made from the function definition might be wrong, since
the definition could be replaced by something completely different
at link time. This is not allowed in C++, thanks to the ODR
(One-Definition-Rule): if a function is replaced by another at
link-time, then the new function must be the same as the original
function. If a language knows that a function or other global can
only be overridden by an equivalent global, it can give it the
weak_odr linkage type, and the optimizers will understand that it
is alright to make deductions based on the function body. The
code generators on the other hand map weak and weak_odr linkage
to the same thing.
llvm-svn: 66339
2009-03-07 15:45:40 +00:00
Chris Lattner
a59518276e
fix header comment and include guard.
...
llvm-svn: 66273
2009-03-06 16:54:19 +00:00
Chris Lattner
e48f897ca7
add a bunch more passes to the C bindings (PR3734), patch by
...
Lennart Augustsson!
llvm-svn: 66272
2009-03-06 16:52:18 +00:00
Nick Lewycky
8811ecdadf
Correct strange whitespace.
...
llvm-svn: 63927
2009-02-06 07:01:00 +00:00
Chris Lattner
41b43da217
add getPointerToGlobal to the C bindings, patch by Lennart Augustsson!
...
PR3364
llvm-svn: 62697
2009-01-21 18:11:10 +00:00
Duncan Sands
dc020f9c3c
Rename getABITypeSize to getTypePaddedSize, as
...
suggested by Chris.
llvm-svn: 62099
2009-01-12 20:38:59 +00:00
Gordon Henriksen
05a868f7af
Add dyn_cast_or_null bindings for some additional classes missed in r61252.
...
llvm-svn: 61253
2008-12-19 18:51:17 +00:00
Gordon Henriksen
29e3894e7d
C bindings for dyn_cast_or_null.
...
This operation can be used to build dyn_cast, isa, and cast.
llvm-svn: 61252
2008-12-19 18:39:45 +00:00
Chris Lattner
3d1f552643
This adds some missing functions to the C binding:
...
- ability to insert previously created instructions using a builder
- creation of aliases
- creation of inline asm constants
Patch by Zoltan Varga!
llvm-svn: 61153
2008-12-17 21:39:50 +00:00
Nick Lewycky
af67df5881
Add protected visibility to libLTO.
...
llvm-svn: 60257
2008-11-29 22:49:59 +00:00
Dan Gohman
d5104a5de6
Add C bindings for extractvalue and insertvalue. Patch by Frits van Bommel!
...
llvm-svn: 58650
2008-11-03 22:55:43 +00:00
Devang Patel
4c758ea3e0
Large mechanical patch.
...
s/ParamAttr/Attribute/g
s/PAList/AttrList/g
s/FnAttributeWithIndex/AttributeWithIndex/g
s/FnAttr/Attribute/g
This sets the stage
- to implement function notes as function attributes and
- to distinguish between function attributes and return value attributes.
This requires corresponding changes in llvm-gcc and clang.
llvm-svn: 56622
2008-09-25 21:00:45 +00:00
Gordon Henriksen
eeb6537abb
PR2731: C and Ocaml bindings for setTailCall and isTailCall.
...
Based on patch by Giorgos Korfiatis.
llvm-svn: 55570
2008-08-30 16:34:54 +00:00
Gordon Henriksen
d930f913e6
Rename some GC classes so that their roll will hopefully be clearer.
...
In particular, Collector was confusing to implementors. Several
thought that this compile-time class was the place to implement
their runtime GC heap. Of course, it doesn't even exist at runtime.
Specifically, the renames are:
Collector -> GCStrategy
CollectorMetadata -> GCFunctionInfo
CollectorModuleMetadata -> GCModuleInfo
CollectorRegistry -> GCRegistry
Function::getCollector -> getGC (setGC, hasGC, clearGC)
Several accessors and nested types have also been renamed to be
consistent. These changes should be obvious.
llvm-svn: 54899
2008-08-17 18:44:35 +00:00
Gordon Henriksen
72c1c7d694
Delete a redundant binding, LLVMHasInitializer.
...
Please use !LLVMIsDeclaration instead.
llvm-svn: 54572
2008-08-09 02:13:58 +00:00
Gordon Henriksen
5225cd66cf
Fix the LLVMCreateJITCompiler C binding.
...
Evan broke it in r54523 by adding a parameter in the implementation without
updating the header correspondingly.
llvm-svn: 54555
2008-08-08 20:49:28 +00:00
Eric Christopher
5927883970
Have IRBuilder take a template argument on whether or not to preserve
...
names. This can save a lot of allocations if you aren't going to be
looking at the output.
llvm-svn: 54546
2008-08-08 19:39:37 +00:00
Devang Patel
a0e4fb8283
Provide a hook to set the code generation debug options to investigate lto failures.
...
llvm-svn: 53119
2008-07-03 22:53:14 +00:00
Gordon Henriksen
9f337549a7
Add C binding for ExecutionEngine::addGlobalMapping.
...
llvm-svn: 52523
2008-06-20 02:16:11 +00:00
Gordon Henriksen
00889ccfca
Remove a duplicative binding. Patch by Mahadevan R.
...
llvm-svn: 51238
2008-05-19 05:47:10 +00:00
Gordon Henriksen
6ea927b1d7
Improve documentation.
...
llvm-svn: 50768
2008-05-06 19:17:01 +00:00
Gordon Henriksen
a735a9c481
Use (void) instead of () in C code.
...
llvm-svn: 50620
2008-05-04 12:55:34 +00:00
Anton Korobeynikov
5bf6876ab8
Correct parameter attributes encoding for C bindings.
...
Patch by Anders Johnsen!
llvm-svn: 50375
2008-04-28 21:48:04 +00:00
Gordon Henriksen
2d9cc2197a
Expose parameter attributes via C bindings.
...
Patch by Anders Johnsen!
llvm-svn: 50360
2008-04-28 17:37:06 +00:00
Gordon Henriksen
2ad5aef5e6
PR2245: Misleading parameter name in llvm-c/Core.h:LLVMConstArray
...
Applying fix by Frits van Bommel.
llvm-svn: 50250
2008-04-25 03:21:19 +00:00
Duncan Sands
a07136ee2d
Merge LLVMBuilder and FoldingBuilder, calling
...
the result IRBuilder. Patch by Dominic Hamon.
llvm-svn: 49604
2008-04-13 06:22:09 +00:00
Erick Tryzelaar
4a0da98825
Expose Function::viewCFG and Function::viewCFGOnly to bindings.
...
llvm-svn: 48982
2008-03-31 16:22:09 +00:00
Erick Tryzelaar
8ac07c2834
Expose ExecutionEngine::getTargetData() to c and ocaml bindings.
...
llvm-svn: 48851
2008-03-27 00:27:14 +00:00
Gordon Henriksen
07a45f4edb
Objective Caml bindings for basic block, function, global, and arg iterators.
...
llvm-svn: 48711
2008-03-23 22:21:29 +00:00
Gordon Henriksen
b81777a354
C and Objective Caml bindings for mem2reg and reg2mem.
...
Patch by Erick Tryzelaar.
llvm-svn: 48602
2008-03-20 17:16:03 +00:00
Gordon Henriksen
054817ce06
C bindings for Module-, Function-, and BasicBlock::iterator.
...
llvm-svn: 48528
2008-03-19 03:47:18 +00:00
Gordon Henriksen
265f780c22
C and Objective Caml bindings for the various getParent methods of the IR.
...
Based on Erick Tryzelaar's patch.
llvm-svn: 48523
2008-03-19 01:11:35 +00:00
Gordon Henriksen
ab4b7d36cd
C and Objective Caml bindings for the TargetData class.
...
llvm-svn: 48422
2008-03-16 20:08:03 +00:00
Gordon Henriksen
82a0e74f43
C and Objective Caml bindings for several scalar transforms.
...
Patch originally by Erick Tryzelaar, but has been modified somewhat.
llvm-svn: 48419
2008-03-16 16:32:40 +00:00
Gordon Henriksen
9657149875
Remove unnecessary includes.
...
llvm-svn: 48418
2008-03-16 15:55:43 +00:00
Gordon Henriksen
878114bf16
C and Objective Caml bindings for PassManagers.
...
llvm-svn: 48413
2008-03-16 04:20:44 +00:00
Gordon Henriksen
6c6075e326
Expose Module::dump via C and Ocaml.
...
Patch by Erick Tryzelaar.
llvm-svn: 48379
2008-03-14 23:58:56 +00:00
Gordon Henriksen
a49d435b27
Cleanup some comments in the OCaml bindings.
...
Patch by Erick Tryzelaar.
llvm-svn: 48014
2008-03-07 19:13:06 +00:00
Nick Kledzik
91a6dcff32
fixes from review of first commit
...
llvm-svn: 47695
2008-02-27 22:25:36 +00:00
Nick Kledzik
07b4a62234
first commit of new LTO system. It is not hooked up in the llvm/tools/Makefile, so no one will build it be default yet
...
llvm-svn: 47621
2008-02-26 20:26:43 +00:00
Gordon Henriksen
931e121ad1
Fixing a bug creating floating point constants of type other
...
than double through the C bindings. Thanks to Tomas Lindquist
Olsen for reporting it.
llvm-svn: 46656
2008-02-02 01:07:50 +00:00
Gordon Henriksen
097102c32a
Adding C bindings for SwitchInst::addCase.
...
Patch by Bryan O'Sullivan!
llvm-svn: 45481
2008-01-01 05:50:53 +00:00
Gordon Henriksen
4a4d73519e
Add some doxygen comments to llvm-c/Core.h.
...
llvm-svn: 45450
2007-12-30 17:46:33 +00:00
Gordon Henriksen
1158c533f7
Bindings for instruction calling conventions.
...
llvm-svn: 45422
2007-12-29 20:45:00 +00:00