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

79929 Commits

Author SHA1 Message Date
Filipe Cabecinhas
f74b0c7c40 [BitcodeReader] Make sure abbrev records have at least one operand (record code)
Bug found with AFL fuzz.

llvm-svn: 238265
2015-05-26 23:52:21 +00:00
Owen Anderson
1db6d7f8ed Add initial support for the convergent attribute.
llvm-svn: 238264
2015-05-26 23:48:40 +00:00
Filipe Cabecinhas
2da00c394b [BitcodeReader] Sanity check on Comdat ID
Shouldn't be an assert, since user input can trigger it.

Bug found with AFL fuzz.

llvm-svn: 238261
2015-05-26 23:00:56 +00:00
Philip Reames
1497966324 [PlaceSafepoints] Entry safepoint location doesn't need to be a terminator
Long ago, the poll insertion code assumed that the insertion site was a terminator.  As a result, the entry selection code would split a basic block to ensure it could pass a terminator.  The insertion code was updated quite a while ago - possibly before it ever landed upstream - but the now redundant work was never removed.  

While I'm at it, remove a comment which doesn't apply to the upstreamed code.  

NFC intended.

llvm-svn: 238254
2015-05-26 21:16:42 +00:00
Philip Reames
82dc6b4b06 [PlaceSafepoints] Cleanup InsertSafepointPoll function
While working on another change, I noticed that the naming in this function was mildly deceptive.  While fixing that, I took the oppurtunity to modernize some of the code.  NFC intended.

llvm-svn: 238252
2015-05-26 21:03:23 +00:00
Kostya Serebryany
dd85a5b4fc [lib/Fuzzer] make the fuzzing timeout 1200 seconds by default (was: infinity)
llvm-svn: 238251
2015-05-26 20:57:47 +00:00
Rafael Espindola
84e886354e Simplify boolean conditional return statements.
Patch by Richard <legalize@xmission.com>.

llvm-svn: 238250
2015-05-26 20:37:36 +00:00
Akira Hatanaka
6f08fc2ca6 Remove NoFramePointerElim and NoFramePointerElimOverride from TargetOptions and
remove ExecutionEngine's dependence on CodeGen. NFC.

This is a follow-up to r238080.

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

llvm-svn: 238244
2015-05-26 20:17:20 +00:00
Adrian Prantl
d3d1f85857 Use "auto &" in range-based for-loop and remove the extra braces.
llvm-svn: 238243
2015-05-26 20:06:51 +00:00
Adrian Prantl
b1b02bafa3 Fix a use-after-free in a DEBUG output.
llvm-svn: 238242
2015-05-26 20:06:48 +00:00
Kostya Serebryany
6903bb7921 [lib/Fuzzer] fix docs
llvm-svn: 238236
2015-05-26 19:32:52 +00:00
Kostya Serebryany
9de53cc3c2 [lib/Fuzzer] fix build with assertions
llvm-svn: 238235
2015-05-26 19:29:33 +00:00
Rafael Espindola
d0b9369094 Print "lock \t foo" instead of "lock \n foo".
This gets gas and llc -filetype=obj to agree on the order of prefixes.

For llvm-mc we need to fix the asm parser to know that it makes a difference
on which line the "lock" is in.

Part of pr23594.

llvm-svn: 238232
2015-05-26 18:35:10 +00:00
Jan Vesely
856e4fb817 R600: Use SIGN_EXTEND_INREG for SEXT loads
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Matt Arsenault <Matthew.Arsenault@amd.com>
llvm-svn: 238229
2015-05-26 18:07:22 +00:00
Jan Vesely
c3ec893938 R600: Add comments to subword private address load lowering code
v2: Use C++ comments and end with periods

Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Matt Arsenault <Matthew.Arsenault@amd.com>
llvm-svn: 238228
2015-05-26 18:07:21 +00:00
Diego Novillo
4ef8ed56e4 Revert "Re-commit changes in r237579 with fix for bug breaking windows builds."
This reverts commit r238201 to fix linking problems in x86 Linux
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20150525/278413.html

llvm-svn: 238223
2015-05-26 17:45:38 +00:00
Matt Arsenault
b8bed2fb8d CodeGenPrepare: Don't match addressing modes through addrspacecast
This was resulting in the addrspacecast being removed and incorrectly
replaced with a ptrtoint when sinking.

llvm-svn: 238217
2015-05-26 16:59:43 +00:00
Rui Ueyama
cd68d85cf8 Object: Add Archive::getNumberOfSymbols().
Add a function that returns number of symbols in archive headers.

llvm-svn: 238213
2015-05-26 16:20:40 +00:00
Tom Stellard
11f35d3a02 R600/SI: Add assembler support for all CI and VI VOP2 instructions
llvm-svn: 238211
2015-05-26 15:55:52 +00:00
Rafael Espindola
0e92f19a7e Replace getOrCreateSectionData with registerSection.
There is now no SectionData to be created.

llvm-svn: 238208
2015-05-26 15:07:25 +00:00
Rafael Espindola
1c87cbde41 Have getCurrentSectionData return a MCSection.
I will fix the name shortly.

llvm-svn: 238204
2015-05-26 14:48:11 +00:00
Rafael Espindola
e67d49ec65 Pass a MCSection to getCurrentSectionData.
A step towards merging MCSection and MCSectionData.

llvm-svn: 238203
2015-05-26 14:42:52 +00:00
Luke Cheeseman
e0014ad127 Re-commit changes in r237579 with fix for bug breaking windows builds.
llvm-svn: 238201
2015-05-26 13:40:31 +00:00
Luke Cheeseman
27ebd5e2f5 Test Commit
llvm-svn: 238199
2015-05-26 13:10:35 +00:00
Elena Demikhovsky
1abbfebd87 AVX-512: fixed a bug in arithmetic operations lowering for i1 type
https://llvm.org/bugs/show_bug.cgi?id=23630

llvm-svn: 238198
2015-05-26 12:37:17 +00:00
Elena Demikhovsky
5d72ee6887 AVX-512: fixed a bug in lowering VSELECT for 512-bit vector
https://llvm.org/bugs/show_bug.cgi?id=23634

llvm-svn: 238195
2015-05-26 11:32:39 +00:00
Michael Kuperstein
9b9d97f26a Use std::bitset for SubtargetFeatures.
Previously, subtarget features were a bitfield with the underlying type being uint64_t. 
Since several targets (X86 and ARM, in particular) have hit or were very close to hitting this bound, switching the features to use a bitset.
No functional change.

The first several times this was committed (e.g. r229831, r233055), it caused several buildbot failures.
Apparently the reason for most failures was both clang and gcc's inability to deal with large numbers (> 10K) of bitset constructor calls in tablegen-generated initializers of instruction info tables. 
This should now be fixed.

llvm-svn: 238192
2015-05-26 10:47:10 +00:00
Daniel Sanders
adc4fb19a2 [mips] Make TTypeEncoding indirect to allow .eh_frame to be read-only.
Summary:
Following on from r209907 which made personality encodings indirect, do the
same for TType encodings. This fixes the case where a try/catch block needs
to generate references to, for example, std::exception in the
.gcc_except_table.

This commit uses DW_EH_PE_sdata8 for N64 as far as is possible at the moment.
However, it is possible to end up with DW_EH_PE_sdata4 when a TargetMachine is
not available. There's no risk of issues with inconsistency here since the
tables are self describing but it does mean there is a small chance of the
PC-relative offset being out of range for particularly large programs.

Reviewers: petarj

Reviewed By: petarj

Subscribers: srhines, joerg, tberghammer, llvm-commits

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

llvm-svn: 238190
2015-05-26 10:19:18 +00:00
Craig Topper
d7a132b310 [TableGen] Fix line wrapping logic for the autogenerated header to use math that makes more sense (at least to me).
The old code had a bug if the description was between 75 and 85 characters or so as it substracted PSLen from Desc.size() instead of MAX_LINE_LEN in the compare. It also calculated odd values for PosE on the last split and just let StringRef::slice take care of it being larger than the description string.

llvm-svn: 238187
2015-05-26 08:07:56 +00:00
Craig Topper
f2dd173b6e [TableGen] Rewrite an assert to not do a bunch unsigned math and then try to ensure the result is a positive number.
I think the fact that it was explicitly excluding 0 kept this from being a tautology. The exclusion of 0 for the old math was also a bug that's easily hit if the description gets split into multiple lines.

llvm-svn: 238186
2015-05-26 08:07:49 +00:00
Craig Topper
7aac58564f [TableGen] Put a space between '*' and description in the autogenerated tablegen header. Minor cleanup in surrounding code.
llvm-svn: 238185
2015-05-26 08:07:45 +00:00
Craig Topper
ece2a0d659 [TableGen] Fix indentation. NFC
llvm-svn: 238181
2015-05-26 06:48:47 +00:00
Craig Topper
f9ae48d70b [TableGen] Include header for each cpp file first. NFC
llvm-svn: 238180
2015-05-26 06:48:46 +00:00
Craig Topper
05dc62a73c [TableGen] Remove unneeded namespace around a function. Just put llvm:: on the definition since it's already declared in a header file.
llvm-svn: 238178
2015-05-26 06:48:41 +00:00
Craig Topper
eeaddaa803 [TableGen] Use 'static' instead of an anonymous namespace.
llvm-svn: 238177
2015-05-26 06:48:38 +00:00
Rafael Espindola
e78e9457dc Remove most uses of MCSectionData from MCAssembler.
llvm-svn: 238172
2015-05-26 02:17:21 +00:00
Rafael Espindola
73c4e75193 Stop using MCSectionData in MCAsmLayout.h.
llvm-svn: 238170
2015-05-26 02:00:36 +00:00
Rafael Espindola
54231e91c6 Move MCSection destruction to MCContext::reset.
Fixes the leaks when running llc.

Also found by an asan bot.

llvm-svn: 238167
2015-05-26 01:52:19 +00:00
Rafael Espindola
4f9f9a1d0f Stop using MCSectionData in MCMachObjectWriter.h.
llvm-svn: 238165
2015-05-26 01:15:30 +00:00
Rafael Espindola
0173a2073d Stop using MCSectionData in MCExpr.h.
llvm-svn: 238163
2015-05-26 00:52:18 +00:00
Rafael Espindola
aea8a3a003 Return a MCSection from MCFragment::getParent().
Another step in merging MCSectionData and MCSection.

llvm-svn: 238162
2015-05-26 00:36:57 +00:00
Rafael Espindola
4542f2778f Call the destructors of the MCSections.
They now contain the fragments. If we don't call the destructors the
fragments leak.

Found by an asan bot.

llvm-svn: 238161
2015-05-26 00:32:28 +00:00
Rafael Espindola
fc487a3241 Store a MCSection in MCFragment.
Part of the work to merge MCSectionData into MCSection.

llvm-svn: 238160
2015-05-25 23:48:22 +00:00
Rafael Espindola
6260f6cc49 Turn MCSectionData into a field of MCSection.
This also changes MCAssembler to store a vector of MCSections instead of an
iplist of MCSectionData.

llvm-svn: 238159
2015-05-25 23:14:17 +00:00
Rafael Espindola
f9294a6e82 Move MCSectionData to MCSection.h.
Another step in merging MCSectionData and MCSection.

llvm-svn: 238158
2015-05-25 22:57:48 +00:00
Rafael Espindola
3e5f02d14b Make a few MCSectionELF& variables const. NFC.
This just reduces the noise from another patch.

llvm-svn: 238156
2015-05-25 21:56:55 +00:00
Rafael Espindola
d0d5342abc Insert MCSectionData into the section list directly in getOrCreateSectionData.
Removing the logic from the constructor will make it easier to merge
MCSectionData and MCSection.

llvm-svn: 238155
2015-05-25 20:39:23 +00:00
Craig Topper
6fc0c57742 Use range-based for loops. NFC.
llvm-svn: 238154
2015-05-25 20:01:18 +00:00
Bjorn Steinbrink
8603eb4818 Remove conflicting attributes before adding deduced readonly/readnone
Summary:
In case of functions that have a pointer argument and only pass it to
each other, the function attributes pass deduces that the pointer should
get the readnone attribute, but fails to remove a readonly attribute
that may already have been present.

Reviewers: nlewycky

Subscribers: llvm-commits

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

llvm-svn: 238152
2015-05-25 19:46:38 +00:00
Rafael Espindola
e59724b6cc Move HasInstructions to MCSection.
llvm-svn: 238150
2015-05-25 18:34:26 +00:00