Commit Graph
537 Commits
Author SHA1 Message Date
David Nadlinger 288fd47707 Merged 1.075 frontend. 2012-11-24 21:10:13 +01:00
kai dcff6c92c7 Conditionally add error() prototype and remove inifile().
This is alyready done in `dmd2/mars.h`.
2012-11-18 18:04:35 +01:00
David Nadlinger 60ebf5b968 Fix building against the OS X 10.8 SDK.
This is a backport of DMD commit 47bee50a39 by Justin Holewinski.

GitHub: Fixes #218.
2012-11-17 22:29:23 +01:00
David Nadlinger 34e1415f35 Merge pull request #226 from jerro/pragma-llvm-inline-ir
Pragma llvm_inline_ir
2012-11-15 12:05:17 -08:00
David Nadlinger ab94a6d60c Don't treat __ensure specially in LDC.
The only change here is commenting out the Id::ensure check,
the rest is just alignment of the code to upstream DMD.
2012-11-08 23:53:50 +01:00
Jernej Krempuš 7bbe782615 Pragma llvm_inline_ir
Adding pragma llvm_inline_ir.

Improved the error messages.

Append "ret void" when the return type is void

Improved the error message

in case when the string passed as llvm inline ir isn't valid llvm
assembly language.

LLVM 3.2 fix.

Add attribute AlwaysInline inside DtoInlineIRFunction.

Always generate a body for llvm_inline_ir

Also, always make llvm_inline_ir functions linkonce_odr. Because
the body is always generated when a module uses a llvm_inline_ir
function, the fact that the linker removes the function shouldn't
cause problems.
2012-11-08 22:05:15 +01:00
Jernej Krempuš 047dcb5591 Fixed D1 build errors. 2012-10-03 04:13:21 +02:00
David Nadlinger 165e0ef3c6 Fix typo in D1 part of 940d6e9. 2012-09-16 22:07:30 +02:00
David Nadlinger b11c49a9c9 Fix D1 build.
This applies the changes from 9a3cdf2e to dmd/ as well.
2012-09-16 22:04:39 +02:00
kai 940d6e907f Take advantage of Triple and TargetData.
A lot of system specific knowledge is already present in LLVM. This is used to populate several fields in global.params instead of hard coded values in main(). Ensures that the frontend and LLVM have always the same values.
2012-09-16 19:50:21 +02:00
kai 4b0c4bf4ae Get rid of global.params.dataLayout.
The string representation of the data layout is retrieved from the TargetData class (in main) and passed via global.params.dataLayout to the module. Since the gTargetData is also a global variable it makes no sense to pass this information using another global variable.
2012-09-08 20:25:42 +02:00
kai 4ae64dd2e7 Fix size returned by os_critsecsize() and construct type for D_CRITIAL_SECTION on Windows. 2012-09-08 11:49:37 +02:00
kai 2173b52aea Make LDC1 compile with LLVM 3.2 trunk. 2012-08-17 15:44:20 +02:00
kai 692d624db4 Make LDC1 compile again. 2012-08-17 15:34:17 +02:00
kai e6a07ffdfe Several changes to optimizer related code.
- New functions codeGenOptLevel() and verifyModule() to remove code duplication
- Hidden option no-verify renamed to disable-verify and moved to optimizer (like opt tool)
- Removed global.params.noVerify
2012-08-16 23:26:52 +02:00
kai e13b115583 More unification work. 2012-07-29 14:22:56 +02:00
kai 175810bdab Consolidate all MSVC related files for LDC/LDC2 in 1 folder. 2012-06-06 17:32:47 +02:00
kai 086e0d251b Latest changes to compile LDC with MSVC. 2012-06-06 17:29:21 +02:00
kai 30cc6e309a Add more files required for MSVC. 2012-06-01 17:49:28 +02:00
David Nadlinger 1805e534b2 Fix issue 97 - <<= broken for LDC 1.
This code path was introduced in the 1.074 merge.
2012-05-25 15:54:42 +02:00
kai 1c6ff32d50 Merge dmd-1.074 into ldc. 2012-04-13 23:12:46 +02:00
kai f1998a6110 Minimize differences between original dmd source and ldc1.
Mainly affects formatting but I also found some code differences.
2012-04-10 21:52:12 +02:00
Eldar Insafutdinov 30b20794c7 Fix D1 frontend 2012-04-02 16:43:46 +01:00
kai e5f2430855 Remove unused member VarDeclaration::anonDecl. 2012-03-28 06:57:17 +02:00
kai e739102374 Removed unused member VarDeclaration::offset2. 2012-03-27 07:13:55 +02:00
kai 0a9ba4d283 Move additional #include inside IN_LLVM section. 2012-03-25 15:19:25 +02:00
kai 2433b74460 Add some upcoming changes from 2.059/1.074 which helps compiling with MSC. 2012-03-22 21:01:43 +01:00
kai dee054fae0 Small code cleanup.
- Wraps some LDC specific code in 'IN_LLVM' section
- Adds some MSVC specific code to 'IN_LLVM' section
- Removes an unused include file

Net result is much less errors with MSVC.
2012-03-15 07:11:54 +01:00
kai d6396bbddf Fix error with va_arg in 64 bit mode. 2012-03-06 07:29:43 +01:00
kai 8a20415cd1 Fix white space. 2012-03-06 07:28:29 +01:00
kai a23b837ebd Merge dmd-1.073. 2012-02-23 20:41:22 +01:00
Alexey Prokhin 4d3ba3594c Refactoring: moved ldc specific code from dmd/attrib.c and dmd2/attrib.c into gen/pragma.cpp 2012-02-15 13:16:06 +04:00
kai 04b3d72cfe Fix for issue #60. 2012-02-03 17:20:18 +01:00
kai 37ed7cdbae Added missing initialization. 2012-02-03 16:51:11 +01:00
kai f9201e8352 Merge 1.072 2012-02-02 03:13:27 +01:00
David Nadlinger efcbe8390a Work around macro redefinition warning (darwin11-llvm-gcc-4.2). 2012-01-23 21:42:02 +01:00
Alexey Prokhin 43057c64ec Temporary fixes for #60 and #59 until ldc1 frontend is not updated to the latest version 2012-01-10 22:09:22 +04:00
Alexey Prokhin 43365105ef Forgotten changes from 875ebcf 2012-01-10 21:46:40 +04:00
Alexey Prokhin edc4a5f003 DMD Issue 5416 - null should have a type of its own 2011-12-16 20:15:10 +04:00
Alexey Prokhin 4e8afa8858 Fixed #47 — Compile-time segfault involving libpthread, _aaGet 2011-12-11 09:52:09 +04:00
Alexey Prokhin 23947489f7 Backported llvm3.0 intrinsic patch to ldc1 2011-12-07 19:36:14 +04:00
Alexey Prokhin 641cc85e64 Added -shared switch.
If the flag is passed, ldc will create a shared library not an executable file.
2011-12-06 19:43:14 +04:00
Alexey Prokhin 913eda6188 Fixed compilation of ldc1 2011-12-06 17:36:53 +04:00
Alexey Prokhin 6357c421ac Updated ldc version and homepage 2011-12-03 13:52:05 +04: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
David Nadlinger 21a05aa971 Merge branch 'default' into 'merge'. 2011-07-29 00:37:30 +02:00
David Nadlinger 15c5316e26 Prevent two function with same mangled name but different types from being declared.
Previously, LDC would crash in the backend due to the fact that the IR is typed in such cases (we recently had such an instance with Tango, where an extern( C ) function was declared once with int and once with size_t).
2011-07-27 23:01:22 +02:00
Alexey Prokhin a41b822420 Fixed ldc1 compilation 2011-07-26 09:30:36 +04:00
Alexey Prokhin 7a31b599cc Updated to dmdfe 2.054 2011-07-19 19:20:38 +04:00