1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 19:12:56 +02:00
Commit Graph

106314 Commits

Author SHA1 Message Date
Rafael Espindola
d95a431fd9 Use range loops.
llvm-svn: 214280
2014-07-30 01:52:40 +00:00
Rafael Espindola
9f7e19243c Convert a few more function pointer calls to just "f()".
llvm-svn: 214276
2014-07-30 01:36:32 +00:00
Adam Nemet
53ebec6583 [AVX512] Test that _mm512_set1_* intrinsics generate broadcasts
llvm-svn: 214275
2014-07-30 01:30:51 +00:00
Adam Nemet
29f192c73f [AVX512] Add missing CHECK-LABEL
llvm-svn: 214273
2014-07-30 01:30:45 +00:00
Rafael Espindola
d5c0acb861 Don't duplicate the function name in a comment.
llvm-svn: 214272
2014-07-30 01:23:45 +00:00
Duncan P. N. Exon Smith
1d7b0f97dd Reapply "UseListOrder: Order GlobalValue uses after initializers"
This reverts commit r214249, reapplying r214242 and r214243, now that
r214270 has fixed the UB.

llvm-svn: 214271
2014-07-30 01:22:16 +00:00
Duncan P. N. Exon Smith
5d1b1e64b5 UseListOrder: Fix undefined behaviour
This commit fixes undefined behaviour that caused the revert in r214249.

The problem was two unsequenced operations on a `DenseMap<>`, giving
different behaviour in GCC and Clang.  This:

    DenseMap<T*, unsigned> DM;
    for (auto &X : ...)
      DM[&X] = DM.size() + 1;

should have been:

    DenseMap<T*, unsigned> DM;
    for (auto &X : ...) {
      unsigned Size = DM.size();
      DM[&X] = Size + 1;
    }

Until r214242, this difference between compilers didn't matter.  In
r214242, `OrderMap::LastGlobalValueID` was introduced and compared
against IDs, which in GCC were off-by-one my expectations.

llvm-svn: 214270
2014-07-30 01:20:26 +00:00
Matt Arsenault
d8f2b465a3 R600/SI: Consider adjacent offsets in getLdStBaseRegImmOfs
We can treat ds_read2_* as a single offset if the offsets are adjacent.

No test since emission of read2 instructions for partially
aligned loads isn't implemented yet.

llvm-svn: 214269
2014-07-30 01:01:10 +00:00
Petar Jovanovic
0f2b26de4c Add support for scalarizing ctlz_zero_undef
Fix the missing case in ScalarizeVectorResult() that was exposed with
libclcore.bc in Android.

Differential Revision: http://reviews.llvm.org/D4645

llvm-svn: 214266
2014-07-30 00:44:03 +00:00
Rafael Espindola
aa8e1b8d73 Use function pointers with just f(1,2) instead of (*f)(1,2).
llvm-svn: 214265
2014-07-30 00:38:58 +00:00
Duncan P. N. Exon Smith
5ed3df063e Revert "UseListOrder: Remove move assignment"
This reverts commit r214260.  Turns out move assignment *is* necessary
for MSVC [1].

[1]: http://bb.pgr.jp/builders/ninja-clang-i686-msc17-R/builds/9631

llvm-svn: 214264
2014-07-30 00:25:33 +00:00
Richard Smith
6c8f410a31 Header hygiene: remove using directive and #undef DEBUG_TYPE once we're done.
llvm-svn: 214263
2014-07-30 00:25:24 +00:00
Duncan P. N. Exon Smith
474bbf4c5a UseListOrder: Remove move assignment
Remove the move assignment added in r214213, since it wasn't necessary
to fix the bots (r214224 was the magic touch).

llvm-svn: 214260
2014-07-30 00:05:02 +00:00
Joerg Sonnenberger
db7b2c7644 Add rfci instruction.
llvm-svn: 214256
2014-07-29 23:45:20 +00:00
Lang Hames
b1e74ae824 [MCJIT] Add options to llvm-rtdyld to describe a phony target address space for
use in -verify mode.

This patch adds three hidden command line options to llvm-rtdyld:

 -target-addr-start <start-addr> : Specify the start of the virtual address
                                   space on the phony target.

 -target-addr-end   <end-addr>   : Specify the end of the virtual address space
                                   on the phony target.

 -target-section-sep <sep>       : Specify the separation (in bytes) between the
                                   end of one section and the start of the next.

These options automatically default to sane values for the target platform. In
particular, they allow narrow (e.g. 32-bit, 16-bit) targets to be tested from
wider (e.g. 64-bit, 32-bit) hosts without overflowing pointers.

The section separation option defaults to zero, but can be set to a large number
(e.g. 1 << 32) to force large separations between sections in order to
stress-test large-code-model code.

llvm-svn: 214255
2014-07-29 23:43:13 +00:00
Joerg Sonnenberger
abd973f309 mbar without argument is equivalent to mbar 0.
llvm-svn: 214250
2014-07-29 23:31:27 +00:00
Duncan P. N. Exon Smith
cc8a88fa18 Revert "UseListOrder: Order GlobalValue uses after initializers"
This reverts commits r214242 and r214243 while I investigate buildbot
failures [1][2][3].  I can't reproduce these failures locally, so if
anyone can see what I've done wrong, I'd appreciate a note.

[1]: http://lab.llvm.org:8011/builders/llvm-hexagon-elf/builds/9840
[2]: http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/14981
[3]: http://bb.pgr.jp/builders/cmake-llvm-x86_64-linux/builds/15191

llvm-svn: 214249
2014-07-29 23:31:11 +00:00
Joerg Sonnenberger
afb8bfcb47 Recognize BookE's mbar instruction.
llvm-svn: 214244
2014-07-29 23:16:31 +00:00
Duncan P. N. Exon Smith
1460a11fa9 UseListOrder: Additional test coverage for r214242
r214242 was subtle enough it really deserves a targeted test with
comments.  This adds some global variables that trigger the relevant
code path.  Sorry this wasn't committed with the fix.

llvm-svn: 214243
2014-07-29 23:15:49 +00:00
Duncan P. N. Exon Smith
cdab8367f8 UseListOrder: Order GlobalValue uses after initializers
To avoid unnecessary forward references, the reader doesn't process
initializers of `GlobalValue`s until after the constant pool has been
processed, and then in reverse order.  Model this when predicting
use-list order.  This gets two more Bitcode tests passing with
`llvm-uselistorder`.

Part of PR5680.

llvm-svn: 214242
2014-07-29 23:06:14 +00:00
Duncan P. N. Exon Smith
589a519a8a UseListOrder: Create a struct around OrderMap, NFC
llvm-svn: 214241
2014-07-29 23:03:40 +00:00
Manman Ren
d130fd7e21 Feedback on r214189, no functionality change.
llvm-svn: 214240
2014-07-29 22:58:13 +00:00
Eli Bendersky
02bdcf05e0 Add missing test for r214210.
Thanks dblaikie for reminding me.

llvm-svn: 214239
2014-07-29 22:57:59 +00:00
Joerg Sonnenberger
5dd0828a9c Fix typo in alias: DSIR -> DSISR
llvm-svn: 214238
2014-07-29 22:42:44 +00:00
Justin Bogner
6ed5e5948b llvm-profdata: Clean up and reorganize some tests
This moves some tests around to make it clearer what's being tested,
and adds very rudimentary comment syntax to the text input format to
make specifying this kind of test a little bit simpler.

llvm-svn: 214235
2014-07-29 22:29:23 +00:00
Joerg Sonnenberger
d52d4c80b5 Support move to/from segment register.
llvm-svn: 214234
2014-07-29 22:21:57 +00:00
Lang Hames
c8d9cf454f [MCJIT] XFAIL some RuntimeDyld tests on MIPS - RuntimeDyldChecker isn't properly
endian-aware yet, and this is causing failures when cross-linking on MIPS.

llvm-svn: 214231
2014-07-29 21:48:22 +00:00
Rafael Espindola
52959c50e9 Use nullptr instead of NULL.
llvm-svn: 214229
2014-07-29 21:46:05 +00:00
Alex Lorenz
9503511918 Coverage: improve efficiency of the counter propagation to the expansion regions.
This patch reduces the complexity of the two inner loops in order to speed up 
the loading of coverage data for very large functions.

llvm-svn: 214228
2014-07-29 21:42:24 +00:00
Lang Hames
1d332e5199 [MCJIT] Make sure we print the full 64-bit result of exprs in RuntimeDyldChecker.
llvm-svn: 214227
2014-07-29 21:38:20 +00:00
Rafael Espindola
debf00a333 Remove unused includes.
llvm-svn: 214226
2014-07-29 21:38:05 +00:00
Matt Arsenault
ccbab61a53 R600/SI: Implement getLdStBaseRegImmOfs
llvm-svn: 214225
2014-07-29 21:34:55 +00:00
Duncan P. N. Exon Smith
307d072e82 UseListOrder: Try to resolve buildbot failure
MSVC [1] thinks `UseListShuffleVector` needs a copy constructor, but I
don't.  Let's see if being explicit about `UseListOrder` is convincing.

[1]: http://lab.llvm.org:8011/builders/lld-x86_64-win7/builds/11664/steps/build_Lld/logs/stdio

Here's the failure:

C:/lld-x86_64_win7/lld-x86_64-win7/llvm.src/include\llvm/IR/UseListOrder.h(92): error C2248: 'llvm::UseListShuffleVector::operator =' : cannot access private member declared in class 'llvm::UseListShuffleVector' (C:\lld-x86_64_win7\lld-x86_64-win7\llvm.src\lib\Bitcode\Writer\ValueEnumerator.cpp) [C:\lld-x86_64_win7\lld-x86_64-win7\llvm.obj\lib\Bitcode\Writer\LLVMBitWriter.vcxproj]
          C:/lld-x86_64_win7/lld-x86_64-win7/llvm.src/include\llvm/IR/UseListOrder.h(56) : see declaration of 'llvm::UseListShuffleVector::operator ='
          C:/lld-x86_64_win7/lld-x86_64-win7/llvm.src/include\llvm/IR/UseListOrder.h(32) : see declaration of 'llvm::UseListShuffleVector'
          This diagnostic occurred in the compiler generated function 'llvm::UseListOrder &llvm::UseListOrder::operator =(const llvm::UseListOrder &)'

llvm-svn: 214224
2014-07-29 21:30:21 +00:00
Rafael Espindola
50859a1427 Delete dead code.
The gold plugin doesn't call lseek or read directly any more.

llvm-svn: 214221
2014-07-29 21:09:43 +00:00
Rafael Espindola
74ac2cd9f3 Have a single enum for "not a bitcode" error.
This is more convenient for callers. No functionality change, this will
be used in a next patch to the gold plugin.

llvm-svn: 214218
2014-07-29 21:01:24 +00:00
Matt Arsenault
d64b11dc6c R600/SI: Enable named operand table for DS instructions
llvm-svn: 214217
2014-07-29 21:00:56 +00:00
Matt Arsenault
5d4212bf5b Remove line with no effect
llvm-svn: 214216
2014-07-29 21:00:53 +00:00
Rafael Espindola
959d066783 gold plugin: Fix handling of corrupted bitcode files.
We should still claim them and tell gold about the error.

llvm-svn: 214214
2014-07-29 20:46:19 +00:00
Duncan P. N. Exon Smith
6ff3f85013 UseListShuffleVector: Remove copy constructor
Remove the copy constructor added in r214178 to appease MSVC17 since it
shouldn't be called at all.  My guess is that explicitly deleting it
will make the compiler happy.  To round out the operations I've also
deleted copy assignment and added move assignment.  Otherwise no
functionality change.

llvm-svn: 214213
2014-07-29 20:45:52 +00:00
Duncan P. N. Exon Smith
3d59d5afdc UseListShuffleVector: Code reorganization, NFC
llvm-svn: 214212
2014-07-29 20:45:49 +00:00
Lang Hames
46768ed40a [MCJIT] Make the RuntimeDyldChecker stub_addr builtin use file names rather than
full paths for its first argument.

This allows us to remove the annoying sed lines in the test cases, and write
direct references to file names in stub_addr calls (rather than <filename>
placeholders).

llvm-svn: 214211
2014-07-29 20:40:37 +00:00
Eli Bendersky
b838a71565 Fix FileCheck crash when empty prefix is passed.
llvm-svn: 214210
2014-07-29 20:30:53 +00:00
Rafael Espindola
06b2000418 Move the bitcode error enum to the include directory.
This will let users in other libraries know which error occurred. In particular,
it will be possible to check if the parsing failed or if the file is not
bitcode.

llvm-svn: 214209
2014-07-29 20:22:46 +00:00
Alex Lorenz
7522b90640 Coverage: fix the missing output stream in recursive call to CoverageMappingContext::dump
llvm-svn: 214206
2014-07-29 19:58:16 +00:00
Juergen Ributzka
2fe879698c [RuntimeDyld][AArch64] Make encode/decodeAddend also work on big-endian hosts.
llvm-svn: 214205
2014-07-29 19:57:15 +00:00
Juergen Ributzka
53d208d4b9 [RuntimeDyld][AArch64] Make encode/decodeAddend more typesafe by using the relocation enum type. NFCI.
llvm-svn: 214204
2014-07-29 19:57:11 +00:00
Rafael Espindola
ace129d81b Small gold plugin simplifications.
* Use a range loop.
* Store the extra options as "const char *".

llvm-svn: 214199
2014-07-29 19:17:44 +00:00
Joerg Sonnenberger
f3709585f9 Add a number of aliases for SPR access.
llvm-svn: 214196
2014-07-29 18:55:43 +00:00
Matt Arsenault
001ee9417a R600/SI: Add isMUBUF / isMTBUF
Also add missing comments about how the flags work.

llvm-svn: 214195
2014-07-29 18:51:56 +00:00
Matt Arsenault
751b041f67 R600/SI: Set bits on SMRD instructions
Set mayStore = 0 and enable named operand table.

llvm-svn: 214194
2014-07-29 18:51:54 +00:00