platform/upstream/llvm.git
11 years agoNo need to use a Set when a vector would do.
Nadav Rotem [Thu, 27 Jun 2013 00:14:13 +0000 (00:14 +0000)]
No need to use a Set when a vector would do.

llvm-svn: 185047

11 years agoRemove the process's reservation cache and don't
Sean Callanan [Thu, 27 Jun 2013 00:10:26 +0000 (00:10 +0000)]
Remove the process's reservation cache and don't
bother checking if a region is safe to use.  In
cases where regions need to be synthesized rather
than properly allocated, the memory reads required
to determine whether the area is used are

- insufficient, because intermediate locations
  could be in use, and

- unsafe, because on some platforms reading from
  memory can trigger events.

All this only makes a difference on platforms
where memory allocation in the target is impossible.
Behavior on platforms where it is possible should
stay the same.

<rdar://problem/14023970>

llvm-svn: 185046

11 years agoRemoved two logging printf statements from the APFloat tests... = /.
Michael Gottesman [Thu, 27 Jun 2013 00:00:45 +0000 (00:00 +0000)]
Removed two logging printf statements from the APFloat tests... = /.

llvm-svn: 185045

11 years ago[APFloat] Added unittest for APFloat.multiply that checks special cases, result categ...
Michael Gottesman [Wed, 26 Jun 2013 23:55:26 +0000 (23:55 +0000)]
[APFloat] Added unittest for APFloat.multiply that checks special cases, result categories, and result status.

llvm-svn: 185044

11 years ago[APFloat] Added unittest for APFloat.subtract that checks special cases, result categ...
Michael Gottesman [Wed, 26 Jun 2013 23:55:23 +0000 (23:55 +0000)]
[APFloat] Added unittest for APFloat.subtract that checks special cases, result categories, and result status.

llvm-svn: 185043

11 years agoSimplify code.
Eli Friedman [Wed, 26 Jun 2013 23:47:39 +0000 (23:47 +0000)]
Simplify code.

llvm-svn: 185042

11 years agoSLP: When searching for vectorization opportunities scan the blocks in post-order...
Nadav Rotem [Wed, 26 Jun 2013 23:44:45 +0000 (23:44 +0000)]
SLP: When searching for vectorization opportunities scan the blocks in post-order because we grow chains upwards.

llvm-svn: 185041

11 years agoSLP: Dont erase instructions during vectorization because it prevents the outerloops...
Nadav Rotem [Wed, 26 Jun 2013 23:43:23 +0000 (23:43 +0000)]
SLP: Dont erase instructions during vectorization because it prevents the outerloops from iterating over the instructions.

llvm-svn: 185040

11 years agoHandle all TemplateArguments in trivial TypeLocs.
Eli Friedman [Wed, 26 Jun 2013 23:30:50 +0000 (23:30 +0000)]
Handle all TemplateArguments in trivial TypeLocs.

Armed with a much better understanding of what
TemplateSpecializationTypeLoc::initializeArgLocs actually does, I now
understand that it's fine to just use an empty TemplateArgumentLocInfo
for Integral, Declaration, and NullPtr TemplateArguments.

Fixes PR14281. (The testcases are actually derived from libcxx_test in
deduction-crash.cpp because the original testcase was impossible to reduce.)

llvm-svn: 185038

11 years agoIn InstCombine{AddSub,MulDivRem} convert APFloat.isFiniteNonZero() && !APFloat.isDeno...
Michael Gottesman [Wed, 26 Jun 2013 23:17:31 +0000 (23:17 +0000)]
In InstCombine{AddSub,MulDivRem} convert APFloat.isFiniteNonZero() && !APFloat.isDenormal => APFloat.isNormal.

llvm-svn: 185037

11 years ago[APFloat] Convert all references to fcNormal to references to isFiniteNonZero().
Michael Gottesman [Wed, 26 Jun 2013 23:17:28 +0000 (23:17 +0000)]
[APFloat] Convert all references to fcNormal to references to isFiniteNonZero().

Currently inside APFloat fcNormal still implies the old definition of Normal
(i.e. isFiniteNonZero) instead of the proper IEEE-754R definition that the
external method isNormal() uses.

This patch prepares for the internal switch inside APFloat by converting all
references that check if a category is fcNormal directly with an indirect call
via isFiniteNonZero().

llvm-svn: 185036

11 years agoPR16467: Teach -Wunsequenced that in C11 (unlike C++11), an assignment's
Richard Smith [Wed, 26 Jun 2013 23:16:51 +0000 (23:16 +0000)]
PR16467: Teach -Wunsequenced that in C11 (unlike C++11), an assignment's
side-effect is not sequenced before its value computation. Also fix a
mishandling of ?: expressions where the condition is constant that was
exposed by the tests for this.

llvm-svn: 185035

11 years ago<rdar://problem/14281898>
Han Ming Ong [Wed, 26 Jun 2013 22:52:37 +0000 (22:52 +0000)]
<rdar://problem/14281898>

Much faster way to get dirty size.

llvm-svn: 185033

11 years agoRevert "Debug Info: clean up usage of Verify." as it's breaking bots.
Eric Christopher [Wed, 26 Jun 2013 22:44:57 +0000 (22:44 +0000)]
Revert "Debug Info: clean up usage of Verify." as it's breaking bots.

This reverts commit r185020

llvm-svn: 185032

11 years agoFix a crash bug in dumping options with groups
Reid Kleckner [Wed, 26 Jun 2013 22:43:37 +0000 (22:43 +0000)]
Fix a crash bug in dumping options with groups

Option groups don't have prefixes.  Option dumping is basically dead
code unless there is something wrong with the option table, so this
isn't an important crasher.

llvm-svn: 185031

11 years agoClarify and doxygen-ify comments
Stephen Lin [Wed, 26 Jun 2013 22:27:50 +0000 (22:27 +0000)]
Clarify and doxygen-ify comments

llvm-svn: 185030

11 years agoSema: Small cleanup around TemplateParamListContext
David Majnemer [Wed, 26 Jun 2013 22:25:55 +0000 (22:25 +0000)]
Sema: Small cleanup around TemplateParamListContext

llvm-svn: 185029

11 years agoUpdate the platform options help strings.
Greg Clayton [Wed, 26 Jun 2013 22:24:05 +0000 (22:24 +0000)]
Update the platform options help strings.

llvm-svn: 185028

11 years agoFixed the process_events.py example to be able to specify the platform and also use...
Greg Clayton [Wed, 26 Jun 2013 22:23:45 +0000 (22:23 +0000)]
Fixed the process_events.py example to be able to specify the platform and also use the debugger's listener.

llvm-svn: 185027

11 years ago[Mips Disassembler] Have the DecodeCCRRegisterClass function use the getReg
Chad Rosier [Wed, 26 Jun 2013 22:23:32 +0000 (22:23 +0000)]
[Mips Disassembler] Have the DecodeCCRRegisterClass function use the getReg
function to lookup the proper tablegen'ed register enumeration.  Previously,
it was using the encoded value directly.

llvm-svn: 185026

11 years agoObjectiveC: diagnose duplicate declaration of
Fariborz Jahanian [Wed, 26 Jun 2013 22:10:27 +0000 (22:10 +0000)]
ObjectiveC: diagnose duplicate declaration of
private ivars in class extensions and class
@implementation. // rdar://14278560

llvm-svn: 185025

11 years agoARM: Proactively ensure that the LowerCallResult hack for 'this'-returns is not used...
Stephen Lin [Wed, 26 Jun 2013 21:42:14 +0000 (21:42 +0000)]
ARM: Proactively ensure that the LowerCallResult hack for 'this'-returns is not used for incompatible calling conventions.

(Currently, ARM 'this'-returns are handled in the standard calling convention case by treating R0 as preserved and doing some extra magic in LowerCallResult; this may not apply to calling conventions added in the future so this patch provides and documents an interface for indicating such)

llvm-svn: 185024

11 years agoDon't use unnamed local enums as template arguments.
Joerg Sonnenberger [Wed, 26 Jun 2013 21:31:47 +0000 (21:31 +0000)]
Don't use unnamed local enums as template arguments.
Fixes -Werror bootstrap.

llvm-svn: 185023

11 years agoThis patch fixes PR16395, when HandleMSProperty returns null due to a declaration...
Aaron Ballman [Wed, 26 Jun 2013 21:28:44 +0000 (21:28 +0000)]
This patch fixes PR16395, when HandleMSProperty returns null due to a declaration with no name.

Patch thanks to Robert Wilhelm.

llvm-svn: 185022

11 years agoAST: small cleanup to FriendObjectKind
David Majnemer [Wed, 26 Jun 2013 21:28:41 +0000 (21:28 +0000)]
AST: small cleanup to FriendObjectKind

llvm-svn: 185021

11 years agoDebug Info: clean up usage of Verify.
Manman Ren [Wed, 26 Jun 2013 21:26:10 +0000 (21:26 +0000)]
Debug Info: clean up usage of Verify.

No functionality change.
It should suffice to check the type of a debug info metadata, instead of
calling Verify.

llvm-svn: 185020

11 years agoSync file handling logic in RewriterTestContext.h and RefactoringTest.cpp.
Rafael Espindola [Wed, 26 Jun 2013 21:02:22 +0000 (21:02 +0000)]
Sync file handling logic in RewriterTestContext.h and RefactoringTest.cpp.

They are mostly duplicated and got out of sync during the PathV1 removal. We
should factor the code somewhere, but for now a FIXME will do.

llvm-svn: 185019

11 years agoRewrite record layout for ms_struct structs.
Eli Friedman [Wed, 26 Jun 2013 20:50:34 +0000 (20:50 +0000)]
Rewrite record layout for ms_struct structs.

The old implementation of ms_struct in RecordLayoutBuilder was a
complete mess: it depended on complicated conditionals which didn't
really reflect the underlying logic, and placed a burden on users of
the resulting RecordLayout. This commit rips out almost all of the
old code, and replaces it with simple checks in
RecordLayoutBuilder::LayoutBitField.

This commit also fixes <rdar://problem/14252115>, a bug where class
inheritance would cause us to lay out bitfields incorrectly.

llvm-svn: 185018

11 years ago<rdar://problem/14262854>
Han Ming Ong [Wed, 26 Jun 2013 20:46:27 +0000 (20:46 +0000)]
<rdar://problem/14262854>

Match up with top’s implementation on recent Cab as API has changed a bit.
Tested the same binary running on Zin as well. Tested ARM binary on iOS as well.

llvm-svn: 185017

11 years agoMinor formatting fix to ARMBaseRegisterInfo::getCalleeSavedRegs
Stephen Lin [Wed, 26 Jun 2013 20:19:06 +0000 (20:19 +0000)]
Minor formatting fix to ARMBaseRegisterInfo::getCalleeSavedRegs

llvm-svn: 185016

11 years agoRename PathV2 to just Path now that it is the only one.
Rafael Espindola [Wed, 26 Jun 2013 19:33:03 +0000 (19:33 +0000)]
Rename PathV2 to just Path now that it is the only one.

llvm-svn: 185015

11 years agoUpdating the same comment in a different file, again for links. No functional change...
Aaron Ballman [Wed, 26 Jun 2013 19:33:02 +0000 (19:33 +0000)]
Updating the same comment in a different file, again for links.  No functional change intended.

llvm-svn: 185014

11 years agoUpdating a link in the comments; no functional change.
Aaron Ballman [Wed, 26 Jun 2013 19:17:19 +0000 (19:17 +0000)]
Updating a link in the comments; no functional change.

llvm-svn: 185013

11 years ago[mips] Do not emit ".option pic0" if target is mips64.
Akira Hatanaka [Wed, 26 Jun 2013 19:08:49 +0000 (19:08 +0000)]
[mips] Do not emit ".option pic0" if target is mips64.

llvm-svn: 185012

11 years ago[mips] Improve code generation for constant multiplication using shifts, adds and
Akira Hatanaka [Wed, 26 Jun 2013 18:48:17 +0000 (18:48 +0000)]
[mips] Improve code generation for constant multiplication using shifts, adds and
subs.

llvm-svn: 185011

11 years agoRemove unneeded limbo state flag.
Matt Kopec [Wed, 26 Jun 2013 18:46:08 +0000 (18:46 +0000)]
Remove unneeded limbo state flag.

llvm-svn: 185010

11 years agolibclc: Add assembly versions of vstore for global [u]int4/8/16
Tom Stellard [Wed, 26 Jun 2013 18:22:20 +0000 (18:22 +0000)]
libclc: Add assembly versions of vstore for global [u]int4/8/16

The assembly should be generic, but at least currently R600 only supports
32-bit stores of [u]int1/4, and I believe that only global is well-supported.

R600 lowers the 8/16 component stores to multiple 4-component stores.

The unoptimized C versions of the other stuff is left in place.

Patch by: Aaron Watry

llvm-svn: 185009

11 years agolibclc: Add assembly versions of vload for global int4/8/16
Tom Stellard [Wed, 26 Jun 2013 18:22:15 +0000 (18:22 +0000)]
libclc: Add assembly versions of vload for global int4/8/16

The assembly should be generic, but at least currently R600 only supports
32-bit loads of int1/4, and I believe that only global is well-supported.

R600 lowers the 8/16 component vectors to multiple 4-bit loads.

The unoptimized C versions of the other stuff is left in place.

Patch by: Aaron Watry

llvm-svn: 185008

11 years agolibclc: Initial vstore implementation
Tom Stellard [Wed, 26 Jun 2013 18:22:11 +0000 (18:22 +0000)]
libclc: Initial vstore implementation

Assumes that the target supports byte-addressable stores.

Completely unoptimized.

Patch by: Aaron Watry

llvm-svn: 185007

11 years agolibclc: Initial vload implementation
Tom Stellard [Wed, 26 Jun 2013 18:22:05 +0000 (18:22 +0000)]
libclc: Initial vload implementation

Should work for all targets and data types.  Completely unoptimized.

Patch by: Aaron Watry

llvm-svn: 185006

11 years agor600: Fix implementations of get_group_id.ll and get_local_size.ll
Tom Stellard [Wed, 26 Jun 2013 18:22:00 +0000 (18:22 +0000)]
r600: Fix implementations of get_group_id.ll and get_local_size.ll

llvm-svn: 185005

11 years agolibclc: Implement clz() builtin
Tom Stellard [Wed, 26 Jun 2013 18:21:55 +0000 (18:21 +0000)]
libclc: Implement clz() builtin

Squashed commit of the following:

commit a0df0a0e86c55c1bdc0b9c0f5a739e5adef4b056
Author: Aaron Watry <awatry@gmail.com>
Date:   Mon Apr 15 18:42:04 2013 -0500

    libclc: Rename clz.ll to clz_if.ll to ensure it gets built.

    configure.py treats files that have the same name with the .cl and .ll
    extensions as overriding eachother.

    E.g. If you have clz.cl and clz.ll both specified to be built in the same
    SOURCES file, only the first file listed will actually be built.

    Since the contents of clz.ll were an interface that is implemented in
    clz_impl.ll, rename clz.ll to clz_if.ll to make sure that the interface is
    built.

commit 931b62bed05c58f737de625bd415af09571a6a5a
Author: Aaron Watry <awatry@gmail.com>
Date:   Sat Apr 13 12:32:54 2013 -0500

    libclc: llvm assembly implementation of clz

    Untested... currently crashes in the same manner as add_sat.

commit 6ef0b7b0b6d2e5584086b4b9a9243743b2e0538f
Author: Aaron Watry <awatry@gmail.com>
Date:   Sat Mar 23 12:35:27 2013 -0500

    libclc: Add stub clz builtin

    For scalar int/uint, attempt to use the clz llvm builtin.. for all others
    return 0 until an actual implementation is finished.

Patch by: Aaron Watry

llvm-svn: 185004

11 years agolibclc: Add clamp(vec, scalar, scalar) and max(vec, scalar)
Tom Stellard [Wed, 26 Jun 2013 18:21:49 +0000 (18:21 +0000)]
libclc: Add clamp(vec, scalar, scalar) and max(vec, scalar)

For any GENTYPE that isn't scalar, we need to implement a mixed
vector/scalar version of clamp/max.

This depends on the min() patches I sent to the list a few minutes ago.

Patch by: Aaron Watry

llvm-svn: 185003

11 years agolibclc: Implement the min(vec, scalar) version of the min builtin.
Tom Stellard [Wed, 26 Jun 2013 18:21:44 +0000 (18:21 +0000)]
libclc: Implement the min(vec, scalar) version of the min builtin.

Checks if the current GENTYPE is scalar, and if not, then defines a separate
implementation of the function which casts the second arg to vector before
proceeding.

Patch by: Aaron Watry

llvm-svn: 185002

11 years agolibclc: implement initial version of min()
Tom Stellard [Wed, 26 Jun 2013 18:21:38 +0000 (18:21 +0000)]
libclc: implement initial version of min()

This doesn't handle the integer cases for min(vector, scalar).

Patch by: Aaron Watry

llvm-svn: 185001

11 years agolibclc: Rename [add|sub]_sat.ll to [add|sub]_sat_if.ll
Tom Stellard [Wed, 26 Jun 2013 18:21:31 +0000 (18:21 +0000)]
libclc: Rename [add|sub]_sat.ll to [add|sub]_sat_if.ll

configure.py allows overloading *.cl with *.ll, but will only ever build
the first file listed in SOURCES of ${file}.cl and ${file}.ll

add_sat, sub_sat, (and the soon to be submitted clz) all define interfaces in
${function_name}.ll which are implemented in ${function_name}_impl.ll.

Renaming the interface files is enough to get them to build again, fixing
CL usage of these functions.

Tested on clover/r600g.

Patch by: Aaron Watry

llvm-svn: 185000

11 years agoAdd a another TODO note.
Tom Stellard [Wed, 26 Jun 2013 18:21:25 +0000 (18:21 +0000)]
Add a another TODO note.

Patch by: Aaron Watry

llvm-svn: 184999

11 years agoAdd a TODO note.
Tom Stellard [Wed, 26 Jun 2013 18:21:22 +0000 (18:21 +0000)]
Add a TODO note.

Patch by: Aaron Watry

llvm-svn: 184998

11 years agoSimplify rotate implementation a bit..
Tom Stellard [Wed, 26 Jun 2013 18:21:18 +0000 (18:21 +0000)]
Simplify rotate implementation a bit..

Much more understandable/readable as a result, and probably more efficient.

Patch by: Aaron Watry

llvm-svn: 184997

11 years agolibclc: implement rotate builtin
Tom Stellard [Wed, 26 Jun 2013 18:21:13 +0000 (18:21 +0000)]
libclc: implement rotate builtin

This implementation does a lot of bit shifting and masking. Suffice to say,
this is somewhat suboptimal... but it does look to produce correct results
(after the piglit tests were corrected for sign extension issues).

Someone who knows LLVM better than I could re-write this more efficiently.

Patch by: Aaron Watry

llvm-svn: 184996

11 years agolibclc: Move max builtin to shared/
Tom Stellard [Wed, 26 Jun 2013 18:21:06 +0000 (18:21 +0000)]
libclc: Move max builtin to shared/

Max(x,y) is available for all integer/floating types.

Patch by: Aaron Watry

llvm-svn: 184995

11 years agolibclc: Add clamp() builtin for integer/floating point
Tom Stellard [Wed, 26 Jun 2013 18:20:56 +0000 (18:20 +0000)]
libclc: Add clamp() builtin for integer/floating point

Created under a new shared/ directory for functions which are available for
both integer and floating point types.

Patch by: Aaron Watry

llvm-svn: 184994

11 years agolibclc: Fix abs_diff builtin integer function
Tom Stellard [Wed, 26 Jun 2013 18:20:50 +0000 (18:20 +0000)]
libclc: Fix abs_diff builtin integer function

Patch by: Aaron Watry

llvm-svn: 184993

11 years agolibclc: Add max() builtin function
Tom Stellard [Wed, 26 Jun 2013 18:20:46 +0000 (18:20 +0000)]
libclc: Add max() builtin function

Adds this function for both int and floating data types.

Patch by: Aaron Watry

llvm-svn: 184992

11 years agoconfigure: Enable building separate libraries for target variants
Tom Stellard [Wed, 26 Jun 2013 18:20:38 +0000 (18:20 +0000)]
configure: Enable building separate libraries for target variants

llvm-svn: 184991

11 years agoconfigure: fix out-of-source build
Tom Stellard [Wed, 26 Jun 2013 18:20:35 +0000 (18:20 +0000)]
configure: fix out-of-source build

Patch by: Niels Ole Salscheider

llvm-svn: 184990

11 years agoFix build with LLVM 3.3
Tom Stellard [Wed, 26 Jun 2013 18:20:32 +0000 (18:20 +0000)]
Fix build with LLVM 3.3

Patch by: Niels Ole Salscheider

llvm-svn: 184989

11 years agoImplement ceil() builtin
Tom Stellard [Wed, 26 Jun 2013 18:20:30 +0000 (18:20 +0000)]
Implement ceil() builtin

llvm-svn: 184988

11 years agoImplement fmax() and fmin() builtins
Tom Stellard [Wed, 26 Jun 2013 18:20:25 +0000 (18:20 +0000)]
Implement fmax() and fmin() builtins

llvm-svn: 184987

11 years agoRemove the static keyword from the _CLC_INLINE macro
Tom Stellard [Wed, 26 Jun 2013 18:20:18 +0000 (18:20 +0000)]
Remove the static keyword from the _CLC_INLINE macro

static functions are not allowed in OpenCL C

llvm-svn: 184986

11 years agoUse brackets around include files in length.cl and normalize.cl
Tom Stellard [Wed, 26 Jun 2013 18:20:15 +0000 (18:20 +0000)]
Use brackets around include files in length.cl and normalize.cl

These functions were not being compiled

llvm-svn: 184985

11 years agoFix typo in include/clc/geometric/length.inc
Tom Stellard [Wed, 26 Jun 2013 18:20:12 +0000 (18:20 +0000)]
Fix typo in include/clc/geometric/length.inc

llvm-svn: 184984

11 years agor600: Add overrides file
Tom Stellard [Wed, 26 Jun 2013 18:20:08 +0000 (18:20 +0000)]
r600: Add overrides file

llvm-svn: 184983

11 years agoAllow targets to override generic implementations
Tom Stellard [Wed, 26 Jun 2013 18:20:05 +0000 (18:20 +0000)]
Allow targets to override generic implementations

Targets can override generic implementations by adding a file called
OVERRIDES in $(TARGET_DIR)/lib and listing the generic implementations
that it wants to override.  For example, to override get_group_id() and
get_global_size() you would add these lines to the OVERRIDES file:

workitem/get_group_id.cl
workitem/get_global_size.cl

llvm-svn: 184982

11 years agoMake libclc more Linux FHS conform.
Tom Stellard [Wed, 26 Jun 2013 18:20:03 +0000 (18:20 +0000)]
Make libclc more Linux FHS conform.

- First introducing a versioning scheme
- Add --libexecdir, --includedir and --pkgconfigdir and prefill them as well as --prefix
- Build all targets by default
- Create clc.pc and install it in $pkgconfigdir
- Use clang++ instead of c++
- Rename builtins.bc to built_libs/$triple.bc and install them in $libexecdir
- Includes are installed recursively to $includedir
- Finally add $(DESTDIR) for 'make install'

Patch by: Johannes Obermayr

llvm-svn: 184981

11 years agoR600: Replace cl implementations with LLVM IR implementation
Tom Stellard [Wed, 26 Jun 2013 18:20:00 +0000 (18:20 +0000)]
R600: Replace cl implementations with LLVM IR implementation

This allows libclc to be built for R600 with upstream clang and LLVM.

llvm-svn: 184980

11 years agoPTX: move implementations of work-item and synchronisation functions
Tom Stellard [Wed, 26 Jun 2013 18:19:54 +0000 (18:19 +0000)]
PTX: move implementations of work-item and synchronisation functions
to lib, and add header files in generic.  Incorporates a patch by
Tom Stellard!

llvm-svn: 184979

11 years agoMove R600 headers into generic directory
Tom Stellard [Wed, 26 Jun 2013 18:19:50 +0000 (18:19 +0000)]
Move R600 headers into generic directory

llvm-svn: 184978

11 years agor600: Add get_global_size() implementation
Tom Stellard [Wed, 26 Jun 2013 18:19:44 +0000 (18:19 +0000)]
r600: Add get_global_size() implementation

llvm-svn: 184977

11 years agor600: Fix get_global_id implementation
Tom Stellard [Wed, 26 Jun 2013 18:19:39 +0000 (18:19 +0000)]
r600: Fix get_global_id implementation

llvm-svn: 184976

11 years agor600: Initial support
Tom Stellard [Wed, 26 Jun 2013 18:18:59 +0000 (18:18 +0000)]
r600: Initial support

This includes a get_global_id() implementation and function stubs for
the other workitem and synchronization functions.

llvm-svn: 184975

11 years ago[APFloat] Removed debugging cruft that snuck in.
Michael Gottesman [Wed, 26 Jun 2013 17:59:36 +0000 (17:59 +0000)]
[APFloat] Removed debugging cruft that snuck in.

llvm-svn: 184974

11 years agoThe SLP Vectorizer works across basic blocks. Update the docs.
Nadav Rotem [Wed, 26 Jun 2013 17:59:35 +0000 (17:59 +0000)]
The SLP Vectorizer works across basic blocks. Update the docs.

llvm-svn: 184973

11 years agoFix warning: commas at the end of enumerator lists are a C++11 extension [-Wc++11...
Nico Weber [Wed, 26 Jun 2013 17:31:55 +0000 (17:31 +0000)]
Fix warning: commas at the end of enumerator lists are a C++11 extension [-Wc++11-extensions]

llvm-svn: 184972

11 years agoUse enums instead of raw octal values.
Rafael Espindola [Wed, 26 Jun 2013 17:28:04 +0000 (17:28 +0000)]
Use enums instead of raw octal values.

Patch by 罗勇刚(Yonggang Luo).

llvm-svn: 184971

11 years agoAdd support for passing '-target armv8' through the Driver.
Joey Gouly [Wed, 26 Jun 2013 17:19:48 +0000 (17:19 +0000)]
Add support for passing '-target armv8' through the Driver.

llvm-svn: 184970

11 years agoErase all of the instructions that we RAUWed
Nadav Rotem [Wed, 26 Jun 2013 17:16:09 +0000 (17:16 +0000)]
Erase all of the instructions that we RAUWed

llvm-svn: 184969

11 years agoMatch MSVC's handling of commas during macro argument expansion
Reid Kleckner [Wed, 26 Jun 2013 17:16:08 +0000 (17:16 +0000)]
Match MSVC's handling of commas during macro argument expansion

This allows clang to parse the type_traits header in Visual Studio 2012,
which is included widely in practice.

This is a rework of r163022 by João Matos.  The original patch broke
preprocessing of gtest headers, which this patch addresses.

Patch by Will Wilson!

llvm-svn: 184968

11 years agoAdd a subtarget feature 'v8' to the ARM backend.
Joey Gouly [Wed, 26 Jun 2013 16:58:26 +0000 (16:58 +0000)]
Add a subtarget feature 'v8' to the ARM backend.
This allows for targeting the ARMv8 AArch32 variant.

llvm-svn: 184967

11 years agoDo not add cse-ed instructions into the visited map because we dont want to consider...
Nadav Rotem [Wed, 26 Jun 2013 16:54:53 +0000 (16:54 +0000)]
Do not add cse-ed instructions into the visited map because we dont want to consider them as a candidate for replacement of instructions to be visited.

llvm-svn: 184966

11 years agoARM: fix more cases where predication may or may not be allowed
Tim Northover [Wed, 26 Jun 2013 16:52:40 +0000 (16:52 +0000)]
ARM: fix more cases where predication may or may not be allowed

Unfortunately this addresses two issues (by the time I'd disentangled the logic
it wasn't worth putting it back to half-broken):

+ Coprocessor instructions should all be predicable in Thumb mode.
+ BKPT should never be predicable.

llvm-svn: 184965

11 years agoARM: allow predicated barriers in Thumb mode
Tim Northover [Wed, 26 Jun 2013 16:52:32 +0000 (16:52 +0000)]
ARM: allow predicated barriers in Thumb mode

The barrier instructions are only "always-execute" in ARM mode, they can quite
happily sit inside an IT block in Thumb.

llvm-svn: 184964

11 years ago[tsan] Fix build.
Sergey Matveev [Wed, 26 Jun 2013 16:49:34 +0000 (16:49 +0000)]
[tsan] Fix build.

llvm-svn: 184963

11 years agoRemove the 'generic' CPU from the ARM eabi attributes printer.
Joey Gouly [Wed, 26 Jun 2013 16:39:06 +0000 (16:39 +0000)]
Remove the 'generic' CPU from the ARM eabi attributes printer.
Make v4 the default ARM architecture attribute, to match CodeGen.

llvm-svn: 184962

11 years agoRevert "Temporarily disable building the armv7 variants of profile_ios on"
Bob Wilson [Wed, 26 Jun 2013 16:35:16 +0000 (16:35 +0000)]
Revert "Temporarily disable building the armv7 variants of profile_ios on"

This reverts commit r184816.  With Chandler's change in r184929, this should
no longer be necessary.

llvm-svn: 184961

11 years agoPathV1 is deprecated since the 18th of Dec 2010. Remove it.
Rafael Espindola [Wed, 26 Jun 2013 16:24:35 +0000 (16:24 +0000)]
PathV1 is deprecated since the 18th of Dec 2010. Remove it.

llvm-svn: 184960

11 years agoDon't use PathV1.h in IncludeExcludeTest.cpp.
Rafael Espindola [Wed, 26 Jun 2013 16:20:55 +0000 (16:20 +0000)]
Don't use PathV1.h in IncludeExcludeTest.cpp.

llvm-svn: 184959

11 years agoDon't use PathV1.h in TransformTest.cpp.
Rafael Espindola [Wed, 26 Jun 2013 15:48:36 +0000 (15:48 +0000)]
Don't use PathV1.h in TransformTest.cpp.

llvm-svn: 184958

11 years ago[tsan] Move some suppressions-related code to common.
Sergey Matveev [Wed, 26 Jun 2013 15:37:14 +0000 (15:37 +0000)]
[tsan] Move some suppressions-related code to common.

Factor out code to be reused in LSan. Also switch from linked list to vector.

llvm-svn: 184957

11 years agoDon't use PathV1.h in PerfSupport.cpp.
Rafael Espindola [Wed, 26 Jun 2013 15:22:42 +0000 (15:22 +0000)]
Don't use PathV1.h in PerfSupport.cpp.

llvm-svn: 184956

11 years agoAdd a convenience functions that don't return if the directory existed.
Rafael Espindola [Wed, 26 Jun 2013 15:21:13 +0000 (15:21 +0000)]
Add a convenience functions that don't return if the directory existed.

llvm-svn: 184955

11 years agoRemove unused include.
Rafael Espindola [Wed, 26 Jun 2013 15:12:41 +0000 (15:12 +0000)]
Remove unused include.

llvm-svn: 184954

11 years agoDon't explicitly set update version
Ed Maste [Wed, 26 Jun 2013 15:10:31 +0000 (15:10 +0000)]
Don't explicitly set update version

Host::GetOSVersion's caller already sets it to UINT32_MAX to determine
which version number components are set.

llvm-svn: 184953

11 years agoclang/test/Driver/pth.c: Fix r184942, a regexp like "\\\\" is redundant here. Should...
NAKAMURA Takumi [Wed, 26 Jun 2013 15:03:20 +0000 (15:03 +0000)]
clang/test/Driver/pth.c: Fix r184942, a regexp like "\\\\" is redundant here. Should be matched to single \ with '\\'.

llvm-svn: 184952

11 years agoRemove last use of PathV1.h from clang.
Rafael Espindola [Wed, 26 Jun 2013 15:01:50 +0000 (15:01 +0000)]
Remove last use of PathV1.h from clang.

Instead of creating a temporary directory, remember the set of temporary files
we create.

llvm-svn: 184951

11 years ago[sanitizer] readdir and readdir_r interceptors.
Evgeniy Stepanov [Wed, 26 Jun 2013 15:00:53 +0000 (15:00 +0000)]
[sanitizer] readdir and readdir_r interceptors.

llvm-svn: 184950

11 years agoWe only create one file, no need to delete a directory.
Rafael Espindola [Wed, 26 Jun 2013 14:33:23 +0000 (14:33 +0000)]
We only create one file, no need to delete a directory.

llvm-svn: 184949

11 years agoFix the lldb build.
Rafael Espindola [Wed, 26 Jun 2013 14:10:56 +0000 (14:10 +0000)]
Fix the lldb build.

llvm-svn: 184948

11 years agoRemove unused includes.
Rafael Espindola [Wed, 26 Jun 2013 13:54:34 +0000 (13:54 +0000)]
Remove unused includes.

llvm itself is now PathV1 clean.

llvm-svn: 184947

11 years ago[PowerPC] Accept 17-bit signed immediates for addis
Ulrich Weigand [Wed, 26 Jun 2013 13:49:53 +0000 (13:49 +0000)]
[PowerPC] Accept 17-bit signed immediates for addis

The assembler currently strictly verifies that immediates for
s16imm operands are in range (-32768 ... 32767).  This matches
the behaviour of the GNU assembler, with one exception: gas
allows, as a special case, operands in an extended range
(-65536 .. 65535) for the addis instruction only (and its
extended mnemonic lis).

The main reason for this seems to be to allow using unsigned
16-bit operands for lis, e.g. like lis %r1, 0xfedc.

Since this has been supported by gas for a long time, and
assembler source code seen "in the wild" actually exploits
this feature, this patch adds equivalent support to LLVM
for compatibility reasons.

llvm-svn: 184946