Commit Graph

188109 Commits

Author SHA1 Message Date
Eric Fiselier a1c73a6d6d Unify and cleanup rpath handling in tests.
llvm-svn: 223594
2014-12-06 22:08:51 +00:00
Eric Fiselier b92da3f217 [libcxx] Add logic to probe compiler in tests.
Summary:
This patch probes the cxx compiler used during testing by getting it to dump its predefined macros. Based on the value of these macros the compiler name and compiler name + version are added to the available features.

There are three compiler names:
- `clang`
- `apple-clang`
- `gcc`.

The available features added are equivalent to:
- `'%s' % compiler_name`
- `'%s-%s.%s' % compiler_name, major_version, minor_version`

This information can be used to XFAIL tests on different compilers / versions.



Reviewers: mclow.lists, danalbert, jroelofs

Reviewed By: jroelofs

Subscribers: cfe-commits

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

llvm-svn: 223593
2014-12-06 21:13:15 +00:00
Eric Fiselier b9f99739bc Add support for building and testing libc++ without threads to CMake.
Currently hacks must be used in to configure and build libc++ without threads
when using CMake. This patch adds CMake options to enable/disable building with
threads and a monotonic clock.

This patch also propagates the configuration information to lit so the tests
are properly configured as well.

llvm-svn: 223591
2014-12-06 21:02:58 +00:00
Eric Fiselier 2050bedf03 Improve error message when _LIBCPP_HAS_NO_MONOTONIC_CLOCK is used improperly
llvm-svn: 223590
2014-12-06 20:09:11 +00:00
Benjamin Kramer 3280a5d9f5 Turn some DenseMaps that are only used for set operations into DenseSets.
DenseSet has better memory efficiency now.

llvm-svn: 223589
2014-12-06 19:22:54 +00:00
Benjamin Kramer 89e5306f43 Make the DenseMap bucket type configurable and use a smaller bucket for DenseSet.
DenseSet used to be implemented as DenseMap<Key, char>, which usually doubled
the memory footprint of the map. Now we use a compressed set so the second
element uses no memory at all. This required some surgery on DenseMap as
all accesses to the bucket now have to go through methods; this should
have no impact on the behavior of DenseMap though. The new default bucket
type for DenseMap is a slightly extended std::pair as we expose it through
DenseMap's iterator and don't want to break any existing users.

llvm-svn: 223588
2014-12-06 19:22:44 +00:00
Benjamin Kramer 8e5dc53784 Reapply "LLVMContext: Store APInt/APFloat directly into the ConstantInt/FP DenseMaps."
This reapplies r223478 with a fix for 32 bit targets.

llvm-svn: 223586
2014-12-06 13:12:56 +00:00
David Majnemer 64ba326b1e ConstantFold: Don't optimize comparisons with weak linkage objects
Consider:
void f() {}
void __attribute__((weak)) g() {}
bool b = &f != &g;

It's possble for g to resolve to f if --defsym=g=f is passed on to the
linker.

llvm-svn: 223585
2014-12-06 11:58:33 +00:00
David Majnemer ed00cd20ad I didn't intend to commit this change.
llvm-svn: 223584
2014-12-06 10:52:32 +00:00
David Majnemer 1af36e5baf InstSimplify: Optimize away useless unsigned comparisons
Code like X < Y && Y == 0 should always be folded away to false.

llvm-svn: 223583
2014-12-06 10:51:40 +00:00
NAKAMURA Takumi fc3062f65a Reformat.
llvm-svn: 223580
2014-12-06 05:57:06 +00:00
Tom Stellard 8d5f5e4238 R600/SI: Restore PrivateGlobalPrefix to the default ELF value of ".L"
This was changed in r223323.

llvm-svn: 223579
2014-12-06 05:34:34 +00:00
Paul Robinson 01105887ab Rename a couple of preprocessor symbols to be more descriptive. NFC.
Review feedback from recent changes to GetSVN.cmake.

llvm-svn: 223578
2014-12-06 05:06:37 +00:00
Richard Smith 223d3f2e4d [modules] If we import a module, and we've seen a module map that describes the
module, use the path from the module map file in preference to the path from
the .pcm file when resolving relative paths in the .pcm file. This allows
diagnostics (and .d output) to give relative paths if the module was found via
a relative path.

llvm-svn: 223577
2014-12-06 03:21:08 +00:00
NAKAMURA Takumi e7633631e1 Avoid angle brackets in comment. [-Wdocumentation-html]
llvm-svn: 223576
2014-12-06 03:11:46 +00:00
Sean Callanan 957a872cb1 Fixed an unfortunate reversed conditional that
resulted in hard-to-track-down crashes.  Sigh.

llvm-svn: 223575
2014-12-06 02:31:49 +00:00
Duncan P. N. Exon Smith 35303fd739 IR: Disallow function-local metadata attachments
Metadata attachments to instructions cannot be function-local.

This is part of PR21532.

llvm-svn: 223574
2014-12-06 02:29:44 +00:00
NAKAMURA Takumi 6980404cfe LLVMInstrumentation requires MC since r223532.
llvm-svn: 223573
2014-12-06 02:22:11 +00:00
Matt Arsenault e9b68b55c1 Fix typo
llvm-svn: 223572
2014-12-06 02:14:41 +00:00
Hans Wennborg a81d1dd5da Add a proper triple to switch-jump-table.ll
llvm-svn: 223571
2014-12-06 02:08:16 +00:00
NAKAMURA Takumi cfc0354aaa llvm/test/CodeGen/X86/switch-jump-table.ll: Add explicit triple. Local labels have a prefix "." for targeting i686-cygming.
llvm-svn: 223570
2014-12-06 02:03:49 +00:00
Kate Stone 641e9f8c69 Improvements to FastDemangler to correct parsing of <local-name> encodings for string literal and parameter/entity cases. Patch courtesy of slydiman.
llvm-svn: 223569
2014-12-06 01:42:41 +00:00
Jim Ingham 4623b9d3e2 Reverting r223548 which broke running in the shell on OS X.
llvm-svn: 223568
2014-12-06 01:41:10 +00:00
Ahmed Bougacha 8b54286d1c [X86] Refactor PMOV[SZ]Xrm to add missing AVX2 patterns.
Most patterns will go away once the extload legalization changes land.

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

llvm-svn: 223567
2014-12-06 01:31:07 +00:00
Hans Wennborg 08de833c1c SelectionDAG switch lowering: Replace unreachable default with most popular case.
This can significantly reduce the size of the switch, allowing for more
efficient lowering.

I also worked with the idea of exploiting unreachable defaults by
omitting the range check for jump tables, but always ended up with a
non-neglible binary size increase. It might be worth looking into some more.

SimplifyCFG currently does this transformation, but I'm working towards changing
that so we can optimize harder based on unreachable defaults.

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

llvm-svn: 223566
2014-12-06 01:28:50 +00:00
Jim Ingham 33df7cd345 Add the ability to set breakpoints with conditions, commands, etc,
in the "dummy-target".  The dummy target breakpoints prime all future
targets.  Breakpoints set before any target is created (e.g. breakpoints
in ~/.lldbinit) automatically get set in the dummy target.  You can also
list, add & delete breakpoints from the dummy target using the "-D" flag,
which is supported by most of the breakpoint commands.

This removes a long-standing wart in lldb...

<rdar://problem/10881487>

llvm-svn: 223565
2014-12-06 01:28:03 +00:00
Duncan P. N. Exon Smith da41af9e94 IR: Disallow complicated function-local metadata
Disallow complex types of function-local metadata.  The only valid
function-local metadata is an `MDNode` whose sole argument is a
non-metadata function-local value.

Part of PR21532.

llvm-svn: 223564
2014-12-06 01:26:49 +00:00
Kostya Serebryany 597dcc7a8d No memcpy for copy ctor with -fsanitize-address-field-padding=1
Summary:
When -fsanitize-address-field-padding=1 is present
don't emit memcpy for copy constructor.
Thanks Nico for the extra test case.

Test Plan: regression tests

Reviewers: thakis, rsmith

Reviewed By: rsmith

Subscribers: rsmith, cfe-commits

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

llvm-svn: 223563
2014-12-06 01:23:08 +00:00
Chris Matthews b36ba28d60 Fix for xunit output to work around issue in Jenkins when tests are at the root level
llvm-svn: 223562
2014-12-06 01:13:49 +00:00
Richard Smith 4a89a06d0d PR21217: Slightly more eagerly load -fmodule-map-file= files and provide
diagnostics if they don't exist. Based on a patch by John Thompson!

llvm-svn: 223561
2014-12-06 01:13:41 +00:00
Sean Callanan ceeb74e606 Now that we get types from modules, we occasionally
encounter clang::ExternalASTSources that are not instances
of ClangExternalASTSourceCommon.  We used to blithely
assume that all are, and so we could use static_cast<>.
That's no longer the case, so we have to have these AST
sources register themselves.

llvm-svn: 223560
2014-12-06 01:03:30 +00:00
Jim Ingham 67d7af9c34 Fix a type (MAX_PATH instead of PATH_MAX) and remove an unused variable.
llvm-svn: 223559
2014-12-06 01:03:17 +00:00
Sean Callanan 498ff1c1b8 Add new-lines after module compiler errors so
they are readable.

llvm-svn: 223557
2014-12-06 00:56:43 +00:00
Duncan P. N. Exon Smith b236211c4c Utils: Style cleanups, NFC
llvm-svn: 223556
2014-12-06 00:48:17 +00:00
Duncan P. N. Exon Smith b13f7d2e36 Utils: Avoid RAUW on metadata in CloneFunction()
llvm-svn: 223555
2014-12-06 00:48:13 +00:00
Nick Lewycky 05044c248e Canonicalize multiplies by looking at whether the operands have any constants themselves. Patch by Tim Murray!
llvm-svn: 223554
2014-12-06 00:45:50 +00:00
Neeraj Badlani 2163b05d8e [TEST-COMMIT] As per Developer Policy, Added a blank line.
llvm-svn: 223553
2014-12-06 00:38:39 +00:00
Tim Northover 5e84fe3ed4 AArch64: use explicit MVT::i64 when creating EXTRACT_SUBVECTOR nodes.
All our patterns use MVT::i64, but the ISelLowering nodes were inconsistent in
their choice.

No functional change.

llvm-svn: 223551
2014-12-06 00:33:37 +00:00
Jim Ingham 0ccb02c4e9 Add an initial description of the rules for constructing new SB API classes.
llvm-svn: 223550
2014-12-06 00:28:05 +00:00
Chris Matthews 8a7c194bc7 Fix corner cases in lit xunit for paths with dots
llvm-svn: 223549
2014-12-06 00:21:08 +00:00
Zachary Turner 00cdc98b7f Fix some posix assumptions related to running shell commands.
Differential Revision: http://reviews.llvm.org/D6553

Reviewed By: Greg Clayton

llvm-svn: 223548
2014-12-06 00:14:24 +00:00
Richard Smith 3464e321b8 Additional safety for the root cause of regression in r223443; make the module
map path more canonical before hashing it. No functionality change.

llvm-svn: 223547
2014-12-06 00:09:19 +00:00
Benjamin Kramer 0dc0e54272 Revert "LLVMContext: Store APInt/APFloat directly into the ConstantInt/FP DenseMaps."
Somehow made DenseMap probe on forever on 32 bit machines.
This reverts commit r223478.

llvm-svn: 223546
2014-12-06 00:02:31 +00:00
Jim Ingham 4701521ba0 Add a list iterable helper and use it to make a Breakpoint
iterator in the BreakpointList class.

llvm-svn: 223544
2014-12-05 23:21:30 +00:00
Jim Ingham 15fe293460 First pass at a description of the lldb coding conventions.
llvm-svn: 223543
2014-12-05 23:18:01 +00:00
Ahmed Bougacha 89bc485085 [X86] Cleanup FCOPYSIGN lowering. NFC intended.
llvm-svn: 223542
2014-12-05 23:11:36 +00:00
Zachary Turner 22ac8711a5 Fix some uninitialized variables in ClangExpressionParser.
Reviewed by: Sean Callanan

llvm-svn: 223541
2014-12-05 22:54:56 +00:00
Kuba Brecka ddac6cbb34 XFAILing suppression tests on Android. The suppression files are not being transfered to the device.
llvm-svn: 223540
2014-12-05 22:47:44 +00:00
Richard Smith 7ed1bc9eb0 [modules] Instead of storing absolute paths in a .pcm file, store the path to
the root of the module and use paths relative to that directory wherever
possible. This is a step towards allowing explicit modules to be relocated
without being rebuilt, which is important for some kinds of distributed builds,
for good paths in diagnostics, and for appropriate .d output.

This is a recommit of r223443, reverted in r223465; when joining together
imported file paths, we now use the system's separator rather than always
using '/'. This avoids path mismatches between the original module build and
the module user on Windows (at least, in some cases). A more comprehensive
fix will follow.

llvm-svn: 223539
2014-12-05 22:42:13 +00:00
Hans Wennborg 76b005398d ASTDumper: print whether a function is constexpr
llvm-svn: 223538
2014-12-05 22:38:57 +00:00