Commit Graph

210793 Commits

Author SHA1 Message Date
Maksim Panchenko 0510cd5161 [PrologEpilogInserter] Minor refactoring.
Differential Revision: http://reviews.llvm.org/D12924

llvm-svn: 248084
2015-09-19 04:42:15 +00:00
Saleem Abdulrasool d5556e34e4 Driver: avoid unnecessary string ops
Use an enumeration for the Floating Point ABIs supported on MIPS.  This is
replicating the ARM change to avoid string based tracking of the floating point
ABI.  NFC.

llvm-svn: 248083
2015-09-19 04:33:38 +00:00
Maksim Panchenko 07b754daf8 Test commit. Fix comment. NFC.
llvm-svn: 248082
2015-09-19 04:01:19 +00:00
Rui Ueyama 27e9e6540c Remove unused #includes.
llvm-svn: 248081
2015-09-19 02:28:32 +00:00
NAKAMURA Takumi e677e2f545 clang-tools-extra: Appease PR24881. [-Wdocumentation]
\returns doesn't accept \li, but \parblock \li.

llvm-svn: 248080
2015-09-19 02:21:28 +00:00
Richard Smith 664798c034 Add test that we correctly allow some non-letter unicode characters in
identifiers, and extend existing test to also cover C++.

llvm-svn: 248079
2015-09-19 02:14:12 +00:00
Rui Ueyama f4d05d7a80 COFF: Parallelize InputFile::parse().
InputFile::parse() can be called in parallel with other calls of
the same function. By doing that, time to self-link improves from
741 ms to 654 ms or 12% faster.

This is probably the last low hanging fruit in terms of parallelism.
Input file parsing and symbol table insertion takes 450 ms in total.
If we want to optimize further, we probably have to parallelize
symbol table insertion using concurrent hashmap or something.
That's doable, but that's not easy, especially if you want to keep
the exact same semantics and linking order. I'm not going to do that
at least soon.

Anyway, compared to r248019 (the change before the first attempt for
parallelism), we achieved 36% performance improvement from 1022 ms
to 654 ms. MSVC linker takes 3.3 seconds to link the same program.
MSVC's ICF feature is very slow for some reason, but even if we
disable the feature, it still takes about 1.2 seconds.
Our number is probably good enough.

llvm-svn: 248078
2015-09-19 01:48:26 +00:00
Adrian Prantl 2f957ac092 Further simplify CGDebugInfo::getOrCreateModuleRef().
DIBuilder ignoers DICompileUnits that are passed in as scopes anyway.

llvm-svn: 248077
2015-09-19 00:59:22 +00:00
Adrian Prantl 532365abe8 Use std::move on these arguments.
llvm-svn: 248076
2015-09-19 00:59:19 +00:00
Chaoren Lin f3057583e8 Fix Linux bot.
llvm-svn: 248075
2015-09-19 00:57:11 +00:00
David Majnemer 47ce0b81b0 [InstCombine] FoldICmpCstShrCst failed for ashr when comparing against -1
(icmp eq (ashr C1, %V) -1) may have multiple answers if C1 is not a
power of two and has the sign bit set.

This fixes PR24873.

llvm-svn: 248074
2015-09-19 00:48:31 +00:00
David Majnemer e5977ebecc [InstCombine] FoldICmpCstShrCst didn't handle icmps of -1 in the ashr case correctly
llvm-svn: 248073
2015-09-19 00:48:26 +00:00
Greg Clayton 1827fc25ab Added a curses based way to see the test suite running. Works only where curses is implemented. Try it out with:
./dotest.py --results-formatter=test_results.Curses --results-file=/dev/stdout

llvm-svn: 248072
2015-09-19 00:39:09 +00:00
Michael J. Spencer acf5bdfd88 [elf2] Improve relocation-undefined-weak.s test.
llvm-svn: 248071
2015-09-19 00:15:38 +00:00
Adrian Prantl 2d3d6dfe1c Rename ASTSourceDescriptor::ModuleName to FullModuleName for clarity.
llvm-svn: 248070
2015-09-19 00:10:37 +00:00
Adrian Prantl c6458d6a4d Refactor ASTReader::getSourceDescriptor(const Module &) into a constructor
of ASTSourceDescriptor. It was effectively a static function.

NFC.

llvm-svn: 248069
2015-09-19 00:10:32 +00:00
Adrian Prantl 8bd4c13f67 Eliminate a redundant check.
llvm-svn: 248068
2015-09-19 00:10:25 +00:00
Matt Arsenault cc5d106263 AMDGPU: Add failing testcase for live interval construction
llvm-svn: 248067
2015-09-19 00:03:56 +00:00
Todd Fiala 40b180e7ee test events: added optional value type to extra event key/val pairs
The test events had worker indexes coming across as strings.  I
want them to be ints.  worker_index now comes across as an int in
the dicationary.

The optional type can be specified with:
--event-add-entries key=val[:type][,key2=val2[:type2]...]
The type piece may be 'int' at this time.  That is all.  Otherwise
it will be a string.

llvm-svn: 248066
2015-09-18 23:46:30 +00:00
Gabor Horvath 659842d0fc [Static Analyzer] Fixed a false positive case in DynamicTypeChecker when dealing with forward declarations.
llvm-svn: 248065
2015-09-18 23:38:57 +00:00
Richard Trieu 324da7b207 Split off the binary literal warning into a subgroup of C++14 warnings
Binary literals predate C++14, but they are listed as a C++14 extension since
this was the first time they were standardized in the language.  Move the
warning into a subgroup so it can be selectively disabled when checking for
other C++14 features.

llvm-svn: 248064
2015-09-18 23:18:39 +00:00
Rui Ueyama 8197a4e0bf COFF: Use parallel_sort in Writer::sortExceptionTable().
This patch saves 4 ms out of 5 ms. Very small improvement,
but maybe better than nothing.

llvm-svn: 248063
2015-09-18 23:17:34 +00:00
Adrian Prantl 666892051c CGDebugInfo: Make creating a skeleton CU in getOrCreateModuleRef optional.
We don't want a skeleton CU when generating debug info for the module
itself.

NFC.

llvm-svn: 248062
2015-09-18 23:01:45 +00:00
Rui Ueyama 49e72e69e5 Fix build error that std::atomic is not copy-constructible.
llvm-svn: 248061
2015-09-18 22:58:12 +00:00
Todd Fiala f77f8ae450 test events: add test_filename to all test-related events.
The test_filename is the full path to the TestCase class's
implementation file.

llvm-svn: 248060
2015-09-18 22:57:04 +00:00
Todd Fiala e83f140833 test events: announce worker count in new initialize event
See the following for details:
http://reviews.llvm.org/D12987

llvm-svn: 248059
2015-09-18 22:45:31 +00:00
Rui Ueyama e629a45531 COFF: Address review comments.
- Fix race condition of `Redo`
- Avoid std::distance

llvm-svn: 248058
2015-09-18 22:31:15 +00:00
Enrico Granata f6fe302ee4 On Linux, if you can't actually locate the libc++ install, do not attempt to use it
The failure mode when one gets this wrong is quite gnarly to then walk oneself out of, and if you can't actually find the library, trying to build against it is fairly pointless anyway
This + my previous skip_if_library_missing change should make running the libc++ tests on a Linux machine without it much more seamless

llvm-svn: 248057
2015-09-18 22:26:34 +00:00
Michael J. Spencer 9779535c5d [elf2] Relocate against undefined weak symbols.
llvm-svn: 248056
2015-09-18 22:26:13 +00:00
Sean Callanan 9077e9f8f2 Moved ResolveSymbolicLink() to the FileSystem where it belongs, thanks
zturner!

http://reviews.llvm.org/D12984

llvm-svn: 248055
2015-09-18 22:24:57 +00:00
Michael J. Spencer 658dccd1c8 [elf2] Relocate against common symbols.
llvm-svn: 248054
2015-09-18 22:13:25 +00:00
Adrian Prantl 0391406e95 Simplify the interface of PCHContainerGenerator and friends
by passing in a CompilerInstance instead of all its individual members.

NFC.

llvm-svn: 248053
2015-09-18 22:10:59 +00:00
Rui Ueyama e0e0796d83 COFF: Parallelize Writer::writeSections().
Self-hosting took 801 ms on my machine. Of which this function took
69 ms. Now it takes 37 ms. That is about 4% overall performance
improvement.

llvm-svn: 248052
2015-09-18 22:07:10 +00:00
Rafael Espindola 54e9d238b6 Relax the test to get it passing with windows paths.
llvm-svn: 248051
2015-09-18 22:01:10 +00:00
Ismail Pazarbasi d347e7a920 Analyzer: Fix a crasher in UbigraphViz
Summary:
Name `Out` refers to the parameter. It is moved into the member `Out`
in ctor-init. Dereferencing null pointer will crash clang, if user
passes '-analyzer-viz-egraph-ubigraph' argument.

Reviewers: zaks.anna, krememek

Subscribers: cfe-commits

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

llvm-svn: 248050
2015-09-18 21:54:47 +00:00
Michael J. Spencer 9567495154 [elf2] Convert if/else cascade into a covered switch. NFC.
llvm-svn: 248049
2015-09-18 21:48:38 +00:00
Sean Callanan db7d8083cd Added support for resolving symbolic links to FileSpec.
We use the symbolic link to resolver to find the target of the LLDB shlib
symlink if there is a symlink.  This allows us to find shlib-relative  resources
even when running under the testsuite, where _lldb.so is a symlink in the Python
resource directory.

Also changed a comment to be slightly more clear about what resolve_path in the
constructor for FileSpec means, since if we were actually using realpath() this
code wouldn't have been necessary.

http://reviews.llvm.org/D12984

llvm-svn: 248048
2015-09-18 21:39:31 +00:00
Keno Fischer c021abfaff Fix Makefile build by adding LLVMSupport to liblldb
`llvm-mi` now depends on the regex functionality available in LLVM's
support library.

llvm-svn: 248047
2015-09-18 21:32:10 +00:00
Eric Christopher c48497a2f8 Reduce indentation in the TargetInfo implementations and fix up
a couple of macro builtin redefines.

llvm-svn: 248046
2015-09-18 21:26:24 +00:00
Sanjoy Das f69d0e3384 [IndVars] Widen more comparisons for non-negative induction vars
Summary:
If an induction variable is provably non-negative, its sign extension is
equal to its zero extension.  This means narrow uses like

  icmp slt iNarrow %indvar, %rhs

can be widened into

  icmp slt iWide zext(%indvar), sext(%rhs)

Reviewers: atrick, mcrosier, hfinkel

Subscribers: hfinkel, reames, llvm-commits

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

llvm-svn: 248045
2015-09-18 21:21:02 +00:00
Rui Ueyama e8d1c59756 Style fix to make it look consistent. NFC.
llvm-svn: 248044
2015-09-18 21:17:44 +00:00
Chris Bieneman cd53780cd4 [CMake] Refactoring and cleaning up clang symlink generation.
Generation of clang symlinks now uses add_clang_symlink macro which uses add_llvm_symlink. Also the list of symlinks to generate is configurable via CLANG_LINKS_TO_CREATE.

This re-lands r248015, with fixes for clang symlinks to always be generated as part of the clang and install-clang targets.

llvm-svn: 248043
2015-09-18 21:15:54 +00:00
Luke Larson e7dba51330 Fix typo and test commit
llvm-svn: 248042
2015-09-18 21:15:45 +00:00
Gabor Horvath dce40c518d [Static Analyzer] General type checker based on dynamic type information.
Differential Revision: http://reviews.llvm.org/D12973

llvm-svn: 248041
2015-09-18 21:15:37 +00:00
Rafael Espindola 34b9ef680f This code never uses r_addend, so it can just use Elf_Rel.
llvm-svn: 248040
2015-09-18 21:12:38 +00:00
Chris Bieneman 895d96a919 [CMake] Adding ALWAYS_GENERATE option to symlink utility functions.
This implements the behavior required for clang symlinks which should be always generated.

llvm-svn: 248039
2015-09-18 21:08:32 +00:00
Rui Ueyama aa95e5a4cc COFF: Parallelize ICF.
The LLD's ICF algorithm is highly parallelizable. This patch does that
using parallel_for_each.

ICF accounted for about one third of total execution time. Previously,
it took 324 ms when self-hosting. Now it takes only 62 ms.

Of course your mileage may vary. My machine is a beefy 24-core Xeon machine,
so you may not see this much speedup. But this optimization should be
effective even for 2-core machine, since I saw speedup (324 ms -> 189 ms)
when setting parallelism parameter to 2.

llvm-svn: 248038
2015-09-18 21:06:34 +00:00
Adrian Prantl 201e10d007 Debug Info: Use the full module name as a key when caching DIModules.
The signature may not have been computed at the time the module reference
is generated (e.g.: in the future while emitting debug info for a clang
module). Using the full module name is safe because each clang module may
only have a single definition.

NFC.

llvm-svn: 248037
2015-09-18 21:06:14 +00:00
Todd Fiala 33896a9872 Adds parallel work queue index to test events, stdout/stderr results support.
See http://reviews.llvm.org/D12983 for details.

llvm-svn: 248036
2015-09-18 21:01:13 +00:00
Rafael Espindola 12d2a39c88 Handle lld not being found in PATH.
llvm-svn: 248035
2015-09-18 20:55:58 +00:00