Tomas Lindquist Olsen
6861e4504f
Updated Tango 0.99.9 patch!
2010-10-23 21:08:11 +02:00
Tomas Lindquist Olsen
db0afdf3e0
Updated CMake building for 2.7 update.
2010-05-19 22:33:03 +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
Tomas Lindquist Olsen
0db459fad0
Updated C binding to be more up to date with LLVM.
2009-10-22 13:30:30 +02:00
Tomas Lindquist Olsen
84a319ad23
Fixed issue in exception runtime with recent LLVM revisions, with this in place EH seems to work properly on x86-64. These fixes need to be merged into tango trunk still!
2009-10-21 05:46:56 +02:00
Tomas Lindquist Olsen
de0d74dc68
Forgot to add files.
2009-08-06 17:04:36 +02:00
Tomas Lindquist Olsen
84f820b442
Added framework for writing a static printf call checker for bearophile to implement.
2009-08-06 16:52:43 +02:00
Tomas Lindquist Olsen
d52ea51df4
Added check and error in case two same named modules - with different packages and compiled at once - would overwrite each other's output files.
2009-08-02 18:37:07 +02:00
Tomas Lindquist Olsen
df82d09206
Fixed bug #349 , now emits error.
2009-08-02 17:56:30 +02:00
Tomas Lindquist Olsen
c69e5a5c83
Fixed compiling with llvm rev > 77732
2009-08-01 18:23:52 +02:00
Tomas Lindquist Olsen
d5d3ecdb05
Added back option to disable metadata generation and users. Set USE_METADATA to OFF in ccmake.
2009-07-31 11:28:31 +02:00
Tomas Lindquist Olsen
b7b671ce48
Disable metadata for typeid(void).
2009-07-31 01:44:47 +02:00
Tomas Lindquist Olsen
3cf7b6a95c
Fixed potential crash with complex recursive struct types.
2009-07-26 19:12:37 +02:00
Tomas Lindquist Olsen
e31957dcd8
Change the frontend generated assert(this) or assert(&this) in D2 to set the ThisExp::var field.
2009-06-03 13:11:01 +02:00
Tomas Lindquist Olsen
062b6d93c4
Make sure typeinfo output are mutable types, this is a temporary workaround to get druntime genobj.d to compile until we figure out what typeinfos are actually needed here and there ...
2009-06-03 04:12:28 +02:00
Tomas Lindquist Olsen
b218bfc828
Added missing initializer of (LDC introduced) Expression::cachedLvalue in D2 frontend.
2009-06-03 03:49:24 +02:00
Tomas Lindquist Olsen
092381577f
Some minor changes to handling of variables referenced from nested functions in D2 .
...
Added generation of new 'void*[4] reserved;' !ModuleInfo member .
2009-06-03 03:04:47 +02:00
Tomas Lindquist Olsen
f6997cb604
D2:
...
Applied function type from D1 frontend that got removed in D2, it's critical for member function type to be correct.
Fixed a bunch of type discrepancies in druntime object.di vs. genobj.d .
Disabled (#if 0) some potentally very large type dumps for -vv .
Updated classinfo and typeinfo generation for D2, almost complete now.
Added finer grained checks for vtbl type mismatching, aids debugging.
2009-06-03 02:28:48 +02:00
Tomas Lindquist Olsen
f733680251
Try to cut down reallocations when building string literals.
2009-05-18 16:01:22 +02:00
Tomas Lindquist Olsen
152db286c0
Added a comment to the ldc.conf.in template about the %%ldcbinarydir%% "macro".
2009-05-18 15:08:46 +02:00
Tomas Lindquist Olsen
be25445461
Added simple check for ClassInfo change introduced in DMD 1.045, it must have 12 fields.
2009-05-17 23:15:04 +02:00
Tomas Lindquist Olsen
0b8413b4bc
Fixed class -> integer casts.
2009-05-17 22:02:03 +02:00
Tomas Lindquist Olsen
2690f3cfd8
Add debug info for all class fields, including those from super classes...
2009-05-17 17:55:53 +02:00
Tomas Lindquist Olsen
e2ba08388f
Added new FreeBSD and Solaris predefined version identifiers.
2009-05-17 17:10:26 +02:00
Tomas Lindquist Olsen
b64ad3299e
Use RTTIBuilder to build !ModuleInfo, still needs some work.
2009-05-17 17:04:47 +02:00
Tomas Lindquist Olsen
3e4ade93ba
Updated comment in RTTIBuilder.h
2009-05-17 16:31:23 +02:00
Tomas Lindquist Olsen
b1fa43ce24
Increased RTTIBuilder buffer to 14 constants, to be big enough for !ClassInfo as well as !TypeInfo
2009-05-17 16:29:49 +02:00
Tomas Lindquist Olsen
dc4b7e8118
Update !ClassInfo generation to use !RTTIBuilder, slight update of !RTTIBuilder .
2009-05-17 16:27:01 +02:00
Tomas Lindquist Olsen
b6daf3d545
Renamed !TypeInfoBuilder to !RTTIBuilder.
2009-05-17 15:20:58 +02:00
Tomas Lindquist Olsen
0414a5acbb
Fixed filename in array bounds check for mixed in imported template function. Fixes ticket #295 .
2009-05-17 14:56:29 +02:00
Tomas Lindquist Olsen
9be5694168
Added error messages when failed to open files for .bc and .ll output, instead of just trying to write to the stream, pretty similar to the #281 problem.
2009-05-17 14:40:09 +02:00
Tomas Lindquist Olsen
0a77bd9fa6
Add error message when failed to open output stream for native asm output. Fixes ticket #281 .
2009-05-17 14:20:27 +02:00
Tomas Lindquist Olsen
5078019c54
Cleaned up TypeInfo_Tuple generation.
2009-05-17 05:07:51 +02:00
Tomas Lindquist Olsen
d80de9deb3
Cleaned up TypeInfo_Struct.
...
Fixed problem with DtoConstSize_t taking a size_t argument, this is not enough for cross compiling from 32bit host to a 64bit target. It now takes uint64_t. There's probably a lot of similar case around to code ...
2009-05-17 04:41:10 +02:00
Tomas Lindquist Olsen
f3c7278e88
Cleaned up TypeInfo generation, still need to do TypeInfo_Struct/Tuple. Eventually do ClassInfo and ModuleInfo as well using same interface.
2009-05-17 03:10:55 +02:00
Tomas Lindquist Olsen
b87acdc36f
Updated DMDFE version id from 1.042 to 1.045 ...
2009-05-16 22:27:31 +02:00
Tomas Lindquist Olsen
6633d696c9
Forgot to set the (ClassInfo.flags & 32) bit added in 1.045.
2009-05-16 22:24:49 +02:00
Tomas Lindquist Olsen
e8780d50e8
Merged DMD 1.045 !!!
2009-05-16 22:21:31 +02:00
Tomas Lindquist Olsen
9beb33770f
Fixed previous aggregate initZ alignment.
...
Added missing IrType::isDelegate method.
2009-05-16 18:37:16 +02:00
Tomas Lindquist Olsen
2e33a6af9f
Added explicit alignment for aggregate __initZ symbols, this is needed for some union types, or the default initializer symbol might be misaligned.
2009-05-16 18:25:01 +02:00
Tomas Lindquist Olsen
c0f2af5afd
Added IrTypeFunction and IrTypeDelegate and eliminated IrDType. This means the Type::ir field can be removed. It's the final part needed for the move to a slightly more sane type system. Now the whole thing just needs to be cleaned up :P
...
Added -v-cg switch, which right now just prints "codegen: module.name (module/name.d)" to stdout, this can really help figuring out where, in some complex build command, things go wrong.
2009-05-16 18:19:52 +02:00
Tomas Lindquist Olsen
62e8384da0
Set explicit alignment for normal global variables, ensures alignment is correct for globals with union type.
2009-05-15 17:17:20 +02:00
Tomas Lindquist Olsen
0680e6a3ca
Enabled fix for ticket #294 . It will try it's best to let LLVM handle the alignment, and fall back to manual padding when that's not possible. If this causes problems again, we'll have to consistently pad manually using packed structs.
2009-05-15 17:05:35 +02:00
Tomas Lindquist Olsen
ad142b5fda
Erm... Revert the rev [1352] change, the original code was correct ...
2009-05-15 15:30:59 +02:00
Tomas Lindquist Olsen
a0678dc9ec
Oups, fix assertion condition in disabled code from rev [1351].
2009-05-14 17:23:55 +02:00
Tomas Lindquist Olsen
b147ecc66d
Initial (but disabled) fix for ticket #294 , the actual part that fixes the bug is in a #if 0 block as I'm afraid it will cause regressions. I'm most likely not going to be around tonight, and maybe not tomorrow as well, so I'm pushing it in case someone wants to run some serious testing/investigate the problem noted in llvmhelpers.cpp : realignOffset .
2009-05-14 17:20:17 +02:00
Tomas Lindquist Olsen
f5d635dfc7
Adds explicit alignment information for alloca instructions in general, there's a few cases that still needs to be looked at but this should catch the majority. Fixes ticket #293 .
2009-05-14 13:26:40 +02:00
Tomas Lindquist Olsen
77cb1c6b8e
Added error instead of assertion failure when trying to get !TypeInfo for a forward declared struct.
2009-05-11 20:54:25 +02:00
Tomas Lindquist Olsen
3fb2cb0322
Okay... Fix the assertion as well, since 20 really is enough yet it wanted MORE... Despite the message.
2009-05-10 17:31:56 +02:00
Tomas Lindquist Olsen
0ab77de246
Increased a buffer size in TypeInfo_StaticArray from 10 to 20 to avoid assertion failures! Thanks LeoD.
2009-05-10 17:25:47 +02:00
Tomas Lindquist Olsen
4f59c0cb7b
Removed fix from rev [1331] since rev [1333] adds a more general fix that catches more cases!
2009-05-10 15:50:51 +02:00
Tomas Lindquist Olsen
ea00a120e9
Added testcase for #288 .
2009-05-10 14:37:30 +02:00
Tomas Lindquist Olsen
c6dca3fb76
Fixed CTFE evaluation on .dup . Fixes ticket #288 .
2009-05-10 14:32:23 +02:00
Tomas Lindquist Olsen
dbe4852b7b
Fixed D-style vararg arguments with types that have sizes bigger that pointers, yet are not aligned to pointer sizes. Fixes ticket #276 .
2009-05-10 04:37:03 +02:00
Tomas Lindquist Olsen
dfea022a86
Changed array slice copying to call a runtime function when assertions or array bound checks are enabled instead of just doing a memcpy. This makes sure an exception is thrown if the copy is invalid (ie. different lengths or overlap). Fixes ticket #283 . Rebuilding the runtime is necessary.
2009-05-10 02:23:05 +02:00
Tomas Lindquist Olsen
54d9955abc
Added reference to DMD bug for latest dstress "regressions" compile/m/mixin_29_E.d and compile/m/mixin_29_F.d .
2009-05-10 00:50:35 +02:00
Tomas Lindquist Olsen
ecc106d7b7
Fixed dmdfe generated class invariant calls. Also insert proper "this !is null" check before it. Fixed invariant* dstress regressions and generally seems like a good idea. Hope I didn't break anything.. minitests run fine!
2009-05-10 00:46:09 +02:00
Tomas Lindquist Olsen
3aeb56abec
Fixed compile unit for debug info for array operations, fixed ticket #280 .
2009-05-09 15:27:27 +02:00
Tomas Lindquist Olsen
ca4f588c08
Fixed deal breaker bug for more-at-once compilation when any module contained aggregates. Fixes ticket #272 .
2009-05-07 02:10:29 +02:00
Tomas Lindquist Olsen
ca39bb4f4d
Fixed array operation codegen when used from imported templates. All array operations are now emitted with template linkage. Fixed #270 .
2009-04-29 18:59:39 +02:00
Tomas Lindquist Olsen
617861ead4
Fixed file name in imported mixins containing assertions.
2009-04-29 18:39:59 +02:00
Tomas Lindquist Olsen
f290ff0530
Forgot the special case part in last !ThisExp change.
2009-04-27 13:59:15 +02:00
Tomas Lindquist Olsen
95b94935ee
Moved special casing of 'assert(this, "null this");' generated statements from !ThisExp into !AssertExp.
...
Fixed filenames for array bounds errors and probably others, fixes #271 .
2009-04-27 13:30:48 +02:00
Tomas Lindquist Olsen
ba38e15f0d
Fixed class default initializers and type generation. Bug #260 is fixed.
2009-04-27 03:40:40 +02:00
Tomas Lindquist Olsen
3bd5cf70c2
Added testcase for overlapping struct default initializer I has missed. Slight tweak of the relevant error message.
2009-04-27 01:43:29 +02:00
Tomas Lindquist Olsen
73f93d7240
Merge
2009-04-25 18:27:11 +02:00
Tomas Lindquist Olsen
3e882d422b
Fixed struct default initializers.
2009-04-25 18:26:54 +02:00
Tomas Lindquist Olsen
687395cda6
Rewrote runtime struct literal codegen.
2009-04-22 03:08:28 +02:00
Tomas Lindquist Olsen
f6f12e4241
Added checks for overlapping union initializers, as shown in bug #259 .
2009-04-22 01:18:21 +02:00
Tomas Lindquist Olsen
575038bfbd
Fixed classinfo.interfaces for .. interfaces!
2009-04-21 20:19:53 +02:00
Tomas Lindquist Olsen
4567a55f7f
Fixed emitting declarations nested inside interfaces.
2009-04-21 19:32:22 +02:00
Tomas Lindquist Olsen
b3db60cbda
Merge.
2009-04-21 17:54:43 +02:00
Tomas Lindquist Olsen
134870c873
Disabled resetting types between modules MAO (more at once). Fixes guaranteed MOA compilation segfault.
2009-04-17 17:16:55 +02:00
Tomas Lindquist Olsen
36f3161803
Merge.
2009-04-17 14:48:37 +02:00
Tomas Lindquist Olsen
1c79df3817
Fixed all issues preventing Tango 0.99.8 to compile with `sh build-tango.sh --verbose ldc'.
2009-04-17 14:38:29 +02:00
Tomas Lindquist Olsen
f5ce8eda1d
Resolve all base classes, including interfaces (!) before resolving the class itself.
2009-04-17 03:01:43 +02:00
Tomas Lindquist Olsen
ea2279b11a
Updated the interal runtime's ClassInfo type to match the one in object.di .
...
Runtime now compiles and runminitest is back to normal except for typeinfo10.d .
2009-04-17 02:54:16 +02:00
Tomas Lindquist Olsen
3d9598d854
Merge with rev [1221]
2009-04-17 01:19:03 +02:00
Tomas Lindquist Olsen
c7936c2ace
!ClassInfo instances were not mutable, this is necessary for .classinfo based locking to work. !ModuleInfo generation was commented out as well.
2009-04-17 00:54:20 +02:00
Tomas Lindquist Olsen
9568616e66
Fixed static struct initializers.
2009-04-17 00:36:21 +02:00
Tomas Lindquist Olsen
803fbf4882
Make !TypeInfo output lazy unless we need to provide full definitions in general.
2009-04-16 22:20:26 +02:00
Tomas Lindquist Olsen
e01917bc0d
Make typeinfo for struct
2009-04-16 22:19:36 +02:00
Tomas Lindquist Olsen
8feabfc5c6
Make sure aggregates are resolved before outputting their debug info.
2009-04-16 21:15:42 +02:00
Tomas Lindquist Olsen
948202a1a1
Fixed ClassInfo.interfaces. mini/s.d now runs again.
2009-04-16 21:10:51 +02:00
Tomas Lindquist Olsen
0521f8075c
Too strict assertion with generating the interfaceInfosZ symbol. Baseclasses might introduce interfaces.
2009-04-16 21:00:49 +02:00
Tomas Lindquist Olsen
414e58a318
Fixed forward referenced structs.
2009-04-16 20:41:27 +02:00
Tomas Lindquist Olsen
1437bd6b7e
Merge.
2009-04-16 20:31:21 +02:00
Tomas Lindquist Olsen
02466de996
Removed invalid assertion.
2009-04-16 20:30:30 +02:00
Tomas Lindquist Olsen
9a86f9c0b5
Fixed some minitest regressions.
2009-04-16 19:21:30 +02:00
Tomas Lindquist Olsen
5db458d8da
Completed interface implementation. Hopefully that's it for now..
2009-04-16 13:18:56 +02:00
Tomas Lindquist Olsen
bb98d68f64
Now compiles again, and fixed type of the Interface[N] ClassInfo symbol.
2009-04-16 11:01:49 +02:00
Tomas Lindquist Olsen
37cf5a5789
Added Doxygen file.
...
Completely seperated type and symbol generation. Should fix a lot of bugs, but is not yet 100% complete.
2009-04-15 20:06:25 +02:00
Tomas Lindquist Olsen
3d1f8cc565
Merged DMD 1.042.
2009-04-03 17:59:34 +02:00
Tomas Lindquist Olsen
57bf95cb42
Moved some DMDFE files into a seperate dmd/root subdir to closer match the DMD file structure since 1.041.
2009-04-03 17:02:52 +02:00
Tomas Lindquist Olsen
9c4b2b4036
Started seperating type resolution from the rest of codegen again, the merge had too many regressions.
2009-04-03 16:34:11 +02:00
Tomas Lindquist Olsen
4df1f9be35
updated ir/irtype.h guard name
2009-04-03 14:54:17 +02:00
Tomas Lindquist Olsen
c6e9f7f9e2
Moved ir/irtype.* into ir/irdtype.*.
...
Renamed IrType to IrDType, analogous to IrDSymbol.
2009-03-31 20:21:28 +02:00
Tomas Lindquist Olsen
14b8aff809
Fixed issue with runtime supplied typeinfo generating multiple symbols.
...
Added new ldc.llvmasm import in runtime cmake file.
2009-03-28 09:45:33 +01:00
Tomas Lindquist Olsen
740cdaa588
Fixed forward reference problem in struct methods on x86-64.
2009-03-28 09:00:32 +01:00
Tomas Lindquist Olsen
e61562033d
Added support for tuple return with __asmtuple!(int,int) etc.
2009-03-28 08:25:58 +01:00