Mercurial > projects > ldc
annotate gen/classes.h @ 1650:40bd4a0d4870
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.
author | Tomas Lindquist Olsen |
---|---|
date | Wed, 19 May 2010 12:42:32 +0200 |
parents | 5d0c043ff131 |
children |
rev | line source |
---|---|
664
eef8ac26c66c
Some missed LLVMDC -> LDC.
Christian Kamm <kamm incasoftware de>
parents:
486
diff
changeset
|
1 #ifndef LDC_GEN_CLASSES_H |
eef8ac26c66c
Some missed LLVMDC -> LDC.
Christian Kamm <kamm incasoftware de>
parents:
486
diff
changeset
|
2 #define LDC_GEN_CLASSES_H |
100 | 3 |
217
0806379a5eca
[svn r233] Added: -oq command line option for writing fully qualified object names.
lindquist
parents:
213
diff
changeset
|
4 #include "gen/structs.h" |
0806379a5eca
[svn r233] Added: -oq command line option for writing fully qualified object names.
lindquist
parents:
213
diff
changeset
|
5 |
1228
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
6 /// Resolves the llvm type for a class declaration |
102
027b8d8b71ec
[svn r106] Turns out the last commit wasn't enough, now the D->LLVM process is even more split up.
lindquist
parents:
100
diff
changeset
|
7 void DtoResolveClass(ClassDeclaration* cd); |
027b8d8b71ec
[svn r106] Turns out the last commit wasn't enough, now the D->LLVM process is even more split up.
lindquist
parents:
100
diff
changeset
|
8 |
1228
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
9 /// Provides the llvm declaration for a class declaration |
100 | 10 void DtoDeclareClass(ClassDeclaration* cd); |
11 | |
1228
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
12 /// Constructs the constant initializer for a class declaration |
100 | 13 void DtoConstInitClass(ClassDeclaration* cd); |
14 | |
1228
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
15 /// Provides the llvm definition for a class declaration |
100 | 16 void DtoDefineClass(ClassDeclaration* cd); |
17 | |
1228
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
18 /// Builds the initializer of cd's ClassInfo. |
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
19 /// FIXME: this should be put into IrStruct and eventually IrClass. |
79758fd2f48a
Added Doxygen file.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
705
diff
changeset
|
20 LLConstant* DtoDefineClassInfo(ClassDeclaration* cd); |
100 | 21 |
486
a34078905d01
Added pragma(llvmdc, "string") for misc per-module compiler configuration, currently "string" can only be "verbose" which forces -vv for module it appears in.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
217
diff
changeset
|
22 DValue* DtoNewClass(Loc loc, TypeClass* type, NewExp* newexp); |
213
7816aafeea3c
[svn r229] Updated the object.d implementation to the latest Tango.
lindquist
parents:
210
diff
changeset
|
23 void DtoInitClass(TypeClass* tc, LLValue* dst); |
7816aafeea3c
[svn r229] Updated the object.d implementation to the latest Tango.
lindquist
parents:
210
diff
changeset
|
24 DValue* DtoCallClassCtor(TypeClass* type, CtorDeclaration* ctor, Array* arguments, LLValue* mem); |
7816aafeea3c
[svn r229] Updated the object.d implementation to the latest Tango.
lindquist
parents:
210
diff
changeset
|
25 void DtoFinalizeClass(LLValue* inst); |
100 | 26 |
114 | 27 DValue* DtoCastClass(DValue* val, Type* to); |
28 DValue* DtoDynamicCastObject(DValue* val, Type* to); | |
133
44a95ac7368a
[svn r137] Many fixes towards tango.io.Console working, but not quite there yet...
lindquist
parents:
132
diff
changeset
|
29 |
114 | 30 DValue* DtoCastInterfaceToObject(DValue* val, Type* to); |
133
44a95ac7368a
[svn r137] Many fixes towards tango.io.Console working, but not quite there yet...
lindquist
parents:
132
diff
changeset
|
31 DValue* DtoDynamicCastInterface(DValue* val, Type* to); |
113
27b9f749d9fe
[svn r117] Initial working implementation of interfaces.
lindquist
parents:
102
diff
changeset
|
32 |
705
5a2983f97498
Fixed weird struct problem from downs, see mini/compile_structs1.d
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
664
diff
changeset
|
33 LLValue* DtoIndexClass(LLValue* src, ClassDeclaration* sd, VarDeclaration* vd); |
132 | 34 |
1434
5d0c043ff131
Remove code duplication for vtable loads and improve instruction naming to make
Frits van Bommel <fvbommel wxs.nl>
parents:
1228
diff
changeset
|
35 LLValue* DtoVirtualFunctionPointer(DValue* inst, FuncDeclaration* fdecl, char* name); |
133
44a95ac7368a
[svn r137] Many fixes towards tango.io.Console working, but not quite there yet...
lindquist
parents:
132
diff
changeset
|
36 |
100 | 37 #endif |