Commit graph

192 commits

Author SHA1 Message Date
Alexey Prokhin
adebe4c732 DMD Issue 4269 - Regression(2.031): invalid type accepted if evaluated while errors are gagged 2012-02-15 13:23:23 +04:00
Alexey Prokhin
f2ed2e96b0 Use optimized array operators implemented in druntime 2012-02-15 13:16:34 +04:00
Alexey Prokhin
dbb6528c95 Fixed #54 — Error: invalid cast from 'typeof(null)' to 'void*' 2012-01-09 15:14:05 +04:00
Alexey Prokhin
eb6809a530 Fixed #41 — Casting Associative Arrays To Immutable 2011-12-09 12:22:12 +04:00
Alexey Prokhin
bb3908f290 Fixed #36 — ICE: DValue::getLVal(): Assertion '0' failed 2011-12-05 13:19:33 +04:00
David Nadlinger
3916835380 Merge remote-tracking branch 'AlexeyProkhin/master' into merge-3.0
Conflicts:
	CMakeLists.txt
	druntime
	runtime/CMakeLists.txt
2011-12-04 18:38:09 +01:00
David Nadlinger
fe19ee84f5 Merge branch 'llvm3.0' into merge-3.0
Conflicts:
	gen/configfile.cpp
2011-12-04 18:16:36 +01:00
David Nadlinger
d0ea856024 Emit all D inline asm labels as local labels.
On OS X, there is an actual significance to the distinction, which before lead e.g. to exception throwing in the below example being broken:

---
import core.exception;

void main() {
  asm {
    jmp Lfoo;
Lfoo:
    ;
  }
  throw cast(OutOfMemoryError)cast(void*)OutOfMemoryError.classinfo.init;
  assert(0);
}
---
2011-12-04 18:13:33 +01:00
Alexey Prokhin
784e3f1542 Fixed cases when debug info of a variable was emitted several times 2011-12-04 15:34:41 +04:00
Alexey Prokhin
91f4e5d015 Added emission of dwarf lexical blocks.
Also, dropped support for DISABLE_DEBUG_INFO definition.
2011-12-04 15:34:35 +04:00
Alexey Prokhin
b8721a8515 Emit debug info for variables that are used in nested functions 2011-12-03 23:45:58 +04:00
kai
a5b3dd29b5 Fixes 2 kinds of warnings.
1) The last parameter of getGetElementPtr() has type bool. In some instances, a 2 is used as parameter. This is converted to true.
2) Several loops use int instead of unsigned. This causes warning about signed/unsigned mismatch.

Curiously, only Visual C++ complains about this. Nevertheless I think that the warnings should be fixed.
2011-11-23 19:01:04 +01:00
Alexey Prokhin
7431d58702 Rewritten initialization of global variables. 2011-10-25 15:43:49 +04:00
Alexey Prokhin
629f13929e WIP: port to llvm 3.0 2011-10-25 15:43:39 +04:00
Alexey Prokhin
9a9999854f Named Return Value Optimization 2011-09-13 21:01:38 +04:00
Alexey Prokhin
0caba6672d Call postblit on a struct when appending it to an array. Use _d_arraycatnT to concatenate multiple arrays.
Before, _d_arraycatT was used to concatenate multiple arrays. That caused an issue when postblit
was called on a struct multiple times. The next code asserted due to the issue:

void main()
{
    static struct S
    {
        int x;
        int pad;
        this(this)
        {
            ++x;
        }
    }

    auto sarr = new S[1];
    auto sarr2 = sarr ~ sarr ~ sarr;
    assert(sarr2[0].x == 1);
    assert(sarr2[1].x == 1);
    assert(sarr2[2].x == 1);
    assert(sarr[0].x == 0);
}
2011-09-10 13:22:05 +04:00
Alexey Prokhin
2cc34c4005 Call desctructors on temporary variables 2011-07-19 19:20:42 +04:00
Alexey Prokhin
4210f4285a Fixed a few interpret regressions 2011-07-19 10:14:11 +04:00
Alexey Prokhin
462cdda4ae Merge dmdfe 2.053beta 2011-07-19 10:14:04 +04:00
David Nadlinger
7a24e12736 Cleanup: Remove unused code in backend, silence some warnings.
This removed quite some clutter that has presumably piled up because LDC is seldom built with a lot of warnings enabled due to DMDFE.
2011-04-24 12:21:33 +02:00
Alexey Prokhin
12984d9cc7 Fix size of classes 2011-02-25 22:28:59 +03:00
Alexey Prokhin
e921998d75 A few fixes for 64bit 2011-02-23 12:49:57 +03:00
Alexey Prokhin
aa5dfdfd4d Fix casting of associative arrays 2011-02-20 19:00:54 +03:00
Alexey Prokhin
c5e9784863 Updated to dmdfe 2.051 2011-01-05 18:21:40 +03:00
Alexey Prokhin
b52cedf6d2 Add another stub to DtoInitializer() 2011-01-03 20:46:23 +03:00
Alexey Prokhin
38b4b4569b Fixed structs assign 2011-01-03 16:50:08 +03:00
Alexey Prokhin
910c589b79 Handle wild modifier in stripModifiers() 2011-01-03 16:50:08 +03:00
Alexey Prokhin
d8115713d2 Fixed initialization of multidimensional static arrays. 2010-12-30 14:04:24 +03:00
Alexey Prokhin
023b55a772 Run postblit constructors for elements of an array. 2010-12-30 14:04:24 +03:00
Alexey Prokhin
44593f6220 Call d_delarray_t() instead of _d_delarray() 2010-12-19 15:51:00 +03:00
Alexey Prokhin
8c0902ce21 Fixed assert when compiling inline test 2010-12-17 12:54:34 +03:00
Alexey Prokhin
71f653f19b Fixes for closures 2010-12-15 17:05:16 +03:00
Alexey Prokhin
3eb6b5e8c8 Fixed a crash when compiling test runnable/A16. 2010-12-14 14:35:52 +03:00
Alexey Prokhin
c3ea7b27c6 Work on debug 2010-12-14 14:35:48 +03:00
Alexey Prokhin
0cc3dc369a Fixed signature of _d_delarray() 2010-11-02 20:30:06 +03:00
Alexey Prokhin
360a99caa9 Resolving nested context for structs.
* * *
Another fix for nested structs
* * *
Yet another fix for nested structs
2010-11-02 13:21:36 +03:00
Alexey Prokhin
2fe6817294 Fixed a druntime crash in _d_delclass 2010-10-31 12:23:35 +03:00
Alexey Prokhin
d0c7a5a3cb Ported to new debug information format introduced in llvm 2.7 2010-10-30 20:57:32 +04:00
Alexey Prokhin
e4c3179d43 Different fixes: phobos compiles now 2010-10-28 14:53:01 +04:00
Alexey Prokhin
b1e5993873 Started work on phobos 2010-10-27 18:13:46 +04:00
Alexey Prokhin
4d7a6eda23 Different fixes for d2 2010-10-07 22:35:32 +04:00
Alexey Prokhin
df87607ba2 Updated to 2.049 2010-09-30 21:54:45 +04: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
Kelly Wilson
b38845e88e Apply patch from klickverbot. This is his 'proper fix' patch for bug #395. 2010-03-08 23:37:40 -07:00
Christian Kamm
57630ea48b Make ref vars work with nesting. 2009-11-07 14:06:11 +01:00
Christian Kamm
4e2e4d5b3d Fix codegen for foreach with ref value being lowered to for. 2009-11-07 13:51:05 +01: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
4c5457ba61 getNullValue is in Constant again
Requires LLVM >= r77721
2009-07-31 23:01:29 +02:00
Benjamin Kramer
66101517d7 LLVMContext changes up to r77366 2009-07-30 15:25:10 +02:00
Benjamin Kramer
a31f3eb98f getClosestStaticTargetForModule was replaced with lookupTarget
Build fix for LLVM r77111.
2009-07-28 15:26:21 +02:00