Commit Graph

182 Commits

Author SHA1 Message Date
David Nadlinger
359f6c585a CPU detection for ARM.
This is not perfect yet, as lookupTarget wipes out any more
specific arch info (e.g. armv8) the triple might have.
2013-10-06 07:36:59 +02:00
David Nadlinger
e9e4e10085 Auto-detect target attributes for -mcpu=native.
This is currently only implemented for ARM in LLVM.
2013-10-06 02:38:50 +02:00
David Nadlinger
e57d0458fb getX86TargetCPU cleanup. 2013-10-06 01:48:21 +02:00
David Nadlinger
d17aa2aaac Disentangle -march and -mcpu.
-mcpu=native now actually works.

GitHub: Fixes #414.
2013-10-06 01:48:12 +02:00
David Nadlinger
02abf028f8 Don't require -triple when using -march.
There is really no reason we should, and I couldn't find out
why that check was added back in 2009.

Also cleaned up the code a bit now that the LLVM 3.0 branches
are gone.
2013-10-06 01:35:20 +02:00
David Nadlinger
b2b56203a9 Use llvm::Triple::isArch64Bit (LLVM 3.1+). 2013-10-06 01:33:29 +02:00
David Nadlinger
639bc0ab71 Removed a few fatal() calls in argument parsing code.
global.errors is checked immediately after return anyway.
2013-10-06 01:33:29 +02:00
David Nadlinger
b94ed4092e De-ancient-C-ification, spelled out EXIT_SUCCESS. 2013-10-06 01:33:29 +02:00
David Nadlinger
7e74f65b32 Also factored out argument parsing to separate function.
The code is still messy, but we have to start somewhere...
2013-10-06 01:33:28 +02:00
David Nadlinger
cc11af3473 Factored predefined version handling code out of main(). 2013-10-06 01:33:28 +02:00
David Nadlinger
71c67457c3 Cleanup: Kill backend_init/term. 2013-10-06 01:33:28 +02:00
David Nadlinger
177b892bf0 Cleanup: We don't support DMC. 2013-10-06 01:33:28 +02:00
David Nadlinger
68c272d6d9 Renamed driver/target to .../targetmachine to avoid confusion with the frontend file. 2013-10-06 01:33:28 +02:00
David Nadlinger
ca82589e25 Merge pull request #482 from klickverbot/ldmd-create-directory
LDMD: Create output directories if they do not exist.
2013-10-03 19:21:23 -07:00
David Nadlinger
7f20de16cf LDMD: Create output directories if they do not exist.
There might be other cases using the LLVM output code as well
that I haven't handled here, but the changes are sufficient to
make LDC work with rdmd on Linux.

GitHub: Fixes #480.
2013-10-02 18:09:47 +02:00
David Nadlinger
c58c833be9 Trivial indentation fix. 2013-10-02 18:02:41 +02:00
David Nadlinger
cf18366c46 LDMD: Ignore -quiet, it is the default.
GitHub: Fixes #472.
2013-09-21 18:31:14 +02:00
David Nadlinger
0a8e1f78b7 Do not append unique suffix to asm file when -output-s is given.
This fixes a regression introduced by commit 50f145640
(pull request #473).
2013-09-15 23:41:55 +02:00
David Nadlinger
50f145640f Use PathV1 for creating temporary files on pre-3.4 LLVM.
GitHub: Fixes #471.
2013-09-15 17:03:39 +02:00
David Nadlinger
b3d8c497e1 Remove leftover D1-only comment. 2013-09-07 22:14:07 +02:00
kai
fc24bd15ca Add version identifier for AArch64 2013-09-07 18:17:02 +02:00
kai
399a0396d2 Fix for issue #467 and partial fir for issue #455 2013-09-06 22:46:06 +02:00
kai
ecf40bef59 Reverting last commit as it breaks a test 2013-09-06 22:30:02 +02:00
kai
1ce6e18a6e Fix for issue #467 2013-09-06 21:58:50 +02:00
Alexey Prokhin
54078eca66 Set global.params.isOS variables so we do not have to modify dmd frontend to use targetTriple 2013-07-29 18:49:09 +04:00
Alexey Prokhin
69e7907875 Move implementation of Module::buildTargetFiles and Module::buildFilePath to gem/module.cpp 2013-07-28 21:17:25 +04:00
kai
81bf8c19a5 Fix a typo in keyowrd 2013-07-20 18:20:24 +02:00
kai
4e8acf7eb6 Fix for LLVM 3.4 2013-07-20 20:23:31 +02:00
kai
9fd5d42e46 Fix ldmd using LLVM 3.4.
unique_file was renamed to createUniqueFile.
2013-07-07 15:34:09 +02:00
kai
02d40239aa unique_file was renamed to createUniqueFile in LLVM.
Fixes yet another LLVM 3.4 compile error.
2013-07-07 14:33:47 +02:00
kai
508bf67e2d Fix a gcc 4.4.7 issue and an LLVM 3.4 oversight. 2013-06-29 17:24:03 +02:00
kai
272230fe59 Make driver/toobj.cpp compatible with LLVM 3.4. 2013-06-29 17:11:14 +02:00
kai
707c134d6e Make ldmd source compatible with LLVM 3.4. 2013-06-29 16:10:52 +02:00
kai
8fb0b12e9e Replace llvm::sys::Path with llvm::SmallString in configfile.cpp.
Also adds some required functions for LLVM 3.4.
2013-06-29 15:10:30 +02:00
kai
cf88271ab9 Replace llvm::sys::Path with std::string.
In many cases this is straightforward. It makes the source LLVM 3.4 compatible without using #idef's.
2013-06-29 14:20:44 +02:00
kai
96601b33fa Fix ldmd for LLVM 3.4
The Path::canExecute() method is gone. As a first fix just copy the source.
2013-06-22 16:58:56 +02:00
kai
aa143b560c Include Git revision in version info.
CMakeLists.txt contains now the version numbers for DMD and (next) LDC release.
If a .git folder is found then the LDC version is replaced by the first 6 chars
of the Git revision.

Possible improvements:

- If the build is not done at the master branch then it could be useful to check for a tag and use the tag instead of the revision. (for release builds)
- Maybe it is useful to include the branch name.

This fixes issue #366.
2013-06-21 06:47:32 +02:00
David Nadlinger
31d85d0910 Merge pull request #398 from ldc-developers/merge-2.063
DMD 2.063.1 merge
2013-06-17 14:04:36 -07:00
David Nadlinger
235bb94878 Make -release only disable bounds checking in non-@safe code. 2013-06-17 13:31:21 +02:00
kai
683294cec9 Fix a typo in Linux code. 2013-06-16 17:57:25 +02:00
David Nadlinger
68798f06c8 Accept '.dd' pure DDoc files. 2013-06-16 00:39:47 +02:00
David Nadlinger
46b6fdd531 Implement '-main'. 2013-06-15 23:09:59 +02:00
David Nadlinger
bed6243481 LDC does not support -transition yet. 2013-06-15 22:57:57 +02:00
kai
f1c71e4bac Make ldc compatible with LLVM 3.4
Development of LLVM 3.4 started with a cleanup of the path class (PathV1).
The changes here let ldc compile at least with rev. 184039 of LLVM.
2013-06-15 19:52:29 +02:00
kai
9f921b25d9 Make ldmd compatible with LLVM 3.4
Development of LLVM 3.4 started with a cleanup of the path class (PathV1).
The changes here let ldmd compile at least with rev. 184039 of LLVM.
2013-06-15 19:13:45 +02:00
David Nadlinger
fd3c696d94 Call Expression::init() during startup.
Was added in 2.063.
2013-06-12 20:16:37 +02:00
David Nadlinger
292caa1438 Merge the 2.063 frontend. 2013-06-12 20:16:37 +02:00
David Nadlinger
b2f2afad29 LDMD: Made error message on compiler execution error clearer.
It is also triggered when the compiler exits with a signal, etc.
2013-06-07 03:20:32 +02:00
David Nadlinger
005f993982 Merge branch 'release-0.11.0'.
Conflicts:
	gen/llvmhelpers.cpp
2013-06-02 21:53:41 +02:00
David Nadlinger
ec59399e21 Change all URLs to point to wiki.dlang.org for the time being. 2013-06-02 21:27:02 +02:00