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

63158 Commits

Author SHA1 Message Date
Akira Hatanaka
41ad5610bf [mips] Mark pseudo instructions as code-gen only.
llvm-svn: 188017
2013-08-08 21:44:39 +00:00
Akira Hatanaka
4f90298c6e [mips] Delete register class HWRegs64.
No functionality change.

llvm-svn: 188016
2013-08-08 21:37:32 +00:00
David Fang
3e8c045f48 cast fix to appease buildbot
llvm-svn: 188014
2013-08-08 21:29:30 +00:00
Arnold Schwaighofer
ddea7f3974 Revert "Reapply r185872 now that the address sanitizer has been changed to support this."
This reverts commit r187939. It broke an O0 build of a spec benchmark.

llvm-svn: 188012
2013-08-08 21:04:16 +00:00
David Fang
772a101ff0 initial draft of PPCMachObjectWriter.cpp
this records relocation entries in the mach-o object file
for PIC code generation.
tested on powerpc-darwin8, validated against darwin otool -rvV

llvm-svn: 188004
2013-08-08 20:14:40 +00:00
Alexey Samsonov
1021d4d06d Fix off-by-one error in Regex::isValid
llvm-svn: 187992
2013-08-08 17:32:45 +00:00
Niels Ole Salscheider
20c4077bf5 R600/SI: Implement fp32<->fp64 conversions
llvm-svn: 187988
2013-08-08 16:06:15 +00:00
Niels Ole Salscheider
74ee40da2a R600/SI: Implement sint<->fp64 conversions
llvm-svn: 187987
2013-08-08 16:06:08 +00:00
Jakub Staszak
cb5ff9e1e0 Use pop_back() instead of pop_back_val() when the returned value is not used.
llvm-svn: 187986
2013-08-08 15:48:46 +00:00
Silviu Baranga
0291b43e25 Remove the now redundant FeatureFP16 from the Cortex-A15 feature list. It was made redundant when FeatureVFP4 was added which implies FP16.
llvm-svn: 187985
2013-08-08 15:47:33 +00:00
Jakub Staszak
7d775148c4 Fix the comment.
llvm-svn: 187984
2013-08-08 15:19:25 +00:00
Mihai Popa
cda7008bd4 The name "tCDP" isn't used anywhere else in the source code, so renaming it for consistency doesn't cause any problems.
This is the only Thumb2 instruction defined with "t" prefix; all other Thumb2 instructions have "t2" prefix (e.g. "t2CDP2" which is defined immediately afterwards).

Patch by Artyom Skrobov.

llvm-svn: 187973
2013-08-08 10:20:41 +00:00
Evgeniy Stepanov
eb8342b22f Disable inlining between sanitized and non-sanitized functions.
Inlining between functions with different values of sanitize_* attributes
leads to over- or under-sanitizing, which is always bad.

llvm-svn: 187967
2013-08-08 08:22:39 +00:00
Eric Christopher
49a1db3fce For DW_TAG_template_type_parameter the actual passed in type could
be void and therefore not have a type entry. Only add the type if
it is non-void and provide a testcase.

llvm-svn: 187966
2013-08-08 08:09:43 +00:00
Craig Topper
093dffb1a8 Remove AllUndef check from one of the loops in getVectorShuffle. It was already handled by the 'AllLHS && AllRHS' check after the previous loop.
llvm-svn: 187965
2013-08-08 08:03:12 +00:00
Eric Christopher
19fba84128 The conversion to bool is fine here, no need to check isType.
llvm-svn: 187964
2013-08-08 07:40:42 +00:00
Eric Christopher
e6639b8535 Make sure that if we're going to attempt to add a type to a DIE that
the type exists.

Fix up cases where we weren't checking for optional types and add
an assert to addType to make sure we catch this in the future.

Fix up a testcase that was using the tag for DW_TAG_array_type
when it meant DW_TAG_enumeration_type.

llvm-svn: 187963
2013-08-08 07:40:37 +00:00
Eric Christopher
4725619d96 Change variable name and reflow formatting.
llvm-svn: 187962
2013-08-08 07:40:31 +00:00
Craig Topper
8a5e83ba97 Optimize mask generation for one of the DAG combiner shufflevector cases.
llvm-svn: 187961
2013-08-08 07:38:55 +00:00
Hal Finkel
e76170ce53 PPC: Map frin to round() not nearbyint() and rint()
Making use of the recently-added ISD::FROUND, which allows for custom lowering
of round(), the PPC backend will now map frin to round(). Previously, we had
been using frin to lower nearbyint() (and rint() via some custom lowering to
handle the extra fenv flags requirements), but only in fast-math mode because
frin does not tie-to-even. Several users had complained about this behavior,
and this new mapping of frin to round is certainly more appropriate (and does
not require fast-math mode).

In effect, this reverts r178362 (and part of r178337, replacing the nearbyint
mapping with the round mapping).

llvm-svn: 187960
2013-08-08 04:31:34 +00:00
David Majnemer
e90cbda29f Revert "coff also doesn't have a ReadOnlySection yet, (!)"
This reverts commit r77814.

We were sticking global constants in the .data section instead of in the
.rdata section when emitting for COFF.

This fixes PR16831.

llvm-svn: 187956
2013-08-08 01:50:52 +00:00
Eric Christopher
160c346748 Reflow for loop.
llvm-svn: 187954
2013-08-08 01:41:05 +00:00
Eric Christopher
c16b1aaf3f Be more rigorous about the sizes of forms and attributes.
llvm-svn: 187953
2013-08-08 01:41:00 +00:00
Alexander Kornienko
8030dee9b6 Changed isPrint for U+00AD SOFT HYPHEN to return true.
Summary:
This is consistent with MacOSX implementation, and most terminals
actually display this character (checked on gnome-terminal, lxterminal, lxterm,
Terminal.app, iterm2). Actually, this is in line with the ISO Latin 1 standard
(ISO 8859-1), which defines it differently from the Unicode Standard. More
information here: http://www.cs.tut.fi/~jkorpela/shy.html

Reviewers: gribozavr, jordan_rose

CC: llvm-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D1310

llvm-svn: 187949
2013-08-08 01:10:50 +00:00
Michael Gottesman
d0acc77647 Revert "[objc-arc] Track if we encountered an additive overflow while computing {TopDown,BottomUp}PathCounts and do nothing if it occured."
This reverts commit r187941.

The commit was passing on my os x box, but it is failing on some non-osx
platforms. I do not have time to look into it now, so I am reverting and will
recommit after I figure this out.

llvm-svn: 187946
2013-08-08 00:41:18 +00:00
Peter Collingbourne
34bf946403 Fix ARM build.
llvm-svn: 187944
2013-08-08 00:15:27 +00:00
Michael Gottesman
a8c38e944e [objc-arc] Track if we encountered an additive overflow while computing {TopDown,BottomUp}PathCounts and do nothing if it occured.
rdar://14590914

llvm-svn: 187941
2013-08-07 23:56:41 +00:00
Michael Gottesman
630805fc43 [objc-arc] Change 4 iterator methods which return const_iterators to be const methods.
llvm-svn: 187940
2013-08-07 23:56:34 +00:00
Bill Wendling
169723f925 Reapply r185872 now that the address sanitizer has been changed to support this.
Original commit message:

Stop emitting weak symbols into the "coal" sections.

The Mach-O linker has been able to support the weak-def bit on any symbol for
quite a while now. The compiler however continued to place these symbols into a
"coal" section, which required the linker to map them back to the base section
name.

Replace the sections like this:

  __TEXT/__textcoal_nt   instead use  __TEXT/__text
  __TEXT/__const_coal    instead use  __TEXT/__const
  __DATA/__datacoal_nt   instead use  __DATA/__data

<rdar://problem/14265330>

llvm-svn: 187939
2013-08-07 23:42:09 +00:00
Hal Finkel
bdc7aa32c1 Add ISD::FROUND for libm round()
All libm floating-point rounding functions, except for round(), had their own
ISD nodes. Recent PowerPC cores have an instruction for round(), and so here I'm
adding ISD::FROUND so that round() can be custom lowered as well.

For the most part, this is straightforward. I've added an intrinsic
and a matching ISD node just like those for nearbyint() and friends. The
SelectionDAG pattern I've named frnd (because ISD::FP_ROUND has already claimed
fround).

This will be used by the PowerPC backend in a follow-up commit.

llvm-svn: 187926
2013-08-07 22:49:12 +00:00
Peter Collingbourne
efa9025062 DataFlowSanitizer; LLVM changes.
DataFlowSanitizer is a generalised dynamic data flow analysis.

Unlike other Sanitizer tools, this tool is not designed to detect a
specific class of bugs on its own.  Instead, it provides a generic
dynamic data flow analysis framework to be used by clients to help
detect application-specific issues within their own code.

Differential Revision: http://llvm-reviews.chandlerc.com/D965

llvm-svn: 187923
2013-08-07 22:47:18 +00:00
Eric Christopher
0cff1be367 Using the integrated assembler we'd fail to change section to the
.tbss section for zerofill thread locals. Make sure we do this
before emitting the zerofills.

Fixes PR15972.

llvm-svn: 187913
2013-08-07 21:13:06 +00:00
Eric Christopher
e1e6b4c0c0 Fix a FIXME, on darwin all virtual sections have a zerofill type.
llvm-svn: 187912
2013-08-07 21:13:01 +00:00
Reid Kleckner
bac8fb7396 On Windows, autolink advapi32 from Path.inc for CryptAcquireContextW
This allows llvm-tblgen to link successfully when compiling with clang.

Both MSBuild and CMake will automatically add advapi32 as part of a set
of other dlls comprising the win32 API to the link line, but CMake
doesn't do that when compiling with clang.  Until someone adds that info
to cmake upstream, this seems like a reasonable work around.

llvm-svn: 187907
2013-08-07 20:19:31 +00:00
Eric Christopher
9b6f209c8c Move assert above first use of variable that we'd be asserting on.
llvm-svn: 187899
2013-08-07 18:51:09 +00:00
Andrew Trick
5cf2601ba8 Confusing comment typo.
llvm-svn: 187895
2013-08-07 17:20:32 +00:00
Elena Demikhovsky
ae2624a373 AVX-512 set: Added BROADCAST instructions
with lowering logic and a test.

llvm-svn: 187884
2013-08-07 12:34:55 +00:00
Richard Sandiford
b6323e0b21 [SystemZ] Optimize floating-point comparisons with zero
This follows the same lines as the integer code.  In the end it seemed
easier to have a second 4-bit mask in TSFlags to specify the compare-like
CC values.  That eats one more TSFlags bit than adding a CCHasUnordered
would have done, but it feels more concise.

llvm-svn: 187883
2013-08-07 11:10:06 +00:00
Richard Sandiford
5960348422 [SystemZ] Add floating-point load-and-test instructions
These instructions can also be used as comparisons with zero.

llvm-svn: 187882
2013-08-07 11:03:34 +00:00
Benjamin Kramer
fbbec483df JumpThreading: Turn a select instruction into branching if it allows to thread one half of the select.
This is a common pattern coming out of simplifycfg generating gross code.

a:                                       ; preds = %entry
  %sel = select i1 %cmp1, double %add, double 0.000000e+00
  br label %b

b:
  %cond5 = phi double [ %sel, %a ], [ %sub, %entry ]
  %cmp6 = fcmp oeq double %cond5, 0.000000e+00
  br i1 %cmp6, label %if.then, label %if.end

becomes

a:
  br i1 %cmp1, label %b, label %if.then

b:
  %cond5 = phi double [ %sub, %entry ], [ %add, %a ]
  %cmp6 = fcmp oeq double %cond5, 0.000000e+00
  br i1 %cmp6, label %if.then, label %if.end

Skipping block b completely if possible.

llvm-svn: 187880
2013-08-07 10:29:38 +00:00
Chandler Carruth
0ac9f05175 Add support for linking against a curses library when available and
using it to detect whether or not a terminal supports colors. This
replaces a particularly egregious hack that merely compared the TERM
environment variable to "dumb". That doesn't really translate to
a reasonable experience for users that have actually ensured their
terminal's capabilities are accurately reflected.

This makes testing a terminal for color support somewhat more expensive,
but it is called very rarely anyways. The important fast path when the
output is being piped somewhere is already in place.

The global lock may seem excessive, but the spec for calling into curses
is *terrible*. The whole library is terrible, and I spent quite a bit of
time looking for a better way of doing this before convincing myself
that this was the fundamentally correct way to behave. The damage of the
curses library is very narrowly confined, and we continue to use raw
escape codes for actually manipulating the colors which is a much sane
system than directly using curses here (IMO).

If this causes trouble for folks, please let me know. I've tested it on
Linux and will watch the bots carefully. I've also worked to account for
the variances of curses interfaces that I could finde documentation for,
but that may not have been sufficient.

llvm-svn: 187874
2013-08-07 08:47:36 +00:00
Eric Christopher
e4c1a6601b Remove some parens. No functional change.
llvm-svn: 187872
2013-08-07 08:35:10 +00:00
Craig Topper
059c59a568 Simplify code. No functional change intended.
llvm-svn: 187870
2013-08-07 08:16:07 +00:00
Evgeniy Stepanov
c40b186c69 Initialize SIInsertWaits::ExpInstrTypesSeen in the pass constructor.
This value may be used uninitialized in SIInsertWaits::insertWait.
Found with MemorySanitizer.

llvm-svn: 187869
2013-08-07 07:47:41 +00:00
Dmitri Gribenko
b5e0b0c493 YAMLTraits.h: replace DenseMap that used a bad implementation of DenseMapInfo
for StringRef with a StringMap

The bug is that the empty key compares equal to the tombstone key.

Also added an assertion to DenseMap to catch similar bugs in future.

llvm-svn: 187866
2013-08-07 05:51:27 +00:00
Reed Kotler
30cf33a57e Create a pattern for the "trap" instruction.
llvm-svn: 187863
2013-08-07 04:00:26 +00:00
Reid Kleckner
6f129a9240 Fix boolean logic in LockFileManager and test it
This fixes a bug from r187826.

Reviewers: hans

Differential Revision: http://llvm-reviews.chandlerc.com/D1304

llvm-svn: 187846
2013-08-07 01:22:04 +00:00
Reid Kleckner
a642cec078 Avoid using alloca in Windows/Program.inc
One use needs to copy the alloca into a std::string, and the other use
is before calling CreateProcess, which is very heavyweight anyway.

llvm-svn: 187845
2013-08-07 01:21:33 +00:00
Eric Christopher
8aac1919bd Add a way to grab a particular attribute out of a DIE.
Use it when we're looking for a string in particular. Update comments
as well.

llvm-svn: 187844
2013-08-07 01:18:33 +00:00
Eric Christopher
c0368e09cd Move somewhat messy conditional out of line.
No functional change.

llvm-svn: 187843
2013-08-07 01:18:24 +00:00