Commit Graph

175599 Commits

Author SHA1 Message Date
Tobias Grosser d79029ab62 Fix formatting
llvm-svn: 210124
2014-06-03 20:20:41 +00:00
Rafael Espindola 63e92fb166 Fix a small bug in the parsing of anonymous globals.
It was able to parse

hidden dllexport global i32 42

but not

dllexport global i32 42

llvm-svn: 210121
2014-06-03 20:07:32 +00:00
Rafael Espindola 52b7442c28 Simplify the parsing of unnamed globals. No functionality changed.
llvm-svn: 210120
2014-06-03 20:00:20 +00:00
Rafael Espindola 6efc78e7fa Update comment. This should have been part of r210062.
llvm-svn: 210119
2014-06-03 19:38:37 +00:00
Alp Toker af3f9640c5 Remove some redundant doc comments
llvm-svn: 210118
2014-06-03 19:06:49 +00:00
Sebastian Pop 422e33f363 record delinearization result and reuse it in polyhedral translation
Without this patch, the testcase would fail on the delinearization of the second
array:

; void foo(long n, long m, long o, double A[n][m][o]) {
;   for (long i = 0; i < n; i++)
;     for (long j = 0; j < m; j++)
;       for (long k = 0; k < o; k++) {
;         A[i+3][j-4][k+7] = 1.0;
;         A[i][0][k] = 2.0;
;       }
; }

; CHECK: [n, m, o] -> { Stmt_for_body6[i0, i1, i2] -> MemRef_A[3 + i0, -4 + i1, 7 + i2] };
; CHECK: [n, m, o] -> { Stmt_for_body6[i0, i1, i2] -> MemRef_A[i0, 0, i2] };

Here is the output of FileCheck on the testcase without this patch:

; CHECK: [n, m, o] -> { Stmt_for_body6[i0, i1, i2] -> MemRef_A[i0, 0, i2] };
         ^
<stdin>:26:2: note: possible intended match here
 [n, m, o] -> { Stmt_for_body6[i0, i1, i2] -> MemRef_A[o0] };
 ^

It is possible to find a good delinearization for A[i][0][k] only in the context
of the delinearization of both array accesses.

There are two ways to delinearize together all array subscripts touching the
same base address: either duplicate the code from scop detection to first gather
all array references and then run the delinearization; or as implemented in this
patch, use the same delinearization info that we computed during scop detection.

llvm-svn: 210117
2014-06-03 18:16:31 +00:00
Todd Fiala 68c246aad0 Added gdb-remote memory read ($m) test.
Added set-memory:{content} and get-memory-address-hex: commands
to the test exe for gdb-remote.  Added a test that sets the content
via the inferior command line, then reads it back via gdb-remote
with $m.

Passing on debugserver.  Marked as fail on llgs.  Implementing
in the llgs branch next.

llvm-svn: 210116
2014-06-03 18:09:56 +00:00
Alp Toker ea04672c82 Fix leak from r210059
Also revert r210096 which temporarily disabled the test while this was being
investigated.

llvm-svn: 210115
2014-06-03 17:23:34 +00:00
Tilmann Scheller a17a4326d0 [AArch64] Fix typo in load/store optimizer.
llvm-svn: 210114
2014-06-03 16:33:13 +00:00
Tilmann Scheller 2a7efeb7b7 [AArch64] Add regression tests for the load/store optimizer which cover post-index update folding with sub rather than add.
The tests check that the following transform happens:

  (ldr|str) X, [x20]
   ...
  sub x20, x20, #16
   ->
  (ldr|str) X, [x20], #-16

with X being either w0, x0, s0, d0 or q0.

llvm-svn: 210113
2014-06-03 16:03:00 +00:00
Jeroen Ketema f3943efe17 Fix build broken by LLVM commit r209103
Reviewed-by: Aaron Watry <awatry@gmail.com>
llvm-svn: 210111
2014-06-03 15:43:57 +00:00
Rafael Espindola e3986f3e04 Remove dead code.
New code should probably use shared_ptr anyway.

llvm-svn: 210110
2014-06-03 15:36:31 +00:00
Evgeniy Stepanov ce98452516 [sancov] Delay opening dump file until the first module constructor.
llvm-svn: 210109
2014-06-03 15:27:15 +00:00
Evgeniy Stepanov 937afa1fbb [sancov] Handle spaces in module name.
llvm-svn: 210108
2014-06-03 15:25:43 +00:00
Rafael Espindola aa31609fb8 Implement one operator== with another.
Thanks for David Blaikie for the suggestion.

llvm-svn: 210107
2014-06-03 15:06:22 +00:00
Kostya Serebryany 7d4fc2c6a7 [asan] enable detect_odr_violation=2; https://code.google.com/p/address-sanitizer/wiki/OneDefinitionRuleViolation . This feature has been working quite well so far, found a few bugs and zero false positives. The main problem is that there could be lots of true positives and users will have to disable this checking until the bugs are fixed.
llvm-svn: 210106
2014-06-03 15:06:13 +00:00
Colin Riley 28e7ed12f5 Windows fix: Disable editline for MSVC. Since r208369 there have been issues, probably related to the editline wrapper. For now, it's more stable and usable disabled.
llvm-svn: 210105
2014-06-03 14:37:35 +00:00
Colin Riley 740ed90626 Windows fix: Condition::Wait returned failure when it actually succeeded (SleepConditionVariableCS returns non-zero for success)
llvm-svn: 210104
2014-06-03 14:33:41 +00:00
Evgeniy Stepanov 19f75fc947 [asan] Fix coverage instrumentation with -asan-globals=0.
llvm-svn: 210103
2014-06-03 14:16:00 +00:00
Tim Northover 6890add11d AArch64: mark small types (i1, i8, i16) as promoted
This means the output of LowerFormalArguments returns a lowered
SDValue with the correct type (expected in SelectionDAGBuilder).
Without this, an assertion under a DEBUG macro triggers when those
types are passed on the stack.

llvm-svn: 210102
2014-06-03 13:54:53 +00:00
Rafael Espindola 8c557283c0 Use IntrusiveRefCntPtr's == and != nullptr operators.
This is a partial revert of r210075.

llvm-svn: 210101
2014-06-03 13:27:48 +00:00
Rafael Espindola 6d5ec8fee3 Add operator== and operator!= to compare with nullptr.
llvm-svn: 210100
2014-06-03 13:26:18 +00:00
Colin Riley b7fd1bd223 Fix windows build: SBTypeEnumMember.cpp added to the separate windows liblldb.dll project.
llvm-svn: 210099
2014-06-03 13:01:18 +00:00
Evgeniy Stepanov bb2fc7e4bb [sancov] Fix map update logic on Android.
dlopen()/dlclose() are not interceptable on Android,
so we update .sancov.map in module constructor callbacks.

llvm-svn: 210098
2014-06-03 12:15:43 +00:00
Daniel Jasper 114a2bc9d2 clang-format: Refactor indentation behavior for multiple nested blocks.
This fixes a few oddities when formatting multiple nested JavaScript
blocks, e.g.:

Before:
  promise.then(
      function success() {
        doFoo();
        doBar();
      },
      [], function error() {
        doFoo();
        doBaz();
      });
  promise.then([],
               function success() {
                 doFoo();
                 doBar();
               },
               function error() {
    doFoo();
    doBaz();
  });

After:
  promise.then(
      function success() {
        doFoo();
        doBar();
      },
      [],
      function error() {
        doFoo();
        doBaz();
      });
  promise.then([],
               function success() {
                 doFoo();
                 doBar();
               },
               function error() {
                 doFoo();
                 doBaz();
               });

llvm-svn: 210097
2014-06-03 12:02:45 +00:00
Kostya Serebryany be6d91f1ba temporary disable part of a test because it causes clang to leak memory (want to have the sanitizer bot green)
llvm-svn: 210096
2014-06-03 11:45:37 +00:00
Alexander Musman a8e9d2eccc [OPENMP] Loop canonical form analysis (Sema)
This patch implements semantic analysis to make sure that the loop is in OpenMP canonical form.
This is the form required for 'omp simd', 'omp for' and other loop pragmas.

Differential revision: http://reviews.llvm.org/D3778

llvm-svn: 210095
2014-06-03 10:16:47 +00:00
Simon Atanasyan fd5b2346cc [Mips] Make la25-stub.test self contained.
No functional changes.

llvm-svn: 210094
2014-06-03 09:59:42 +00:00
Rui Ueyama eafa806b72 Improve error message.
Previously the parser always printed out an error message followed
by "Invalid file type" even if the file type is correct.

llvm-svn: 210093
2014-06-03 08:40:49 +00:00
Richard Smith 9213a6bfa4 Remove incorrect assertion.
llvm-svn: 210092
2014-06-03 08:40:27 +00:00
Richard Smith 454a7cdfb3 Implement DR990 and DR1070. Aggregate initialization initializes uninitialized
elements from {}, rather than value-initializing them. This permits calling an
initializer-list constructor or constructing a std::initializer_list object.
(It would also permit initializing a const reference or rvalue reference if
that weren't explicitly prohibited by other rules.)

llvm-svn: 210091
2014-06-03 08:26:00 +00:00
Richard Smith f051496804 Teach AST dumper to dump the array filler in an initializer list.
llvm-svn: 210090
2014-06-03 08:24:28 +00:00
Rui Ueyama 009f91a9ee Rename FileToMutable -> SimpleFileWrapper.
FileToMutable is what this class does, but this class (or, to be precise,
an instance of this class) is a wrapper of the other SimpleFile. It's odd
that the class was named like a function.

llvm-svn: 210089
2014-06-03 08:12:33 +00:00
Rui Ueyama 6668b5a8b8 Fix build breakage.
llvm-svn: 210087
2014-06-03 07:53:37 +00:00
Rui Ueyama 6848f96c7a Inline short member function.
llvm-svn: 210086
2014-06-03 07:52:42 +00:00
Rui Ueyama 95be0d014a Use auto for obvious types.
llvm-svn: 210085
2014-06-03 07:43:15 +00:00
Rui Ueyama 9ef8a9c94b No need to compute valBit until mask bit is 1.
llvm-svn: 210084
2014-06-03 07:39:32 +00:00
Richard Smith 6c3bbf4271 PR11410: Extend diagnostic to cover all cases of aggregate initialization, not
just the extremely specific case of a trailing array element that couldn't be
initialized because the default constructor for the element type is deleted.

Also reword the diagnostic to better match our other context diagnostics and to
prepare for the implementation of core issue 1070.

llvm-svn: 210083
2014-06-03 07:28:54 +00:00
Rui Ueyama 076caf7897 Use range-based for loop.
llvm-svn: 210082
2014-06-03 07:27:49 +00:00
Rui Ueyama 9939b5ab5e Remove unusual use of using.
llvm-svn: 210081
2014-06-03 07:24:46 +00:00
Nikola Smiljanic b226964e25 List DR532 as implemented on the defect report status page by renaming the namespace.
llvm-svn: 210080
2014-06-03 07:06:20 +00:00
Richard Smith 06a67e2c6f When emitting a multidimensional array new, emit the initializers for the
trailing elements as a single loop, rather than sometimes emitting a nest of
several loops. This fixes a bug where CodeGen would sometimes try to emit an
expression with the wrong type for the element being initialized. Plus various
other minor cleanups to the IR produced for array new initialization.

llvm-svn: 210079
2014-06-03 06:58:52 +00:00
Rafael Espindola e00fec8fe4 Use an enum class.
llvm-svn: 210078
2014-06-03 05:26:12 +00:00
Rafael Espindola 92512e89a2 Use an enum class.
Might also fix the windows build.

llvm-svn: 210077
2014-06-03 05:12:33 +00:00
Rafael Espindola c7dd10b221 Remove the last unspecified_bool_type from llvm.
llvm-svn: 210076
2014-06-03 05:05:15 +00:00
Rafael Espindola 507f1bc37e Don't assume an implicit IntrusiveRefCntPtr -> bool operator.
llvm-svn: 210075
2014-06-03 05:04:52 +00:00
Rui Ueyama 04ade04e98 Reference::target() doesn't and shouldn't return a nullptr.
llvm-svn: 210074
2014-06-03 05:04:07 +00:00
Rafael Espindola da74795f5b Make this operator bool() explicit to match the standard library.
llvm-svn: 210073
2014-06-03 04:54:15 +00:00
Rafael Espindola d9a25d82c1 Make this operator bool() explicit to match the standard library.
llvm-svn: 210072
2014-06-03 04:42:24 +00:00
Rafael Espindola 1d364c18e2 This lambda returns a boolean, update the return statements.
llvm-svn: 210071
2014-06-03 04:41:30 +00:00