Commit Graph

1641 Commits

Author SHA1 Message Date
Vassil Vassilev
666437108e Replace .U with .undo 2014-03-31 14:03:09 +02:00
Vassil Vassilev
96319aa30f Implement .U FileName. 2014-03-31 14:03:08 +02:00
Vassil Vassilev
33676c14a9 Implement dump of MacroDirectiveInfo. 2014-03-31 14:03:08 +02:00
Vassil Vassilev
3e7f2aa7aa If -verify specified don't apply any custom diagnostic mappings. 2014-03-31 14:03:07 +02:00
Vassil Vassilev
4b0b984d63 Use the proper arguments to remove items. 2014-03-31 14:03:06 +02:00
Vassil Vassilev
3dd8d2e900 The CompilerInvocation is the owner of the DiagnosticOptions, all the rest point to them.
It used some default diagnostic options, which are different from the ones that
come from the driver passing the invocation options.
2014-03-31 14:03:06 +02:00
Vassil Vassilev
40195aa864 Cosmetics. 2014-03-31 14:03:06 +02:00
Vassil Vassilev
d7d4674f4e Increase verbosity of the output 2014-03-31 14:03:05 +02:00
Vassil Vassilev
2f9ba97a53 We need internal isystem. 2014-03-31 14:03:05 +02:00
Vassil Vassilev
4d53e0fd33 Access sema internals and revert the list of unused decls. 2014-03-31 14:03:05 +02:00
Vassil Vassilev
33ece80d2b Move renaming. 2014-03-31 14:03:04 +02:00
Vassil Vassilev
230638b648 Rename the class to smth more meaningful. 2014-03-31 14:03:04 +02:00
Vassil Vassilev
0210c101f4 Escape -x flags passed in as invocation. 2014-03-31 14:03:03 +02:00
Vassil Vassilev
d87e58b4f5 Simplify. 2014-03-31 14:03:03 +02:00
Vassil Vassilev
5e6b8590be Do not leak the diagnostics engine. 2014-03-31 14:03:03 +02:00
Vassil Vassilev
1f25fe3a00 CXX consistency. 2014-03-31 14:03:03 +02:00
Vassil Vassilev
73113c2c4b Reduce includes. 2014-03-31 14:03:02 +02:00
Vassil Vassilev
d86e86086f Use better, more accurate include. 2014-03-31 14:03:02 +02:00
Vassil Vassilev
0250ffe457 Fwd declare the clang::DiagnosticsEngine. 2014-03-31 14:03:01 +02:00
Vassil Vassilev
5e3a83bd3b Set the ignored diags before the driver does parse from args.
This allows the driver to override our custom diagnostics if the user wants any
special treatment.
2014-03-31 14:03:01 +02:00
Vassil Vassilev
59b980dd69 Don't recreate the diagnosic client, just set it to the tweaked instance. 2014-03-31 14:03:00 +02:00
Vassil Vassilev
d28bc43cd1 Suppress warnings coming from system headers. 2014-03-31 14:02:59 +02:00
Vassil Vassilev
d1a8efcd55 Implement soft reset of the diagnostics engine. 2014-03-31 14:02:59 +02:00
Axel Naumann
ba642a2869 Be more precise when comparing compilation and runtime libc++.
For instance XCode 5.1 braught a libc++ that was sufficiently different to cause havok
all over the place. Thus ABI_VERSION is clearly not enough.
2014-03-29 15:38:56 +01:00
Axel Naumann
a73b5c98c1 Add new file. 2014-03-28 16:52:56 +01:00
Axel Naumann
b3f0aa4120 Add new llvm lib dependencies. 2014-03-28 16:52:55 +01:00
Axel Naumann
ac4aaa3c76 Fix warning; be explicit about overriding the overload. 2014-03-28 16:13:00 +01:00
Axel Naumann
358764f8c0 Implement custom inliner to skip doFinalization. 2014-03-28 15:51:03 +01:00
Axel Naumann
d7b99d80fc Disable module validation: it takes ages. 2014-03-28 15:51:03 +01:00
Axel Naumann
f2da5f7cb7 Add backend passes (inlining etc) to cling.
They are usually provided by clang's BackendUtil - which we don't use and which
has no support for incremental ("streaming") compilation but runs the passes on
the whole module the whole time, and does end-of-TU cleanup (e.g. "dead" code
removal) that we cannot use because subsequent transactions might create new
uses - think force_inline functions that must stay.

Instead BackendPass wraps what's in clang's BackendUtil into a
TransactionTransformer. It gets added to the IR transformers. In the future this
should only transform the delta of one Transaction instead of the whole Module.

This fixes the libc++ issue we worked around by
templates' symbols are not exported anymore and cause missing symbols with
XCode 5.1.

We include ObjC passes even though this blows up the list of linked libraries to
make it easier to port cling to ObjC(++).
2014-03-28 15:51:03 +01:00
Axel Naumann
e85e30e290 Fix MacOS missing symbol __ZNSt3__113basic_ostreamIcNS_11char_traitsIcEEElsEi.
This is triggered by emitting operator<< 'class std::__1::basic_ostream<char,
struct std::__1::char_traits<char> > &(int)' even though its marked as exported
in general. Now that clang and libc++ agree on the handling of exported
templates we can remove our work-around.
2014-03-28 15:51:03 +01:00
Vassil Vassilev
c65f5bbba6 Use proper regexp 2014-03-27 11:18:57 +01:00
Vassil Vassilev
f0fe89669c Fix doxygen typos. Thank you clang. 2014-03-27 11:18:57 +01:00
Axel Naumann
3aea38dd3d CXXExceptions are C++, not Exceptions. 2014-03-25 10:25:01 +01:00
Axel Naumann
c65443727d Only turn on C++11 (and other C++ LangOpts) if C++ is enabled. 2014-03-24 16:25:00 +01:00
Vassil Vassilev
9af7ee2640 Actual optional regex syntax. 2014-03-24 15:26:56 +01:00
Vassil Vassilev
2c9fe16a56 Remove dead branch. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
80a0e1e56e C++11 noexcept op. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
4d5e607256 Merge unloadTransaction and rollbackTransaction. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
cad76c3090 Reset diags is done in the node eraser. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
b1f4287c67 Reduce includes. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
c6544c49f9 Update test. 2014-03-24 14:25:57 +01:00
Axel Naumann
7390550dfe Add comment explaining (part of) the bootstrap sequencing. 2014-03-23 21:13:54 +01:00
Axel Naumann
b44c7c69c0 MASSIVE reduction in linked libs. Ouch. 2014-03-22 18:39:57 +01:00
Philippe Canal
93ce42bdc3 Preliminary support for template alias.
GetPartiallyDesaguredType now desugar template alias
but does not yet properly propagate the opaque typedef
and thus:

  template <typename T> using myvector = std::vector<T>;
  myvector<Double32_t> vd32d;

  template<class T> using ptr = T*;
  ptr<Double32_t> p3;

Both currently result in the Double32_t being ignored.
2014-03-21 16:57:07 +01:00
Philippe Canal
45895aec23 No longer hide the compiler detail.
The partial desugaring (part of normalization) now strips a typedef
even when it original from std and points to compiler details (__gnu_cxx, etc.).

The cost of this convenience was the fact the same entity could have different
'name' and thus different class even-though they were supposed to be strictly
equivalent. i.e. depending on the way to get to the class it could be name
vector<int*>::iterator or __gnu_cxx::iterator<int*> or std::iterator<int*>.

This different from the case where we have a strictly bidirectional equivalent
between the class and its unique typedef (yes, we are talking about you std::string).

This also different from the case where there is a semantic difference between
the two possible name.  I.e. where an opaque typedef is used.  For example,
vector<Double32_t> and vector<double> and where the 'way' to get to the type[name]
is relevant.
2014-03-21 16:57:07 +01:00
Timur Pocheptsov
3115300308 Protect against recursive definitions (for example,
data members of a type we're already priting - either static data member or "cross-references").
2014-03-21 11:24:58 +01:00
Philippe Canal
8bdb34696e Do not pass on -ffunction-sections.
-ffunction-sections breaks the debugger on some platforms ... and does not help libCling at all.
2014-03-19 22:48:58 +01:00
Vassil Vassilev
68e01b936b Implement FileManager uncaching. 2014-03-19 14:52:21 +01:00
Axel Naumann
931608551b Enforce that cling uses clang with our patches, not a user-provided clang. 2014-03-18 09:18:07 +01:00