Commit Graph

110639 Commits

Author SHA1 Message Date
Johnny Chen 8446277c11 Fix a logic error caught by the static analyzer.
llvm-svn: 137328
2011-08-11 19:12:10 +00:00
Johnny Chen 64503c8168 To silence the static analyzer.
llvm-svn: 137326
2011-08-11 19:03:44 +00:00
Owen Anderson 3477f2cea5 Tighten decoding of addrmode2 instructions to reject more UNPREDICTABLE cases.
llvm-svn: 137325
2011-08-11 19:00:18 +00:00
Bruno Cardoso Lopes 043c820800 Fix PR10492 by teaching MOVHLPS and MOVLPS mask matching to be more strict.
llvm-svn: 137324
2011-08-11 18:59:13 +00:00
Owen Anderson 0e15b48f3c Tighten operand decoding of addrmode2 instruction. The offset register cannot be PC.
llvm-svn: 137323
2011-08-11 18:55:42 +00:00
Owen Anderson e33c95d39b Correct immediate range for shifter operands. Patch by James Molloy, with additional encoding fixes added by me.
llvm-svn: 137322
2011-08-11 18:41:59 +00:00
Benjamin Kramer fa7e6a54b1 Plug a memory leak.
llvm-svn: 137321
2011-08-11 18:39:28 +00:00
Owen Anderson ed25385227 Improve error checking in the new ARM disassembler. Patch by James Molloy.
llvm-svn: 137320
2011-08-11 18:24:51 +00:00
Johnny Chen d14651afaf To silence the static analyzer.
llvm-svn: 137319
2011-08-11 18:21:06 +00:00
Jim Grosbach 27ad83d8a9 ARM push of a single register encodes as pre-indexed STR.
Per the ARM ARM, a 'push' of a single register encodes as an STR,
not an STM.

llvm-svn: 137318
2011-08-11 18:07:11 +00:00
Andrew Trick 266ab10012 Cleanup. Another thorough review by Nick!
llvm-svn: 137317
2011-08-11 17:54:58 +00:00
Jim Grosbach 8ba76c6d5c ARM pop of a single register encodes as post-indexed LDR.
Per the ARM ARM, a 'pop' of a single register encodes as an LDR,
not an LDM.

llvm-svn: 137316
2011-08-11 17:35:48 +00:00
Justin Holewinski 6c6a7fd692 PTX: Add basic documentation to CodeGenerator.html
llvm-svn: 137315
2011-08-11 17:34:16 +00:00
Enrico Granata 8c9d35603e Fixed an issue where a pointer's address was being logged instead of its value
Access to synthetic children by name:
 if your object has a synthetic child named foo you can now type
  frame variable object.foo (or ->foo if you have a pointer)
  and that will print the value of the synthetic child
  (if your object has an actual child named foo, the actual child prevails!)
 this behavior should also work in summaries, and you should be able to use
 ${var.foo} and ${svar.foo} interchangeably
  (but using svar.foo will mask an actual child named foo)

llvm-svn: 137314
2011-08-11 17:08:01 +00:00
Nadav Rotem efdd183f52 Add a comment, per Bruno's CR.
llvm-svn: 137313
2011-08-11 17:05:47 +00:00
Sean Callanan da6df8a186 Extended the AST importer to support ParenTypes.
This is necessary to support importing certain
function pointer types.

llvm-svn: 137311
2011-08-11 16:56:07 +00:00
Nadav Rotem 61140e1028 [AVX] When joining two XMM registers into a YMM register, make sure that the
lower XMM register gets in first. This will allow the SUBREG pattern to
elliminate the first vector insertion. 

llvm-svn: 137310
2011-08-11 16:49:36 +00:00
Anna Zaks 22a9d0f316 Analyzer Core: Adding support for user-defined symbol dependencies. (For example, the allocated resource symbol only needs to be freed if no error has been returned by the allocator, so a checker might want to make the lifespan of the error code symbol depend on the allocated resource symbol.) Note, by default, the map that holds the dependencies will get destroyed along with the SymbolManager at the end of function exploration.
llvm-svn: 137309
2011-08-11 16:43:28 +00:00
Nadav Rotem 1542d5a00a [AVX] If the data which is going to be saved is already in two XMM registers
(for example, after integer operation), do not pack the registers into a YMM
before saving. Its better to save as two XMM registers.

Before:
                vinsertf128         $1, %xmm3, %ymm0, %ymm3
                vinsertf128         $0, %xmm1, %ymm3, %ymm1
                vmovaps              %ymm1, 416(%rsp)

After:
                vmovaps              %xmm3, 416+16(%rsp)
                vmovaps              %xmm1, 416(%rsp)

llvm-svn: 137308
2011-08-11 16:41:21 +00:00
Greg Clayton aa51684318 Patch for "process load" by Filipe Cabecinhas.
Filipe was attempting to do a:

(lldb) process load ~/path/foo.dylib

But the process load command wasn't resolving the path. We have to be careful
about resolving the path here because we want to do it in terms of the platform
we are using. the "~/" can mean a completely different path if you are remotely
debugging on another machine as another user. So to support this, platforms now
can resolve remote paths:

bool
Platform::ResolveRemotePath (const FileSpec &platform_path,
                             FileSpec &resolved_platform_path);

The host/local platform will just resolve the path.
                             

llvm-svn: 137307
2011-08-11 16:25:18 +00:00
Chris Lattner 5a2c70cc8f add missing colon, thanks peter.
llvm-svn: 137306
2011-08-11 16:15:10 +00:00
Raghesh Aloor e75e986d03 Removing some trailing whitespaces
llvm-svn: 137304
2011-08-11 08:44:56 +00:00
Chris Lattner 96710b4308 fix PR10605 / rdar://9930964 by adding a pretty scary missed check.
It's somewhat surprising anything works without this.  Before we would
compile the testcase into:

test:                                   # @test
	movl	$4, 8(%rdi)
	movl	8(%rdi), %eax
	orl	%esi, %eax
	cmpl	$32, %edx
	movl	%eax, -4(%rsp)          # 4-byte Spill
	je	.LBB0_2

now we produce:

test:                                   # @test
	movl	8(%rdi), %eax
	movl	$4, 8(%rdi)
	orl	%esi, %eax
	cmpl	$32, %edx
	movl	%eax, -4(%rsp)          # 4-byte Spill
	je	.LBB0_2
llvm-svn: 137303
2011-08-11 06:26:54 +00:00
Craig Topper 6d64a738fa Add tests for string literal concatenation.
llvm-svn: 137302
2011-08-11 05:57:09 +00:00
Craig Topper 5265bb211d Raw string followup. Pass a couple StringRefs by value.
llvm-svn: 137301
2011-08-11 05:10:55 +00:00
Greg Clayton 0c02e4eaea Fix the broken build that happened with my last checkin.
llvm-svn: 137300
2011-08-11 04:30:39 +00:00
Craig Topper 93b3e848de Update C++0x status page to reflect support for raw string literals.
llvm-svn: 137299
2011-08-11 04:09:26 +00:00
Craig Topper 54edccafc5 Add support for C++0x raw string literals.
llvm-svn: 137298
2011-08-11 04:06:15 +00:00
Bruno Cardoso Lopes dbd1352c80 Cleanup: Remove Int_ CVTSS2SI* forms
llvm-svn: 137297
2011-08-11 02:52:36 +00:00
Bruno Cardoso Lopes a2d8bb97b9 Splats for v8i32/v8f32 can be handled by VPERMILPSY. This was causing
infinite recursive calls in legalize. Fix PR10562

llvm-svn: 137296
2011-08-11 02:49:44 +00:00
Bruno Cardoso Lopes 572c9aaf53 Use the splat index to generate the desired shuffle. Otherwise we
could only get undefs and the vector shuffle becomes an undef,
generating wrong code.

llvm-svn: 137295
2011-08-11 02:49:41 +00:00
Greg Clayton aa149cbd86 Added the ability to remove orphaned module shared pointers from a ModuleList.
This is helping us track down some extra references to ModuleSP objects that
are causing things to get kept around for too long. 

Added a module pointer accessor to target and change a lot of code to use 
it where it would be more efficient.

"taret delete" can now specify "--clean=1" which will cleanup the global module
list for any orphaned module in the shared module cache which can save memory
and also help track down module reference leaks like we have now.

llvm-svn: 137294
2011-08-11 02:48:45 +00:00
John McCall 8e4c74bb7c Simplify EH control flow by observing that EH scopes form a simple
hierarchy of delegation, and that EH selector values are meaningful
function-wide (good thing, too, or inlining wouldn't work).
2,3d
1a
hierarchy of delegation and that EH selector values have the same
meaning everywhere in the function instead of being meaningful only
in the context of a specific selector.

This removes the need for routing edges through EH cleanups,
since a cleanup simply always branches to its enclosing scope.

llvm-svn: 137293
2011-08-11 02:22:43 +00:00
Eli Friedman 3ae39f8ad1 Fix X86TargetLowering::LowerExternalSymbol so that it actually works in non-trivial cases. This hasn't been an issue before because the function isn't normally called (but apparently is used to generate a tail-call to sin() on ELF x86-32 with PIC and SSE2).
Fixes PR9693.

llvm-svn: 137292
2011-08-11 01:48:05 +00:00
Johnny Chen e1894cf97c Add logic to SBValue.linked_list_iter() to detect infinite loop and to bail out early.
Add code to test case to create an evil linked list with:

    task_evil -> task_2 -> task_3 -> task_evil ...

and to check that the linked list iterator only iterates 3 times.

llvm-svn: 137291
2011-08-11 01:19:46 +00:00
Anna Zaks e6d0c86297 Make SymbolManager comments doxygen friendly.
llvm-svn: 137290
2011-08-11 01:03:22 +00:00
Johnny Chen 9c1b703ac4 Change the SBValue.linked_list_iter() to treat the value object as a homogeneous linked list data structure
where an empty linked list is represented as a value object with a NULL value, instead of a special value
object which 'points' to NULL.

Also modifies the test case to comply.

rdar://problem/9933692

llvm-svn: 137289
2011-08-11 00:49:03 +00:00
Johnny Chen 3c24a17c7c Incremental fixes of issues found by Xcode static analyzer.
llvm-svn: 137288
2011-08-11 00:43:20 +00:00
Jim Ingham 478235d882 In the case where we are trying to resume a thread all the way to 0, if we get
llvm-svn: 137287
2011-08-11 00:38:52 +00:00
Chad Rosier 9019fd3813 Typo.
llvm-svn: 137286
2011-08-11 00:22:48 +00:00
Johnny Chen 8082a00dcb When a benchmarks test fails, the re-run command should include the '+b' option instead of the '-t' option.
llvm-svn: 137285
2011-08-11 00:16:28 +00:00
Anna Zaks 173864b36c Cleanup: remove CleanedSate member and GetState() wrapper from StmtNodeBuilder, not needed as of r137273.
llvm-svn: 137284
2011-08-11 00:11:21 +00:00
Devang Patel 784077eb57 Stay within 80 columns.
llvm-svn: 137283
2011-08-10 23:58:09 +00:00
Jim Grosbach d5d6359785 ARM LDRT assembly parsing and encoding.
llvm-svn: 137282
2011-08-10 23:43:54 +00:00
Anna Zaks e309e05603 Cleanup: remove GetState() wrapper from ExprEngine, not needed as of r137273.
llvm-svn: 137279
2011-08-10 23:34:53 +00:00
Jim Grosbach d3f7bcd43c Tidy up. 80 columns.
llvm-svn: 137277
2011-08-10 23:23:47 +00:00
Andrew Trick d3530b9117 Reapplying r136844.
An algorithm for incrementally updating LoopInfo within a
LoopPassManager. The incremental update should be extremely cheap in
most cases and can be used in places where it's not feasible to
regenerate the entire loop forest.

- "Unloop" is a node in the loop tree whose last backedge has been removed.
- Perform reverse dataflow on the block inside Unloop to propagate the
  nearest loop from the block's successors.
- For reducible CFG, each block in unloop is visited exactly
  once. This is because unloop no longer has a backedge and blocks
  within subloops don't change parents.
- Immediate subloops are summarized by the nearest loop reachable from
  their exits or exits within nested subloops.
- At completion the unloop blocks each have a new parent loop, and
  each immediate subloop has a new parent.

llvm-svn: 137276
2011-08-10 23:22:57 +00:00
Johnny Chen 119fd6c03b Ignore the static analyzer, instead; and add comment why.
llvm-svn: 137275
2011-08-10 23:19:32 +00:00
Jim Grosbach 94ba2cba6e ARM tests for LDRSHT assembly parsing and encoding.
llvm-svn: 137274
2011-08-10 23:18:30 +00:00
Anna Zaks 5a56a6653f Analyzer Core: In checkDeadSymbols checker callback, provide the state in which the symbols are not yet deleted so that checkers could inspect them. Since we are now always creating a transition in ProcessStmt(), remove the logic for adding a transition when none was generated. TODO: the extra transitions will have to be removed; more cleanups; a checker that tests teh new fucntionality.
llvm-svn: 137273
2011-08-10 23:14:54 +00:00