Commit graph

29 commits

Author SHA1 Message Date
kai
b8692b94f8 Fix the non-LLVM 3.5 builds 2014-03-10 12:29:31 +01:00
kai
bc0788deac Fix DataLayout changes in LLVM 3.5.
DataLayout must now be a pointer because it can be null.
2014-03-10 06:50:03 +01:00
Kai Nacke
a39e5582e6 DLL linkage is decoupled from linkage in LLVM 3.5. 2014-01-19 11:02:27 +01:00
Kai Nacke
74630ed7f1 Simplify LLVM passes.
Use a typedef to minimize difference between LLVM 3.1 and Â3.2+.
Use IRBuilder method CreateMemCpy.
2013-12-16 15:00:00 +01:00
David Nadlinger
1f59740524 _d_allocclass -> "_d_newclass".
The define is a leftover from the times when we supported
both D1 and D2.
2013-10-24 00:25:36 +02:00
David Nadlinger
0a96aea868 Sort includes according to style guidelines:
1. Main include corresponding to .cpp file, if any.
 2. DMD and LDC includes.
 3. LLVM includes.
 4. System includes.

Also updated a few include guards to match the default format.
2013-02-07 21:20:55 +01:00
kai
a11459bc31 "The Great Renaming" continues.
More changes to match the renamed files of LLVM 3.3.
2013-01-06 17:17:30 +01:00
kai
272e7b7a55 Follow "The Great Renaming" in LLVM 3.3
This time VMCore was renamed to IR. Several top level include
files were moved to new subfolder IR.
2013-01-03 08:52:23 +01:00
David Nadlinger
9458911839 Added LLVM-style license headers to all our files. 2012-12-16 17:19:14 +01:00
kai
a7c7b514c0 Add changes for LLVM 3.2
- The Attributes class was changed again
- TargetData was renamed to DataLayout

Compiles again with LLVm 3.0, 3.1 and trunk(3.2).
2012-10-13 18:54:42 +02:00
kai
dbb5a34eda Add changes for LLVM 3.2. 2012-07-29 17:31:50 +02:00
Alexey Prokhin
629f13929e WIP: port to llvm 3.0 2011-10-25 15:43:39 +04:00
Robert Clipsham
2234264acf Merged klickverbot's off-by-one fixes for D optimisation passes. Thanks. 2011-01-05 23:39:32 +00:00
Kelly Wilson
11cbacf9da Fix for ticket #440 by klickverbot. Thx. 2011-01-02 00:42:10 -05:00
Alexey Prokhin
4d7a6eda23 Different fixes for d2 2010-10-07 22:35:32 +04:00
Moritz Warning
c151d37365 fixes #434 :: add llvm 2.8 support 2010-10-23 13:38:26 +02:00
Tomas Lindquist Olsen
1fac40d2bd Update to work with LLVM 2.7.
Removed use of dyn_cast, llvm no compiles
without exceptions and rtti by
default. We do need exceptions for the libconfig stuff, but rtti isn't
necessary (anymore).

Debug info needs to be rewritten, as in LLVM 2.7 the format has
completely changed. To have something to look at while rewriting, the
old code has been wrapped inside #ifndef DISABLE_DEBUG_INFO , this means
that you have to define this to compile at the moment.

Updated tango 0.99.9 patch to include updated EH runtime code, which is
needed for LLVM 2.7 as well.
2010-05-19 12:42:32 +02:00
Benjamin Kramer
c220dcac05 IntegerType is now contextifed.
Requires llvm >= 78969. resistor says this will be the last context API change :)
2009-08-14 00:39:18 +02:00
Benjamin Kramer
66101517d7 LLVMContext changes up to r77366 2009-07-30 15:25:10 +02:00
Benjamin Kramer
3f0a0686a8 Value::getNameStart and Value::getNameLength were removed 2009-07-23 20:34:35 +02:00
Benjamin Kramer
27a9f93767 DOUT is deprecated, use DEBUG(errs()) instead 2009-07-27 11:44:01 +02:00
Benjamin Kramer
d7049de966 More factory methods moved to LLVMContext 2009-07-15 18:09:41 +02:00
Benjamin Kramer
0ee2f34611 Don't use llvm::getGlobalContext() anymore 2009-07-13 20:16:15 +02:00
Christian Kamm
756a2cb2a1 Adjust LDC to work with the LLVMContext LLVM changes.
This means we now require a fairly new LLVM revision. I use 75234.
2009-07-10 21:30:02 +02:00
Frits van Bommel
5ecdf1a70a Eliminate comparisons between GC allocations and constants. This removes some
`assert(this !is null)`s when member functions get inlined.

Also tweak pass order a bit.
2009-06-20 14:28:59 +02:00
Frits van Bommel
d1f582583b Turn new _d_array_slice_copy runtime call into memcpy when the slice lengths are
equal and alias analysis says it's safe.
2009-05-10 04:18:14 +02:00
Frits van Bommel
634d623b34 Some tweaks to -simplify-drtcalls. 2009-05-09 02:34:27 +02:00
Frits van Bommel
34955bcbf9 Remove calls to some runtime functions if their results are unused 2009-05-02 11:58:50 +02:00
Frits van Bommel
0df1e34eb2 Implement first D-specific optimization pass: -simplify-drtcalls.
It uses the machinery of the standard -simplify-libcalls pass, but optimizes
calls to the D runtime instead of calls to C libraries.

At the moment, these optimizations are implemented by this pass:
 - Avoid the runtime call for `arr.length = newlen` if it can determine that
   the new length isn't longer than the old one.
 - Ditto for `cast(T[]) arr` if it will clearly always succeed.
   (e.g. if the length of the original array is zero, or if the old element
   size is a multiple of the new element size)
2009-04-28 21:58:06 +02:00