Commit Graph

186515 Commits

Author SHA1 Message Date
Bob Wilson da37021cf3 Do not build a separate x86_64h Haswell slice for the iOS simulator.
r199996 added new x86_64h slices for all the Darwin compiler_rt libraries
that had an x86_64 slice, but that is overkill for the iOS Simulator
platform where the x86_64h slice is never used.

llvm-svn: 221610
2014-11-10 17:05:21 +00:00
Daniel Jasper 0bd9a19b28 clang-format: Fix pointer formatting.
Before:
  void f(Bar* a = nullptr, Bar * b);
After:
  void f(Bar* a = nullptr, Bar* b);

llvm-svn: 221609
2014-11-10 16:57:30 +00:00
Rafael Espindola 101b364b46 Fix variable names and comment style. NFC.
llvm-svn: 221608
2014-11-10 16:31:06 +00:00
Nico Weber a644d7f39c clang-format: [Java] Never treat @interface as annotation.
'@' followed by any keyword can't be an annotation, but @interface is currently
the only combination of '@' and a keyword that's allowed, so limit it to this
case. `@interface Foo` without a leading `public` was misformatted prior to
this patch.

llvm-svn: 221607
2014-11-10 16:30:02 +00:00
Nico Weber 337f5b27ad clang-format: Document that --assume-filename affects the language.
llvm-svn: 221606
2014-11-10 16:14:54 +00:00
Benjamin Kramer 283afa3f12 Remove unused diagnostic.
llvm-svn: 221605
2014-11-10 16:07:58 +00:00
Daniel Sanders 87f9b88bfb [mips] Fix sret arguments for N32/N64 which were accidentally broken in r221534.
llvm-svn: 221604
2014-11-10 15:57:53 +00:00
Simon Atanasyan 7b2e2b7d01 [Mips] Replace the redundant condition by assert call
No functional changes.

llvm-svn: 221603
2014-11-10 15:50:22 +00:00
Simon Atanasyan 1255354141 [Mips] Do not read addends for relocations which do not use them
No functional changes.

llvm-svn: 221602
2014-11-10 15:50:01 +00:00
Marshall Clow 68640684e8 Update status pages for C++1z
llvm-svn: 221601
2014-11-10 15:43:20 +00:00
Alexander Kornienko c48a535a7c [Tooling] Restore current directory after processing each file.
Summary:
If we actually change directory before processing a file, we need to
restore it afterwards. This was broken in r216620.

Added a comment for the changes in r216620.

Reviewers: klimek

Reviewed By: klimek

Subscribers: klimek, cfe-commits

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

llvm-svn: 221600
2014-11-10 15:42:31 +00:00
Viktor Kutuzov d98b348cb9 Enable running Ubsan tests on FreeBSD
Differential Revision: http://reviews.llvm.org/D6089

llvm-svn: 221599
2014-11-10 15:31:56 +00:00
Manuel Klimek fb9e32b4b2 Mark test using python as REQUIRES: python27.
llvm-svn: 221598
2014-11-10 15:29:29 +00:00
Viktor Kutuzov eb5e79550a [Ubsan] Fix the missing_return.cpp test to pass on FreeBSD
Differential Revision: http://reviews.llvm.org/D6088

llvm-svn: 221597
2014-11-10 15:27:13 +00:00
Viktor Kutuzov f686063f57 [Ubsan] Fix the cast-overflow.cpp test to build on FreeBSD
Differential Revision: http://reviews.llvm.org/D6087

llvm-svn: 221596
2014-11-10 15:25:01 +00:00
Viktor Kutuzov dc6cbfe859 [Sanitizers] Enable stack traces on FreeBSD
Differential Revision: http://reviews.llvm.org/D6086

llvm-svn: 221595
2014-11-10 15:22:04 +00:00
Shankar Easwaran 156ffbc4c0 [ELF] add missing test for max-page-size
llvm-svn: 221594
2014-11-10 15:16:31 +00:00
Shawn Best e1a76dba0d LLGS Android target support (r221570) missed adding some files: http://reviews.llvm.org/D6166
llvm-svn: 221593
2014-11-10 15:06:15 +00:00
NAKAMURA Takumi f96d423fd8 [CMake] llvm-c-test: Use libLLVM.so if it is available.
llvm-svn: 221592
2014-11-10 15:04:26 +00:00
NAKAMURA Takumi c8abc4c201 [CMake] Let llvm-shlib work on Linux with --whole-archive.
FIXME: It should work on not only Linux but elf-targeting gnu ld.

For example if LLVM_DYLIB_COMPONENTS is "BitWriter Support", CMake emits the command line like;

  -Wl,--whole-archive
    lib/libLLVMBitWriter.a
    lib/libLLVMSupport.a *1
  -Wl,--no-whole-archive
  lib/libLLVMCore.a
  lib/libLLVMSupport.a   *2
  -lrt -ldl -ltinfo -lpthread -lm

It works since symbols in LLVMCore is resolved with not *2 but *1.

Unfortunately, --gc-sections is not powerful in this case to prune unused "visibility(default)" entries.

I am still experimenting other way not to rely on --whole-archive.

llvm-svn: 221591
2014-11-10 15:04:02 +00:00
NAKAMURA Takumi e1e5274a88 [CMake] Move llvm-shlib in prior to other tools.
llvm-svn: 221590
2014-11-10 15:03:02 +00:00
Shankar Easwaran 7757f1ace6 [Gnu] Support --image-base option
The value for --image-base is used as the base address of the program.

llvm-svn: 221589
2014-11-10 14:55:21 +00:00
Shankar Easwaran 7a82510348 [ELF] Fix DT_INIT_ARRAY{SZ} and DT_FINI_ARRAY{SZ}
The dynamic table was creating the entry DT_FINI_ARRAY{SZ} even when there was
no .fini_array section. The entries should be creating in the dynamic section
only if there are sections .init_array/.fini_array in the output.

Fixes the tests that checked for errroneous outputs.

llvm-svn: 221588
2014-11-10 14:55:11 +00:00
Shankar Easwaran 0abfc278f0 [ELF] Fix values of linker created dynamic variables.
The value of _DYNAMIC should be pointing at the start of the .dynamic segment.
This was pointing to the end of the dynamic segment. Similarly the value of
_GLOBAL_OFFSET_TABLE_ was not proper too.

llvm-svn: 221587
2014-11-10 14:55:07 +00:00
Shankar Easwaran 38d187021f [ELF] .dynamic should have SHT_DYNAMIC flag
llvm-svn: 221586
2014-11-10 14:54:53 +00:00
Shankar Easwaran 78aa81d6ed [Gnu] Add options that are ignored
Add options that are ignored and exists just for compatibility reasons.

llvm-svn: 221585
2014-11-10 14:54:49 +00:00
Shankar Easwaran ba154afa06 [ELF] Support -z max-page-size option
The GNU linker allows the user to change the page size by using the option -z
max-page-size.

llvm-svn: 221584
2014-11-10 14:54:43 +00:00
Shankar Easwaran c937b4923e Add support library.
The parsing routines in the linker script to parse strings encoded in various
formats(hexadecimal, octal, decimal, etc), is needed by the GNU driver too. This
library provides helper functions for all flavors and flavors to add helper
functions which other flavors may make use of.

llvm-svn: 221583
2014-11-10 14:54:34 +00:00
Aaron Ballman 0de6a9b5bf Missing testcase from r221581.
llvm-svn: 221582
2014-11-08 17:09:50 +00:00
Aaron Ballman c0ae7dfe75 Updated the wording for a diagnostic to be more grammatically correct, and use a %select. Also ensure that nested namespace definitions are diagnosed properly. Both changes are motivated by post-commit feedback from r221580.
llvm-svn: 221581
2014-11-08 17:07:15 +00:00
Aaron Ballman 730476b50e [c++1z] Support for attributes on namespaces and enumerators.
llvm-svn: 221580
2014-11-08 15:33:35 +00:00
NAKAMURA Takumi 4239789235 [CMake] llvm-shlib: Add possibly missing BitReader and MCDisassembler for llvm-c.
FYI, 3 modules below are redundant in trunk;

  AsmPrinter
  MC
  SelectionDAG

llvm-svn: 221579
2014-11-08 14:12:30 +00:00
Jay Foad 2f945ba85f [ASan] Fix stack-overflow test for PowerPC
Summary:
Tweak the asan stack overflow heuristics to cope with PowerPC64 redzones,
which are larger than on x86-64: 288 bytes for big-endian and 512 bytes
for little-endian.

Reviewers: kcc, willschm, samsonov, eugenis

Reviewed By: samsonov, eugenis

Subscribers: llvm-commits

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

llvm-svn: 221578
2014-11-08 09:51:45 +00:00
Jason Molenda bd07fd57f6 Add a RegisterNumber class to RegisterContextLLDB.h and start using
it in RegisterContext.cpp.

There's a lot of bookkeeping code in RegisterContextLLDB where it has
to convert between different register numbering schemes and it makes 
some methods like SavedLocationForRegister very hard to read or
maintain.  Abstract all of the details about different register numbering
systems for a given register into this new class to make it easier 
to understand what the method is doing.

Also add register name printing to all of the logging -- that's easy to
get now that I've got an object to represent the register numbers.

There were some gnarly corner cases of this method that I believe
I've translated correctly - initial testing looks good but it's
possible I missed a corner case, especially with architectures which
uses a link-register aka return address register like arm32/arm64.
Basic behavior is correct but there are a lot of corner casese that are
handled in this method ...

llvm-svn: 221577
2014-11-08 08:09:22 +00:00
Richard Smith 3e3a705062 [c++1z] Support for u8 character literals.
llvm-svn: 221576
2014-11-08 06:08:42 +00:00
Jason Molenda cf29675d95 Fix a corner case with the handling of noreturn functions.
If a noreturn function was the last function in a section,
we wouldn't correctly back up the saved-pc value into the
correct section leading to us showing the wrong function in
the backtrace.

Also add a backtrace test with an attempt to elicit this 
particular layout.  It happens to work out with clang -Os
but other compilers may not quite get the same layout I'm
getting at that opt setting.  We'll still be exercising the
basic noreturn handling in the unwinder even if we don't get
one function at the very end of a section.

<rdar://problem/16051613> 

llvm-svn: 221575
2014-11-08 05:38:17 +00:00
Richard Smith 13307f5f24 [c++1z] Implement nested-namespace-definitions.
This allows 'namespace A::B { ... }' as a shorthand for 'namespace A {
namespace B { ... } }'. We already supported this correctly for error recovery;
promote that support to a full implementation.

This is not the right implementation: we do not maintain source fidelity
because we desugar the nested namespace definition in the parser. This is
tricky to avoid, since the definition genuinely does inject one named
entity per level in the namespace name.

llvm-svn: 221574
2014-11-08 05:37:34 +00:00
Richard Smith 0f0af19b05 [c++1z] N4295: fold-expressions.
This is a new form of expression of the form:

  (expr op ... op expr)

where one of the exprs is a parameter pack. It expands into

  (expr1 op (expr2onwards op ... op expr))

(and likewise if the pack is on the right). The non-pack operand can be
omitted; in that case, an empty pack gives a fallback value or an error,
depending on the operator.

llvm-svn: 221573
2014-11-08 05:07:16 +00:00
Shankar Easwaran 8f6dd44056 [ELF] Remove unused variable
llvm-svn: 221572
2014-11-08 04:03:24 +00:00
Shankar Easwaran 22c76a5d79 [ELF] Support --no-align-segments.
lld generates an ELF by adhering to the ELF spec by aligning vma/fileoffset to a
page boundary, but this becomes an issue when dealing with large pages. This
adds support so that lld generated executables adheres to the ELF spec with the
rule vma % p_align = offset % p_align.

This is supported by the flag --no-align-segments.

This could be the default in few targets like X86_64 to save space on disk.

llvm-svn: 221571
2014-11-08 03:44:49 +00:00
Shawn Best 8da0bf3b7c LLGS Android target support - for Andy Chien : http://reviews.llvm.org/D6166
llvm-svn: 221570
2014-11-08 01:41:49 +00:00
Ben Langmuir ed98258482 Check module signature when the module has already been loaded
We may need to verify the signature on subsequent imports as well, just
like we verify the size/modtime:
@import A;
@import B; // imports A
@import C; // imports A

llvm-svn: 221569
2014-11-08 00:34:30 +00:00
Fariborz Jahanian e531d27cd1 Fixed a buildbot failure.
llvm-svn: 221568
2014-11-08 00:23:55 +00:00
Ben Langmuir 264ea15e19 Fix unintended fallthrough in ASTReader
llvm-svn: 221567
2014-11-08 00:06:39 +00:00
Shawn Best 181b09b7c3 fix for unit tests finding path to LLDB.h http://reviews.llvm.org/D6177
llvm-svn: 221566
2014-11-08 00:04:04 +00:00
Matt Arsenault afbf21f15c R600/SI: Fix broken check prefixes in test
llvm-svn: 221565
2014-11-08 00:02:57 +00:00
Saleem Abdulrasool d2c5d7f6da Transforms: address some late comments
We already use the llvm namespace.  Remove the unnecessary prefix.  Use the
StringRef::equals method to compare with C strings rather than instantiating
std::strings.

Addresses late review comments from David Majnemer.

llvm-svn: 221564
2014-11-08 00:00:50 +00:00
Saleem Abdulrasool 92b13aac04 Transforms: sort source files in build
Sort target sources.  NFC.

llvm-svn: 221563
2014-11-08 00:00:47 +00:00
Fariborz Jahanian 05e77f8349 [Objective-C Sema]. Issue availability/deprecated warning when
there is a uinque method found when message is sent to receiver 
of 'id' type. // rdar://18848183

llvm-svn: 221562
2014-11-07 23:51:15 +00:00
Zachary Turner 02862bc83a Remove the top-level DebugDriverThread in ProcessWindows.
Originally the idea was that we would queue requests to a master
thread that would dispatch them to other slave threads each
responsible for debugging an individual process.  This might make
some scenarios more scalable and responsive, but for now it seems
to be unwarranted complexity for no observable benefit.

llvm-svn: 221561
2014-11-07 23:44:13 +00:00