Kai Nacke
382ad184d8
Merge branch 'master' into merge-2.066
...
Conflicts:
dmd2/builtin.c
gen/classes.cpp
gen/functions.cpp
gen/llvmhelpers.cpp
gen/statements.cpp
gen/toir.cpp
runtime/druntime
runtime/phobos
2014-09-13 23:11:54 +02:00
David Nadlinger
5370f52e8a
[cleanup] Remove stale debug output statements.
2014-09-13 20:58:05 +02:00
David Nadlinger
42f5ea7cbb
[cleanup] Don't check global.params.useUnitTests twice.
2014-09-13 20:58:02 +02:00
Alexey Prokhin
960d84508b
[Refactoring] Turn IrDsymbol flags into an enum value
2014-09-12 16:27:13 +04:00
Alexey Prokhin
32b1d4cc55
Reduce size of IrDsymbol even more
...
resolved/defined/declared/initialized are turned into flags.
2014-09-12 14:43:54 +04:00
Alexey Prokhin
18f33b1815
Make IrDsymbol to be a typesafe union to reduce memory usage
2014-09-12 14:43:49 +04:00
Alexey Prokhin
5b15095c81
IrDsymbol::DModule is not used
2014-09-11 18:52:27 +04:00
kai
b8a75be61c
Use LLVM intrinsic name as mangled name.
...
If the mangled name is viewed as the name emitted into IR code then the mangled name of an intrinsic is the intrinsic's name.
The name is unique because of the `llvm.` prefix. The only point is that overloaded intrinsics must be resolved earlier.
This commit moves the resolution of oveloaded intrinsics into the semantic analysis pass. The
2014-08-29 08:05:09 +02:00
Alexey Prokhin
d9189acbc4
Move toElem/toConstElem to visitors
2014-08-27 16:22:02 +04:00
Alexey Prokhin
ce1a41305b
Set enclosingScopeExit in glue layer after semantic is done
...
Otherwise, we may end up with a wrong enclosing statement. It could
happen if a try-finally is rewritten as a try-catch (see NrvoWalker).
In this case, enclosingScopeExit will still point to the old unused
try-finally.
2014-08-24 13:59:18 +04:00
kai
2d49563ade
Fix typo
2014-08-23 20:30:43 +02:00
kai
aa35307f54
Fix LLVM 3.6 build
2014-08-23 20:02:43 +02:00
Alexey Prokhin
76dec46df5
WIP: merge dmdfe 2.066
2014-08-22 16:01:28 +04:00
Alexey Prokhin
a6f358c59b
Remove LINKintrisic
2014-07-10 18:10:46 +04:00
Alexey Prokhin
4555af39fa
Fix assert in DtoDefineFunction()
2014-07-10 15:50:44 +04:00
David Nadlinger
b0ff0de9c1
Make function entry basic blocks unnamed.
...
The performance impact should be completely immeasurable,
but the main benefit is that this makes IR dumps slightly
nicer to look at (as the redundant "empty:" labels are
now omitted entirely).
2014-06-29 16:47:44 +02:00
Alexey Prokhin
7597808a2d
Ignore nested functions with a parent that had errors during semantic3.
2014-06-27 18:27:05 +04:00
Alexey Prokhin
61110e3ea4
Fix crash in runnable/arrayop
2014-06-26 19:47:21 +04:00
kai
2b6dbb03f4
Add IF_LOG to more logging statements.
...
Evaluating arguments which call toChars() or toPrettyChars() are much more expensive then checking Logger::enabled().
2014-06-26 06:54:38 +02:00
kai
ecd59cbb77
Fix compilation error
2014-06-23 18:02:14 +02:00
kai
b7615f6a28
Merge branch 'master' into merge-2.065
...
Conflicts:
dmd2/declaration.h
dmd2/dsymbol.h
dmd2/func.c
gen/functions.cpp
gen/toir.cpp
runtime/druntime
2014-06-23 07:57:30 +02:00
kai
7c289fd673
Introduce needsCodegen.
...
This is a backport of the code from 2.065.
2014-06-19 13:20:28 +02:00
Kai Nacke
09da15be0f
Merge branch 'merge-2.064' into merge-2.065
2014-06-16 07:30:31 +02:00
kai
bef0a62622
Merge branch 'master' into merge-2.064
2014-06-15 14:07:58 +02:00
Christian Kamm
bb46ac8758
doc: Fix description of when template function instances are skipped.
2014-06-14 14:22:43 +02:00
kai
5372e57595
Fix for issue #624
2014-06-13 14:08:27 +02:00
kai
f8a53ab3dc
Merge branch 'merge-2.064' into merge-2.065
...
Conflicts:
runtime/druntime
2014-03-12 18:27:43 +01:00
kai
2f2fa92df3
Fix includes for LLVM 3.5
2014-03-07 06:40:39 +01:00
Kai Nacke
fe39da53e3
Merge of 2.065.0-b3.
...
The new visitor class is used for IR generation. This removes some modifications from DMD source.
2014-02-10 08:47:25 +01:00
Kai Nacke
4006fbbd85
Merge branch 'master' into merge-2.064
2014-01-19 13:43:15 +01:00
Kai Nacke
49599f71e9
Add sanitizer attributes.
...
If the sanitizer is enabled (e.g. -sanitize=address) then the corresponding
attribute (e.g. llvm::Attribute::SanitizerAddress) must be set.
2014-01-19 13:03:37 +01:00
Kai Nacke
680568bb62
Merge branch 'master' into merge-2.064
2014-01-12 11:53:00 +01:00
Kai Nacke
b4b71e6c79
Fix include for LLVM 3.5
2014-01-12 11:37:52 +01:00
Kai Nacke
1463f4a275
Merge branch 'master' into merge-2.064
2014-01-06 11:24:03 +01:00
Jernej Krempuš
7436d94e09
Fixed a bug in DtoInlineIR
...
Before this fix, debug info was removed from the module while
parsing inline ir.
2014-01-06 01:27:26 +01:00
Kai Nacke
731f2a8fdf
Merge branch 'master' into merge-2.064
...
Conflicts:
dmd2/root/rmem.c
2014-01-03 15:56:01 +01:00
Kai Nacke
9b4a70c367
Use caching in DtoVaFunctionType.
...
Remove now unused method IrFuncTy.reset().
2014-01-03 15:14:39 +01:00
Kai Nacke
87006d0a5b
Merge branch 'master' into merge-2.064
2014-01-03 13:54:10 +01:00
Kai Nacke
551bce6d18
Change location of assign to irFty.
...
If the comment about this function is still right (can be called recursively) then the assignment
to irFty should be done after all functions are called.
Takes advantage of move assignment, too.
2014-01-03 13:14:12 +01:00
Kai Nacke
58aadf88ef
Merge branch 'master' into merge-2.064
2014-01-02 20:31:28 +01:00
Kai Nacke
1619b18f73
Small cleanup of attribute mess.
2013-12-31 17:29:25 +01:00
Kai Nacke
c231ae0ad0
Merge remote-tracking branch 'origin/master' into merge-2.064
...
Conflicts:
gen/arrays.cpp
2013-12-19 21:27:53 +01:00
Kai Nacke
5f520fccf9
Cache result of DtoFunctionType.
2013-12-19 19:45:16 +01:00
Kai Nacke
248d3f2b66
Merge branch 'master' into merge-2.064
2013-11-05 10:47:43 +01:00
kai
6fe28e1660
Small code modifications to Ir-Classes.
...
Adds some constructors and moves the code to the header file. Uses some of the new constructors.
A big problem with the source are the different strategies used for otherwise similar classes.
E.g. a IrField registers itself with the VarDeclaration. Same is required for IrParameter, but
in this case it is done by the caller.
2013-11-05 10:31:14 +01:00
David Nadlinger
cb341586e3
First merge of 2.064 beta.
...
This corresponds to DMD commit a913ce4bc59a94a022a27e390fc841f4aededffb.
Doesn't build Phobos yet.
2013-10-29 19:21:15 +01:00
David Nadlinger
c400d180d2
Immediately exit on function type mismatch to avoid LLVM crash.
2013-10-29 19:21:14 +01:00
David Nadlinger
f67cbcda98
DtoType -> DtoFunctionType.
2013-10-29 19:21:14 +01:00
David Nadlinger
265d3ee069
Do not try to emit nested functions with unanalyzed parents.
...
GitHub: Fixes #497 .
2013-10-13 21:37:53 +02:00
David Nadlinger
4fee629c4d
Prefer more specific functions to DtoResolveDsymbol.
...
The remaining ones should also be easy to remove with a
closer look at the situation.
Ideally, we would get rid of all of them at some point and
use safe wrapper functions for accessing the IrDsymbol
associated with a given declaration (which would emit the
declarations on the fly if not already present).
2013-10-13 19:18:24 +02:00