Commit Graph

133403 Commits

Author SHA1 Message Date
Chad Rosier db20a41d99 [ms-inline asm] Pass the correct AsmVariant to the PrintAsmOperand() function
and update the printOperand() function accordingly.

llvm-svn: 163544
2012-09-10 21:10:49 +00:00
Greg Clayton 6b152ff550 Added a python example that will compute which functions in a process are hogging the stack.
llvm-svn: 163543
2012-09-10 20:55:08 +00:00
Chad Rosier 6f8d8b2406 [ms-inline asm] Add support for .att_syntax directive.
llvm-svn: 163542
2012-09-10 20:54:39 +00:00
Jim Ingham 41f2b940c9 Fixed a few places where we were doing:
uint32_t size = ThreadList.GetSize();
for (i=0; i < size; ++i)

without grabbing the thread list mutex.

llvm-svn: 163541
2012-09-10 20:50:15 +00:00
Dmitri Gribenko 7acbf00f96 Comment AST: TableGen'ize all command lists in CommentCommandTraits.cpp.
Now we have a list of all commands.  This is a good thing in itself, but it
also enables us to easily implement typo correction for command names.

With this change we have objects that contain information about each command,
so it makes sense to resolve command name just once during lexing (currently we
store command names as strings and do a linear search every time some property
value is needed).  Thus comment token and AST nodes were changed to contain a
command ID -- index into a tables of builtin and registered commands.  Unknown
commands are registered during parsing and thus are also uniformly assigned an
ID.  Using an ID instead of a StringRef is also a nice memory optimization
since ID is a small integer that fits into a common bitfield in Comment class.

This change implies that to get any information about a command (even a command
name) we need a CommandTraits object to resolve the command ID to CommandInfo*.
Currently a fresh temporary CommandTraits object is created whenever it is
needed since it does not have any state.  But with this change it has state --
new commands can be registered, so a CommandTraits object was added to
ASTContext.

Also, in libclang CXComment has to be expanded to include a CXTranslationUnit
so that all functions working on comment AST nodes can get a CommandTraits
object.  This breaks binary compatibility of CXComment APIs.

Now clang_FullComment_getAsXML(CXTranslationUnit TU, CXComment CXC) doesn't
need TU parameter anymore, so it was removed.  This is a source-incompatible
change for this C API.

llvm-svn: 163540
2012-09-10 20:32:42 +00:00
Nadav Rotem 107faf853b Enable stack coloring.
llvm-svn: 163539
2012-09-10 20:15:49 +00:00
Ted Kremenek 8ba803d8d3 Remove clang man page reference to -Oz. It's not an option we want people to use, and is around for historical reasons.
llvm-svn: 163538
2012-09-10 20:10:37 +00:00
DeLesley Hutchins 5ff1644e62 Thread-safety analysis: differentiate between two forms of analysis; a precise
analysis that may give false positives because it is confused by aliasing, and
a less precise analysis that has fewer false positives, but may have false
negatives.  The more precise warnings are enabled by -Wthread-safety-precise.
An additional note clarify the warnings in the precise case.

llvm-svn: 163537
2012-09-10 19:58:23 +00:00
Ted Kremenek 83e480f50f Now that I have a test file to work with, disable the Filecheck part of this test.
llvm-svn: 163536
2012-09-10 19:50:17 +00:00
Jakob Stoklund Olesen 8b9dce5c18 Don't attempt to use flags from predicated instructions.
The ARM backend can eliminate cmp instructions by reusing flags from a
nearby sub instruction with similar arguments.

Don't do that if the sub is predicated - the flags are not written
unconditionally.

<rdar://problem/12263428>

llvm-svn: 163535
2012-09-10 19:17:25 +00:00
Ted Kremenek a8755da8b3 Correctly 'cat' out test files.
llvm-svn: 163534
2012-09-10 19:13:08 +00:00
Ted Kremenek a0fa5d6564 Fix another case where we should be using isBeforeInTranslationUnit().
llvm-svn: 163533
2012-09-10 19:07:56 +00:00
Michael J. Spencer 7307fea911 [Object] Extract Elf_Ehdr. Patch by Hemant Kulkarni!
llvm-svn: 163532
2012-09-10 19:04:02 +00:00
Ted Kremenek 54fd079265 Add a few more cases where we should be using isBeforeInTranslationUnit().
llvm-svn: 163531
2012-09-10 19:02:33 +00:00
Nadav Rotem 3c86b78ae4 Stack Coloring: Handle the case where END markers come before BEGIN markers properly.
llvm-svn: 163530
2012-09-10 18:51:09 +00:00
Ted Kremenek fc57cdf5b8 As a debugging aid to unbreak the buildbots, cat the plist files so I can view them on different builders.
llvm-svn: 163529
2012-09-10 18:38:43 +00:00
Michael Liao 400f7ef871 Enhance PR11334 fix to support extload from v2f32/v4f32
- Fix an remaining issue of PR11674 as well

llvm-svn: 163528
2012-09-10 18:33:51 +00:00
Daniel Dunbar 256ea4e4f3 build/clang_darwin: Add the ASAN dynamic library.
- Now with spelling fix for -lstdc++.

llvm-svn: 163527
2012-09-10 18:26:38 +00:00
Fariborz Jahanian d6876b20e7 More tweaking and test cases for call to super
annotations. // rdar://6386358

llvm-svn: 163525
2012-09-10 18:04:25 +00:00
Ted Kremenek e46c74f3ec Re-enable FileCheck testing of retain-release.m test, and force
a C++ dialect.  Let's see if this is the portability issue with this test.

llvm-svn: 163524
2012-09-10 17:35:24 +00:00
Sergei Larin ef4cc11cf9 Add "blocked" heuristic to the Hexagon MI scheduler.
Improve AQ instruction selection in the Hexagon MI scheduler.

llvm-svn: 163523
2012-09-10 17:31:34 +00:00
Chad Rosier ca8b950317 Revert r163415 in an attempt to bring back the buildbots.
llvm-svn: 163522
2012-09-10 17:26:42 +00:00
Greg Clayton bded106120 Playing around with "objc_refs" over the weekend and improved it to work on a large ObjC program without running into expression timeouts. Now we get a full list of ObjC classes using a runtime function and then qsort the result. Also added code that can count all instances of each ObjC on the heap and also the total byte sizes for the object allocations.
llvm-svn: 163520
2012-09-10 17:22:45 +00:00
Michael Ilseman 0666f0580c Fold multiply by 0 or 1 when in UnsafeFPMath mode in SelectionDAG::getNode().
This folding happens as early as possible for performance reasons, and to make sure it isn't foiled by other transforms (e.g. forming FMAs).

llvm-svn: 163519
2012-09-10 17:00:37 +00:00
Michael Ilseman d5f91515f3 whitespace
llvm-svn: 163518
2012-09-10 16:56:31 +00:00
Fariborz Jahanian b05417e1e1 objective-C: Improving diagnostocs for missing call to
super's annotated methods. // rdar://6386358

llvm-svn: 163517
2012-09-10 16:51:09 +00:00
Michael Liao c3d5b21c39 Add boolean simplification support from CMOV
- If a boolean value is generated from CMOV and tested as boolean value,
  simplify the use of test result by referencing the original condition.
  RDRAND intrinisc is one of such cases.

llvm-svn: 163516
2012-09-10 16:36:16 +00:00
Ted Kremenek 1f9e7f4f91 Temporarily disable FileCheck part of this test.
llvm-svn: 163515
2012-09-10 15:16:32 +00:00
Douglas Gregor c5c5734d19 Allow vector types in pseudo-destructor expressions. Fixes PR13798.
llvm-svn: 163514
2012-09-10 14:57:06 +00:00
Alexander Kornienko 02f481c42f Workaround for MacOSX build failure with gcc <= 4.4
Summary:
A better solution to http://llvm.org/bugs/show_bug.cgi?id=13777
Named namespace + more unique name to make ODR violations unlikely.

Reviewers: chandlerc, doug.gregor, klimek

Reviewed By: doug.gregor

CC: cfe-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D38

llvm-svn: 163513
2012-09-10 14:54:38 +00:00
Ted Kremenek 6c7a5eae6d Revert "Revert Ted's r163489 and r163490, due to breakage."
I need to see how this breaks on other platforms when I fix the issue
that Benjamin Kramer pointed out.

This includes r163489 and r163490, plus a two line change.

llvm-svn: 163512
2012-09-10 14:50:55 +00:00
James Molloy 1e5c611815 Fix an assertion failure when optimising a shufflevector incorrectly into concat_vectors, and a followup bug with SelectionDAG::getNode() creating nodes with invalid types.
llvm-svn: 163511
2012-09-10 14:01:21 +00:00
Nadav Rotem ba9a03f279 Minor cleanup. No functional change.
llvm-svn: 163510
2012-09-10 13:20:00 +00:00
Nadav Rotem d62287dc91 Stack Coloring: Debug prints to print the slot number and not the array index.
llvm-svn: 163509
2012-09-10 13:17:58 +00:00
Nadav Rotem ed242a0f1c Stack Coloring: When searching for disjoint regions, do not compare intervals twice or to theirself.
llvm-svn: 163508
2012-09-10 12:47:38 +00:00
Nadav Rotem 6731363185 Stack Coloring: Add support for multiple regions of the same slot, within a single basic block.
llvm-svn: 163507
2012-09-10 12:39:35 +00:00
Elena Demikhovsky 264fb0217e The VPSHUFB 256-bit instruction may be generated when one of input vector is undefined or zeroinitializer.
I've added the "zeroinitializer" case in this patch.

llvm-svn: 163506
2012-09-10 12:13:11 +00:00
Benjamin Kramer 199f8da3ae Make helper functions static.
llvm-svn: 163505
2012-09-10 11:57:16 +00:00
Benjamin Kramer 47b5c5713b Make helper function static.
llvm-svn: 163504
2012-09-10 11:52:14 +00:00
Benjamin Kramer 1f66f885e8 Move bypassSlowDivision into the llvm namespace.
llvm-svn: 163503
2012-09-10 11:52:08 +00:00
Benjamin Kramer 8dd0edc7b1 c bindings: revert LLVMConstInlineAsm to always use the default asm dialect.
- The C API should be stable
- InlineAsm::AsmDialect is not exposed to C
- The function didn't match the prototype so this was unreachable code

llvm-svn: 163502
2012-09-10 11:52:00 +00:00
Evgeniy Stepanov c9cdb96188 GTest on Android needs a custom tmpdir path.
llvm-svn: 163501
2012-09-10 10:32:29 +00:00
Evgeniy Stepanov c9cde48f3a Wrong crtbegin/crtend pair used for PIE on Android.
Android uses the same flavour of crt*.o for PIE and non-PIE executables, and a
different one for DSOs. GNU/Linux, on the other hand, uses one set of crt*.o
for non-PIE executables, and another for both PIE executables and DSOs.

llvm-svn: 163500
2012-09-10 10:30:12 +00:00
Evgeniy Stepanov 6f66ed1329 [asan] There is no __libc_malloc on Android.
llvm-svn: 163498
2012-09-10 10:18:49 +00:00
NAKAMURA Takumi 6eb1399088 Revert Ted's r163489 and r163490, due to breakage.
r163489, "Take another crack at stabilizing the emission order of analyzer"
r163490, "Use isBeforeInTranslationUnitThan() instead of operator<."

llvm-svn: 163497
2012-09-10 09:17:27 +00:00
Nadav Rotem 2f41ff93e6 Fix a typo in the comment.
llvm-svn: 163496
2012-09-10 08:51:46 +00:00
Nadav Rotem 28e6f8c1fc Add an assertion that the frame index is indeed inside the declared lifetime region.
llvm-svn: 163495
2012-09-10 08:44:15 +00:00
Nadav Rotem d753a952ca Teach the DAGBuilder about lifetime markers which are generated from PHINodes.
llvm-svn: 163494
2012-09-10 08:43:23 +00:00
Alexander Potapenko 67192d41ee Allow to call strchr() from __asan_init().
Fixes PR13794.

llvm-svn: 163493
2012-09-10 08:35:12 +00:00
Simon Atanasyan 464a7f7e89 MIPS: Use -march=arch option to select either generic MIPS ISA,
or the name of a particular processor.

The patch reviewed by Douglas Gregor.

llvm-svn: 163492
2012-09-10 08:32:41 +00:00