Commit Graph

146796 Commits

Author SHA1 Message Date
Alexey Samsonov a0e28a7aaa [Sanitizer] Kill the remainders of platform defines in favor of SANITIZER_ defines
llvm-svn: 178627
2013-04-03 07:24:35 +00:00
Daniel Jasper 5188e6b295 Cleanup, add comments and address review comments.
No functional changes.

llvm-svn: 178626
2013-04-03 07:21:51 +00:00
Alexey Samsonov 8d18cc3096 [Sanitizer] Fix StopTheWorld includes on Android. Patch by Sergey Matveev.
llvm-svn: 178625
2013-04-03 07:06:10 +00:00
Eric Christopher 14c2067ca1 Fix grammar.
llvm-svn: 178624
2013-04-03 05:29:58 +00:00
Eric Christopher 5590949f29 Remove ZeroOrMore from the option description. We don't need it here.
llvm-svn: 178623
2013-04-03 05:26:07 +00:00
Argyrios Kyrtzidis 3e612b419a [modules] If a submodule has re-definitions of the same macro, only the last definition will be used as the "exported" one.
Fixes rdar://13562262

llvm-svn: 178622
2013-04-03 05:11:33 +00:00
Jakob Stoklund Olesen d9bbdfd3cc Add 64-bit compare + branch for SPARC v9.
The same compare instruction is used for 32-bit and 64-bit compares. It
sets two different sets of flags: icc and xcc.

This patch adds a conditional branch instruction using the xcc flags for
64-bit compares.

llvm-svn: 178621
2013-04-03 04:41:44 +00:00
Jason Molenda 69535e0072 Remove a bit of code duplication in RNBRemote::HandlePacket_qProcessInfo -
call DNBProcessGetCPUType() to get the cputype of the process we're debugging.

llvm-svn: 178620
2013-04-03 04:31:59 +00:00
Jason Molenda d5318c0c35 Fix another old usage of GetCurrentThread() to get a mach port
number in RNBRemote::HandlePacket_qProcessInfo -- add a new
GetCurrentThreadMachPort() so callers who need to make a mach
thred_get_state() call at the RNBRemote level will have a way to
get the port number.

llvm-svn: 178619
2013-04-03 04:18:47 +00:00
Hal Finkel b00fc87608 Remove some unsupported-feature comments from PPC.td
These refer to the reciprocal estimate support recently committed.

llvm-svn: 178618
2013-04-03 04:03:58 +00:00
Hal Finkel 2e10331057 Use PPC reciprocal estimates with Newton iteration in fast-math mode
When unsafe FP math operations are enabled, we can use the fre[s] and
frsqrte[s] instructions, which generate reciprocal (sqrt) estimates, together
with some Newton iteration, in order to quickly generate floating-point
division and sqrt results. All of these instructions are separately optional,
and so each has its own feature flag (except for the Altivec instructions,
which are covered under the existing Altivec flag). Doing this is not only
faster than using the IEEE-compliant fdiv/fsqrt instructions, but allows these
computations to be pipelined with other computations in order to hide their
overall latency.

I've also added a couple of missing fnmsub patterns which turned out to be
missing (but are necessary for good code generation of the Newton iterations).
Altivec needs a similar fix, but that will probably be more complicated because
fneg is expanded for Altivec's v4f32.

llvm-svn: 178617
2013-04-03 04:01:11 +00:00
Douglas Gregor 05ba2a055d Use getPredefinesFileID() appropriately.
Thanks to Argyrios for the pointer.

llvm-svn: 178616
2013-04-03 03:16:36 +00:00
Rafael Espindola b9b7ae0c78 Fix the fde encoding used by mips to match gas.
This finally fixes the encoding. The patch also
* Removes eh-frame.ll. It was an unnecessary .ll to .o test that was checking
  the wrong value.
* Merge fde-reloc.s and eh-frame.s into a single test, since the only difference
  was the run lines.
* Don't blindly test the content of the entire .eh_frame section. It makes it
  hard to anyone actually fixing a bug and hitting a difference in a binary
  blob. Instead, use a CHECK for each field and document what is being checked.

llvm-svn: 178615
2013-04-03 03:13:19 +00:00
Aaron Ballman 9c0f0af54f Rolling back the AVX support patch due to breaking a gcc 4.6 build bot that doesn't understand the xgetbv instruction for some reason. Will revisit when time permits.
llvm-svn: 178614
2013-04-03 03:11:39 +00:00
Richard Trieu 17f13ecc5b Refactor the Get* functions to be more consistant among themselves.
llvm-svn: 178613
2013-04-03 03:06:48 +00:00
Michael Gottesman b8c8836594 Remove an optimization where we were changing an objc_autorelease into an objc_autoreleaseReturnValue.
The semantics of ARC implies that a pointer passed into an objc_autorelease
must live until some point (potentially down the stack) where an
autorelease pool is popped. On the other hand, an
objc_autoreleaseReturnValue just signifies that the object must live
until the end of the given function at least.

Thus objc_autorelease is stronger than objc_autoreleaseReturnValue in
terms of the semantics of ARC* implying that performing the given
strength reduction without any knowledge of how this relates to
the autorelease pool pop that is further up the stack violates the
semantics of ARC.

*Even though objc_autoreleaseReturnValue if you know that no RV
optimization will occur is more computationally expensive.

llvm-svn: 178612
2013-04-03 02:57:24 +00:00
Richard Trieu bcd06c0220 Do not assume the template argument is an integer only because the
expressions are integer.  It can also be ValueDecl expressions

Use the type information from the TemplateParameterList instead

Patch by Olivier Goffart!

llvm-svn: 178611
2013-04-03 02:31:17 +00:00
Richard Trieu ad13f55356 Fix a crasher in Template Diffing.
When support was added for declaration arguments, the case of variadic
declaration arguments was not supported.  This patch fixes that problem by
not crashing when certain ValueDecl's are null.

Patch by Olivier Goffart!

llvm-svn: 178610
2013-04-03 02:22:12 +00:00
Richard Trieu 981de5cef3 Fix a crasher in Template Diffing.
Value depenedent expressions for default arguments cannot be evaluated.
Instead, use the desugared template type to get an argument expression that
can be used.  This is needed for both integer and declaration arguements.

Also, move this common code into a separate function.

Patch by Olivier Goffart!

llvm-svn: 178609
2013-04-03 02:11:36 +00:00
Greg Clayton 43fe217b11 <rdar://problem/13506727>
Symbol table function names should support lookups like symbols with debug info. 

To fix this I:
- Gutted the way FindFunctions is used, there used to be way too much smarts only in the DWARF plug-in
- Made it more efficient by chopping the name up once and using simpler queries so that SymbolFile and Symtab plug-ins don't need to do as much
- Filter the results at a higher level
- Make the lldb_private::Symtab able to chop up C++ mangled names and make as much sense out of them as possible and also be able to search by basename, fullname, method name, and selector name.

llvm-svn: 178608
2013-04-03 02:00:15 +00:00
Eric Christopher 1786cb2f01 Move this file into the correct directory.
llvm-svn: 178607
2013-04-03 01:58:56 +00:00
Eric Christopher b7d97e95e8 From PR9121 gcc defaulted to omitting the frame pointer on linux,
however, it doesn't do that unless we're optimizing. Change
that and haul out to a helper function. Also make this a driver
test appropriate rather than an assembly test.

llvm-svn: 178606
2013-04-03 01:58:53 +00:00
Michael Gottesman 624243914f Improved comment. No functionality change.
llvm-svn: 178605
2013-04-03 01:57:16 +00:00
Aaron Ballman 56be6ba5e4 Attempting to fix the build on older GCC versions.
llvm-svn: 178604
2013-04-03 01:39:37 +00:00
Jordan Rose a0e9d39b55 Escape more @ signs in Doxygen comments.
Doxygen treats "@command" the same as "\command" in a doc comment, so
whenever we talk about Objective-C things like "@interface" we have to
make sure to escape them.

Let's try to keep Clang -Wdocumentation-clean!

llvm-svn: 178603
2013-04-03 01:39:23 +00:00
Jordan Rose bc74eb1c90 [analyzer] Better model for copying of array fields in implicit copy ctors.
- Find the correct region to represent the first array element when
  constructing a CXXConstructorCall.
- If the array is trivial, model the copy with a primitive load/store.
- Don't warn about the "uninitialized" subscript in the AST -- we don't use
  the helper variable that Sema provides.

<rdar://problem/13091608>

llvm-svn: 178602
2013-04-03 01:39:08 +00:00
Enrico Granata eb8bd925c6 <rdar://problem/13563403>
Reimplemented the NSDictionary synthetic children provider for added performance.
Instead of generating pairs by running an expression, we now create a pair type using clang-level APIs and fill in a buffer with the pointers to key and value
This strategy takes the time required to dump a 10k items __NSDictionaryM from ~45s to <4s

llvm-svn: 178601
2013-04-03 01:25:29 +00:00
Rafael Espindola aff6081415 Remove anonymous namespace.
Looks like the gcc in http://lab.llvm.org:8011/builders/clang-x86_64-darwin11-self-mingw32/ doesn't like "not external linkage":

/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.src/include/llvm/Support/YAMLTraits.h: In instantiation of 'const bool llvm::yaml::has_SequenceMethodTraits<std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> > >::value':
/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.src/include/llvm/Support/YAMLTraits.h:281:   instantiated from 'llvm::yaml::has_SequenceTraits<std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> > >'
/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.src/utils/yaml2obj/yaml2obj.cpp:627:   instantiated from here
/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.src/include/llvm/Support/YAMLTraits.h:243: error: 'llvm::yaml::SequenceTraits<std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> > >::size' is not a valid template argument for type 'size_t (*)(llvm::yaml::IO&, std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> >&)' because function 'static size_t llvm::yaml::SequenceTraits<std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> > >::size(llvm::yaml::IO&, std::vector<<unnamed>::COFFYAML::Relocation, std::allocator<<unnamed>::COFFYAML::Relocation> >&)' has not external linkage

llvm-svn: 178600
2013-04-03 01:07:53 +00:00
John McCall 638d4f5d11 In ObjC++ on legacy runtimes, push an EH cleanup as well as
a normal cleanup when entering a @try or @synchronized to
ensure that we clean that up if an exception is triggered.

Apparently GCC did this, so it's hard to argue that we shouldn't
do at least as much.

rdar://12364847

llvm-svn: 178599
2013-04-03 00:56:07 +00:00
Aaron Ballman 6bc0dfc7bd This patch addresses PR15351 by explicitly checking for AVX support
when getting the host processor information.

llvm-svn: 178598
2013-04-03 00:33:32 +00:00
Jim Ingham 298f378f6a Allow partial matching for alias commands as well as regular commands.
<rdar://problem/13552724>

llvm-svn: 178597
2013-04-03 00:25:49 +00:00
Sean Callanan e29f61d85e Improved reporting of faults on i386.
<rdar://problem/13558979>

llvm-svn: 178596
2013-04-03 00:08:22 +00:00
Greg Clayton 1a400cf485 Fixed the version test for darwin.
llvm-svn: 178595
2013-04-03 00:04:27 +00:00
Rafael Espindola e1d9afa82d Use yaml::IO in yaml2obj.cpp.
The generic structs and specializations will be refactored when obj2yaml is
changed to use yaml::IO.

llvm-svn: 178593
2013-04-02 23:56:40 +00:00
Fariborz Jahanian 896ae920d5 Objective-C arc [qui]. Don't issue the bridge cast
warning when doing a __bride cast in non-arc
mode (which has no retain count effect).
// rdar://13514210

llvm-svn: 178592
2013-04-02 23:48:59 +00:00
Aaron Ballman 235af9c1f5 Silencing warnings in MSVC due to duplicate identifiers.
llvm-svn: 178591
2013-04-02 23:47:53 +00:00
Enrico Granata 23ab35aed2 Fixing a silly bug that would cause string summaries not to show up :-)
llvm-svn: 178590
2013-04-02 23:07:55 +00:00
Eric Christopher e2fbc67e81 Formatting.
llvm-svn: 178589
2013-04-02 23:06:40 +00:00
Akira Hatanaka 023c678a0d [mips] Small update to the implementation of eh.return for Mips.
This patch initializes t9 to the handler address, but only if the relocation
model is pic. This handles the case where handler to which eh.return jumps 
points to the start of the function.

Patch by Sasa Stankovic.

llvm-svn: 178588
2013-04-02 23:02:07 +00:00
Eric Christopher 5c7ee8b996 Revert "Revert r178079, it caused PR15637."
This reverts commit r178497 since the backend has been fixed.

Also add a test to ensure that we're emitting template information for unions.

llvm-svn: 178587
2013-04-02 22:59:11 +00:00
Eric Christopher 6476f908b3 Support and test template arguments for unions.
llvm-svn: 178586
2013-04-02 22:55:56 +00:00
Eric Christopher 17dd8f07c6 Reformat arguments.
llvm-svn: 178585
2013-04-02 22:55:52 +00:00
Akira Hatanaka 2ffc5734e7 [mips] Expand pseudo multiply/divide instructions in MipsCodeEmitter.cpp.
This patch fixes the following two tests which have been failing on
llvm-mips-linux builder since r178403:

LLVM :: Analysis/Profiling/load-branch-weights-ifs.ll
LLVM :: Analysis/Profiling/load-branch-weights-loops.ll

llvm-svn: 178584
2013-04-02 22:53:58 +00:00
NAKAMURA Takumi fc613f4d61 llvm/test/CodeGen/X86: Unmark them out of XFAIL:cygming, in atomic{32|64}.ll and handle-move.ll, corresponding to r178549.
This reverts r176808, r176798, and r177914.

llvm-svn: 178583
2013-04-02 22:35:08 +00:00
Jakob Stoklund Olesen aeb69a5481 Allow MachineTraceMetrics to be used when the model has no resources.
It it still possible to extract information from itineraries, for
example.

llvm-svn: 178582
2013-04-02 22:27:45 +00:00
Howard Hinnant 459448241a Reference: http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20130325/077133.html
llvm-svn: 178581
2013-04-02 22:14:51 +00:00
Enrico Granata 1ed58f7baf Enabling metrics to calculate (and dump) their standard deviation
llvm-svn: 178580
2013-04-02 21:59:39 +00:00
Howard Hinnant 516487765a The cmake script is failing to copy cxxabi.h to the right place because it was generating to destination path like so /include// and dstdir can legally be blank from my interpretation of the script, and this would then generate a path like libcxx/include// which is illegal.
llvm-svn: 178579
2013-04-02 21:33:01 +00:00
Enrico Granata 4e969282fd Misc fixes:
- make an overload of Launch() that takes an init list of const char* if all you need to tweak in the launch info are the command-line arguments
- make Run() return an int that you can use as an exit-code
- make dynamic values work properly when recursing in FetchVariables()
- make the po output more obvious in verbose mode

llvm-svn: 178578
2013-04-02 21:31:18 +00:00
Enrico Granata d83bfce6d4 <rdar://problem/13415737>
Fixing a bug where LLDB was not handling correctly CFStrings that have an explicit length but no NULL terminator
The data formatter was showing garbled data as part of the summary
The fix is to explicitly figure out the explicit length if we need to (bitfields tell us when that is the case) and use that as a size delimiter

llvm-svn: 178577
2013-04-02 21:25:34 +00:00