377 Commits

Author SHA1 Message Date
Vassil Vassilev
33676c14a9 Implement dump of MacroDirectiveInfo. 2014-03-31 14:03:08 +02:00
Vassil Vassilev
1f25fe3a00 CXX consistency. 2014-03-31 14:03:03 +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
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
f0fe89669c Fix doxygen typos. Thank you clang. 2014-03-27 11:18:57 +01:00
Axel Naumann
297d6a0019 First step away from SVN versioning. 2014-03-04 19:55:00 +01:00
Axel Naumann
57a84ab394 Move some code around to chop Interpreter() into smaller pieces. 2014-03-04 19:55:00 +01:00
Axel Naumann
baca204185 Simplify cxa_atexit(), first part.
Remove trigger__cxa_atexit(), we will just remap until successful.
Remove unused dso parameter.
Instead of friending just provide a function.
Pass a transaction, the typesafe way.
2014-03-04 19:54:59 +01:00
Axel Naumann
1e86611693 Remove unused function. 2014-03-04 19:54:59 +01:00
Axel Naumann
6b647a89cd Force symbol for ~__trigger__cxa_atexit (ROOT-6074); avoid reserved name. 2014-03-03 18:45:21 +01:00
Vassil Vassilev
c7e7156ce1 Remove Interpreter::getModule. 2014-03-03 15:27:05 +01:00
Vassil Vassilev
8d457e947f StringRef-y. 2014-03-03 15:27:05 +01:00
Vassil Vassilev
15918cd889 Remove unused interface. 2014-03-03 15:27:05 +01:00
Vassil Vassilev
e4383ecf7d Remove unused interface. 2014-03-03 15:27:05 +01:00
Vassil Vassilev
1851604b8c Rename printAST to printDebug. 2014-03-03 15:27:05 +01:00
Vassil Vassilev
c745dcc29c Remove useless flag. 2014-03-03 15:27:04 +01:00
Vassil Vassilev
f29b09e054 Remove .printIR and replace it with smarter debug class reusing the latest state tracker. 2014-03-03 15:27:04 +01:00
Vassil Vassilev
71b05e8321 Use the new CodeGen debug printouts in .storeState 2014-02-27 15:57:11 +01:00
Vassil Vassilev
eea3bf1f3d This should be reimplemented. So far it is a nop. 2014-02-27 12:49:10 +01:00
Axel Naumann
9b678f2829 Allow updating of the MetaProcessor's output stream, to redirect a meta command. 2014-02-25 14:18:01 +01:00
Axel Naumann
c88d5a4f19 More doxygen. 2014-02-21 12:11:56 +01:00
Vassil Vassilev
c92a68efc4 Implement cling::Transaction unique id. 2014-02-20 15:16:59 +01:00
Vassil Vassilev
340461a57a Trailing blanks 2014-02-20 15:16:59 +01:00
Axel Naumann
efb09a4d77 Fix doxygen. 2014-02-20 15:16:58 +01:00
Vassil Vassilev
398e97eb40 If the value is not set (due to errors in the runtime evaluation), return default. 2014-02-20 14:43:05 +01:00
Vassil Vassilev
c992cf3047 Implement reloading on .L
We keep the FileEntry -> Transaction mapping so that next time there is .L
we can figure out that it was already loaded and unload it and reload it again.
2014-02-20 10:36:10 +01:00
Axel Naumann
b27e430c89 Implement setValueNoAlloc() for long double. 2014-02-19 14:55:00 +01:00
Vassil Vassilev
2309fc097e Rename ExecutionContext -> IncrementalExecutor 2014-02-19 12:55:00 +01:00
Axel Naumann
8b151c893e Remove now unused Interpreter::getLLVMType(). 2014-02-19 10:53:58 +01:00
Axel Naumann
71cadd6ad2 Remove remaining traces of llvm::Type from cling::Value. 2014-02-19 10:53:58 +01:00
Axel Naumann
789648df2d Add switch for lookup diags; enable it for gDebug>5 (ROOT-6070, ROOT-6044).
Use enum to avoid ambiguities between consecutive bollean args.
Use less default args to avoid Type* -> bool conversion.
2014-02-19 08:39:58 +01:00
Vassil Vassilev
1f85d7b725 Handle returns, temporary results, independent on JIT's runFunction.
Here we don't want to depend on the JIT runFunction, because of its limitations,
when it comes to return value handling. There it is not clear who provides the
storage and who cleans it up in a  platform independent way.

Depending on the type we need to synthesize a call to cling:
  0) void : do nothing;
  1) enum, integral, float, double, referece, pointer types :
       call to cling::internal::setValueNoAlloc(...);
  2) object type (alloc on the stack) :
       cling::internal::setValueWithAlloc
     2.1) constant arrays:
         call to cling::runtime::internal::copyArray(...)

We need to synthesize later (see RuntimeUniverse.h)
 Wrapper has signature: void w(cling::StoredValueRef SVR)
case 1):
  setValueNoAlloc(gCling, &SVR, lastExprTy, lastExpr())
case 2):
  new (setValueWithAlloc(gCling, &SVR, lastExprTy)) (lastExpr)
  case 2.1):
    copyArray(src, placement, N)
2014-02-18 17:22:58 +01:00
Vassil Vassilev
ac4c77fe0a Add const to the void* so that the const overloads falls into this case too. 2014-02-18 17:22:58 +01:00
Vassil Vassilev
ad7054000c Improve implementation, shorter argument names, less overloads. 2014-02-18 17:22:58 +01:00
Axel Naumann
81c8c454b6 Keep constness of &; no need for const T* (folds into T*). 2014-02-18 17:22:58 +01:00
CristinaCristescu
9eb0ffbfcd Lay the foundations of return value alloc/noalloc. The JIT's runFunction is unreliable on 32 bit. Thus we provide a similar functionality in cling to deal with the cases where runFunction cannot.
The underlying issue is that the caller need to provide argument setup
and cleanup, which for 32bit is different than in 64, for example.
The approach we propose should be independent on the concrete platform
implementation, because we pass in the storage and depending on the
return result, we let cling runtime to deside whether and how to alloc
storage.
2014-02-18 17:22:58 +01:00
Vassil Vassilev
bf57dc0424 Move isOnScopeChains to a common ground. Erase the decl from the resolver chain only if it existed there. 2014-02-12 15:30:59 +01:00
Vassil Vassilev
698c8f16fc Fix windows warnings. 2014-02-06 14:51:00 +01:00
Vassil Vassilev
7763150743 Keep the files diff files until the end of the session 2014-02-06 14:50:58 +01:00
Vassil Vassilev
938326566e Blanks. 2014-02-06 14:50:57 +01:00
Vassil Vassilev
13021e652b In rawInput mode we want to be as close as possible to the compiler. 2014-02-06 14:50:57 +01:00
Vassil Vassilev
e5a0df500e Add support for C tentative definitions. 2014-02-06 14:50:57 +01:00
Vassil Vassilev
0944f060ec In -fsyntax-only mode we don't have llvm::Module. 2014-02-06 14:50:56 +01:00
Axel Naumann
c20eb269ad Add ref-getters for GenericValue; do not copy it unnecessarily. 2014-02-04 16:16:55 +01:00
Philippe Canal
6a957ea310 Fix typo in doxygen doc 2014-02-03 16:08:56 +01:00
Philippe Canal
c6501ffe97 Introduce Transform::Config::DropDefaultArg
Currently only implemented for the STL collection.

This could eventually be used to allow customization
of which default argument to strip and which class template.

For now, it is only used to prevent the addition of template
default template argument to the STL collection ... which
we would any strip.

This fixes the secondary issue in ROOT-6020 (one class template
instance having more than one corresponding TClass due to the
inconsistency in the normalization (not adding vs not stripping)
2014-02-01 03:18:02 +01:00
Philippe Canal
1004034c75 Move IsStdClass to cling::utils::Analyze 2014-02-01 03:18:02 +01:00
Bertrand Bellenot
8ca703c272 Implement Interpreter's InclusionDirective() callback
InclusionDirective() callback tells us that an inclusion directive has been processed, allowing us to try to autoload classes using their header file name.
For example try to autoload TGClient (libGui) when seeing #include "TGClient.h"
This should prevent potential crash when executing macros using globals (e.g. gClient), with the following error:
ExecutionContext: use of undefined symbol 'gClient'!
2014-01-28 15:07:56 +01:00
CristinaCristescu
6414870d7a Correct doxygen doc. 2014-01-28 14:52:53 +01:00