Commit Graph

104974 Commits

Author SHA1 Message Date
Eric Christopher 9ade5e2495 Update comments and checks to match reality.
llvm-svn: 130464
2011-04-29 00:07:20 +00:00
Eric Christopher 501d2e2c14 Whitespace.
llvm-svn: 130463
2011-04-29 00:03:10 +00:00
Eli Friedman 517728b1ae Revert r130454; apparently this doesn't actually work.
llvm-svn: 130462
2011-04-28 23:55:14 +00:00
Johnny Chen 51cc833af7 Fix a typo.
llvm-svn: 130461
2011-04-28 23:53:16 +00:00
Ted Kremenek 5e1ed7b8dd Enhance clang_getCXTUResourceUsage() to report the sizes of the memory buffers used by PCH.
llvm-svn: 130460
2011-04-28 23:46:20 +00:00
Fariborz Jahanian 6d003c3041 Fixes debug info generation problem for ms_struct structs.
// rdar://8823265

llvm-svn: 130458
2011-04-28 23:43:23 +00:00
Johnny Chen 6cd4d1d85a Modified to take advantage of the iteration protocol for our lldb container objects.
llvm-svn: 130457
2011-04-28 23:34:58 +00:00
Johnny Chen e25799b99b Modified to take advantage of the iteration protocol for our lldb container objects.
llvm-svn: 130456
2011-04-28 23:26:17 +00:00
Eli Friedman 37b9ede969 Fix runline.
llvm-svn: 130455
2011-04-28 23:12:24 +00:00
Eli Friedman e4ecd42926 Fix a rather obscure crash caused by ARM fast-isel generating code which redefines a register.
rdar://problem/9338332 .

llvm-svn: 130454
2011-04-28 23:03:25 +00:00
Argyrios Kyrtzidis 03535265ef Cut down unnecessary zero'ing when value-initializing arrays of C++ objects.
-C++ objects with user-declared constructor don't need zero'ing.
-We can zero-initialize arrays of C++ objects in "bulk" now, in which case don't zero-initialize each object again.

llvm-svn: 130453
2011-04-28 22:57:55 +00:00
Johnny Chen e69c748328 Modify the test suite and lldbutil.py to utilize the Python iteration pattern now that
the lldb iteration protocol has been added to lldb.py module.

llvm-svn: 130452
2011-04-28 22:57:01 +00:00
Fariborz Jahanian 8409bce4ac ms_struct patch for initialization and field access irgen.
// rdar://8823265 - wip.

llvm-svn: 130451
2011-04-28 22:49:46 +00:00
Devang Patel 80d1d3aaec Preserve line number information.
llvm-svn: 130450
2011-04-28 22:48:14 +00:00
Matt Beaumont-Gay c99298ab5e Coalesce some DEBUGs (moving an only-used-in-DEBUG variable's declaration into the DEBUG)
llvm-svn: 130448
2011-04-28 22:26:05 +00:00
Benjamin Kramer cf9d1ad62e We require threse bits to be zero, too.
This shouldn't happen in practice because the icmp would be a constant.
Add a check so we don't miscompile code if something goes wrong.

llvm-svn: 130446
2011-04-28 21:38:51 +00:00
Stuart Hastings 9f02fd9d8d Raise ARM byval minimum size from 32 to 64, addressing a performance
regression in mason.  rdar://problem/7662569

llvm-svn: 130444
2011-04-28 21:35:59 +00:00
Nick Lewycky 6aa79492a5 Only read *predecessor once so as to fix a theoretical issue where it changes
between two reads (threading).

Fix an off-by-one in the indirect counter table that I meant to revert after an
earlier experiment. Whoops!

Implement GCOV_PREFIX. Doesn't handle GCOV_PREFIX_STRIP yet.

Fix an off-by-one in string emission. Extra whoops!

Tolerate DISubprograms that have null Function*'s attached to them. I don't yet
understand what this means, but it happens when you have a global static with
a non-trivial constructor/destructor.

Fix a crash on switch statements with a single successor (default-only).

llvm-svn: 130443
2011-04-28 21:35:49 +00:00
Johnny Chen fbc0d27144 Move the iteration protocol of lldb objects to the auto-generated lldb Python module.
This is so that the objects which support the iteration protocol are immediately obvious
from looking at the lldb.py file.

SBTarget supports two types of iterations: module and breakpoint.  For an SBTarget instance,
you will need to issue either:

    for m in target.module_iter()

or

    for b in target.breakpoint_iter()

For other single iteration protocol objects, just use, for example:

    for thread in process:
        ID = thread.GetThreadID()
        for frame in thread:
            frame.Disassemble()
            ....

llvm-svn: 130442
2011-04-28 21:31:18 +00:00
Daniel Dunbar c44d313cff Driver/Darwin/ld: Set the deployment target following the version information in
the tool chain, instead of based on the translated arguments.

llvm-svn: 130440
2011-04-28 21:23:41 +00:00
Daniel Dunbar c76da44eeb tests: Tweak test to not write to the same temporary twice, in the hopes of avoiding sporadic win32 failures about renaming a temporary.
llvm-svn: 130439
2011-04-28 21:23:38 +00:00
Daniel Dunbar a86188bf8e Target/X86/MC: Add an option for disabling arith relaxation, for my own testing
purposes.

llvm-svn: 130438
2011-04-28 21:23:31 +00:00
Rafael Espindola 6bd6a70837 Add the getExprForFDESymbol method that responsible for computing the
expressions used in the FDE to refer to symbols.

llvm-svn: 130437
2011-04-28 21:04:39 +00:00
Greg Clayton 68ebae61d1 Added the ability to specify dumping options (show types, show location,
depth control, pointer depth, and more) when dumping memory and viewing as
a type.

llvm-svn: 130436
2011-04-28 20:55:26 +00:00
Devang Patel d36bdb5208 Beautify debug info probe output.
llvm-svn: 130435
2011-04-28 20:46:18 +00:00
Ted Kremenek 8d58790019 Enhance clang_getCXTUResourceUsage() to report how much memory is used by SourceManager's memory buffers.
llvm-svn: 130433
2011-04-28 20:36:42 +00:00
Ted Kremenek e203bbb47e Add MemoryBuffer::getBufferKind() to report whether a memory buffer uses malloc'ed or mmap'ed memory. This is for performance analysis.
llvm-svn: 130432
2011-04-28 20:34:18 +00:00
Devang Patel 72aa1a8a68 Remove DbgDeclare only if all uses are converted.
llvm-svn: 130431
2011-04-28 20:32:02 +00:00
Lenny Maiorani 367342e209 Remove bounded StringRef::compare() since nothing but Clang SA was using it and it is just as easy to use StringRef::substr() preceding StringRef::compare() to achieve the same thing.
llvm-svn: 130430
2011-04-28 20:20:12 +00:00
Eli Friedman 7cd5101ad3 fast-isel sret calls, try 2. We actually do need to do something on x86-32. rdar://problem/9303592 .
llvm-svn: 130429
2011-04-28 20:19:12 +00:00
Benjamin Kramer 101720fb58 Fix a comment.
llvm-svn: 130428
2011-04-28 20:09:57 +00:00
Argyrios Kyrtzidis 9d3c504078 Get the base element type even in multidimensional arrays.
llvm-svn: 130427
2011-04-28 20:07:15 +00:00
Chris Lattner a5452c0d67 improve comment.
llvm-svn: 130426
2011-04-28 20:02:57 +00:00
Lenny Maiorani 18470e3287 Use StringRef::substr() and unbounded StringRef::compare() instead of bounded version of StringRef::compare() because bounded version of StringRef::compare() is going to be removed.
llvm-svn: 130425
2011-04-28 19:31:12 +00:00
Ted Kremenek 414a2c0951 Make the top-level driver ignore -fobjc-default-synthesize-properties while this feature undergoes more review and development. This is still available as a -cc1 option for testing.
llvm-svn: 130424
2011-04-28 19:26:03 +00:00
Stuart Hastings dd77c8efa2 Replace unitary array with scalar. rdar://problem/7662569
llvm-svn: 130423
2011-04-28 19:24:47 +00:00
Lenny Maiorani ed2cc6ccbb Eliminates an assert in the strncpy/strncat checker caused by not validating a cast was successful. If the value of an argument was unknown, the cast would result in a NULL pointer which was later being dereferenced.
This fixes Bugzilla #9806.

llvm-svn: 130422
2011-04-28 18:59:43 +00:00
Argyrios Kyrtzidis e07425a5e7 When value-initializing the elements of an array not not included in the initializer make sure
that a non-trivial C++ constructor gets called.

Fixes rdar://9347552 & http://llvm.org/PR9801

llvm-svn: 130421
2011-04-28 18:53:58 +00:00
Argyrios Kyrtzidis fddbcfbec4 Don't waste memory if the initializer expression is empty.
llvm-svn: 130420
2011-04-28 18:53:55 +00:00
Devang Patel 33d87d97f6 Do not lose line number info while eliminating tail call.
llvm-svn: 130419
2011-04-28 18:43:39 +00:00
Eli Friedman 3cf6d4032a Actually revert r130348 correctly.
llvm-svn: 130418
2011-04-28 18:20:24 +00:00
Stuart Hastings 4b21495e42 Replace SmallVector with an array, as suggested by Frits van Bommel. rdar://problem/7662569
llvm-svn: 130417
2011-04-28 18:16:06 +00:00
Chris Lattner 1777601a74 final step needed to resolve PR6627, which allows us to flatten the code down to
a nice and tidy:
  %x1 = load i32* %0, align 4
  %1 = icmp eq i32 %x1, 1179403647
  br i1 %1, label %if.then, label %if.end

instead of doing lots of loads and branches.  May the FreeBSD bootloader
long fit in its allocated space.

llvm-svn: 130416
2011-04-28 18:15:47 +00:00
Chris Lattner 45e393fc9c code cleanups only.
llvm-svn: 130414
2011-04-28 18:08:21 +00:00
Eli Friedman d5a80ca3c8 Revert r130348; causing buildbot issues on x86-32.
llvm-svn: 130412
2011-04-28 18:06:10 +00:00
Douglas Gregor d517d55484 When determining whether two types are reference-compatible, check
non-CVR qualifiers as well as CVR qualifiers. For example, don't allow
a reference to an integer in address space 1 to bind to an integer in
address space 2.

llvm-svn: 130411
2011-04-28 17:56:11 +00:00
Owen Anderson 715973fc6c Fix a bug in tblgen that caused incorrect encodings on instructions that specified operands with "bit" instead of "bits<1>".
Unfortunately, my only testcase for this is fragile, and the ARM AsmParser can't round trip the instruction in question.
<rdar://problem/9345702>

llvm-svn: 130410
2011-04-28 17:51:45 +00:00
Devang Patel b63596436f Add command line option to print debug info in human readable form as comment in llvm IR output. This, i.e -enable-debug-info-comment, is very useful if you want to easily find out which optimization pass is losing line number information.
llvm-svn: 130409
2011-04-28 17:41:38 +00:00
Andrew Trick c4456ae6ec Reapply r130340: Fix for PR9730.
llvm-svn: 130408
2011-04-28 17:30:04 +00:00
Manuel Klimek 7030b869a0 Fixes ArrayTypeTraitExpr (-Wnon-virtual-dtor).
llvm-svn: 130407
2011-04-28 17:03:03 +00:00