Commit Graph

147393 Commits

Author SHA1 Message Date
Adrian Prantl 751a5e1802 get rid of stdio.h include in testcase
llvm-svn: 179237
2013-04-10 23:09:00 +00:00
Adrian Prantl 5686668776 add mips target requirement to testcase
llvm-svn: 179236
2013-04-10 23:08:57 +00:00
Anna Zaks 07804ef87e [analyzer] Address Jordan’s review of r179219
llvm-svn: 179235
2013-04-10 22:56:33 +00:00
Anna Zaks 3f303be636 [analyzer] Address Jordan’s code review of r 179221
llvm-svn: 179234
2013-04-10 22:56:30 +00:00
Tobias Grosser f242b806ac ScheduleOpt: Do not crash on statements with empty iteration domains
Statements with an empty iteration domain may not have a schedule assigned by
the isl schedule optimizer. As Polly expects each statement to have a schedule,
we keep the old schedule for such statements.

This fixes http://llvm.org/PR15645`

Reported-by: Johannes Doerfert  <johannesdoerfert@gmx.de>
llvm-svn: 179233
2013-04-10 22:48:08 +00:00
Anton Yartsev 8fc29db312 [analyzer] +Testcase: several used-after-free args passed to a function.
llvm-svn: 179232
2013-04-10 22:36:16 +00:00
Anton Yartsev cb2ccd6b79 [analyzer] Switched to checkPreCall interface for detecting usage after free.
Now the check is also applied to arguments for Objective-C method calls and to 'this' pointer.

llvm-svn: 179230
2013-04-10 22:21:41 +00:00
Jack Carter d62445dce4 Mips specific inline asm memory operand modifier test case
These changes are based on commit responses for r179135.

llvm-svn: 179229
2013-04-10 22:10:45 +00:00
Anna Zaks 60d98befe8 [analyzer] Fix a crash in SyntaxCString checker when given a custom strncat.
Fixes PR13476

llvm-svn: 179228
2013-04-10 22:06:29 +00:00
Hal Finkel 95081bff72 Manually remove successors in if conversion when CopyAndPredicateBlock is used
In the simple and triangle if-conversion cases, when CopyAndPredicateBlock is
used because the to-be-predicated block has other predecessors, we need to
explicitly remove the old copied block from the successors list. Normally if
conversion relies on TII->AnalyzeBranch combined with BB->CorrectExtraCFGEdges
to cleanup the successors list, but if the predicated block contained an
un-analyzable branch (such as a now-predicated return), then this will fail.

These extra successors were causing a problem on PPC because it was causing
later passes (such as PPCEarlyReturm) to leave dead return-only basic blocks in
the code.

llvm-svn: 179227
2013-04-10 22:05:25 +00:00
Bill Wendling 5be12a1462 No need to have this return a bool.
llvm-svn: 179226
2013-04-10 22:03:59 +00:00
Jack Carter b6bcdfd23d Mips specific inline asm memory operand modifier test case
These changes are based on commit responses for r179135.

llvm-svn: 179225
2013-04-10 22:02:32 +00:00
Bill Wendling e3335039b6 Move info to CREDITS.TXT file.
llvm-svn: 179224
2013-04-10 21:56:52 +00:00
Kay Tiong Khoo 394bf1482b fixed xsave, xsaveopt, xrstor mnemonics with intel syntax; added test cases
llvm-svn: 179223
2013-04-10 21:52:25 +00:00
Eric Christopher f8d5b64464 Revert "Update the version of dwarf we say we're emitting to at least 3."
temporarily while we work on plumbing through some changes to continue
supporting gdb on darwin.

This reverts commit r179122.

llvm-svn: 179222
2013-04-10 21:45:07 +00:00
Anna Zaks e51362e7f7 [analyzer] When reporting a leak in RetainCount checker due to an early exit from init, step into init.
The heuristic here (proposed by Jordan) is that, usually, if a leak is due to an early exit from init, the allocation site will be
a call to alloc. Note that in other cases init resets self to [super init], which becomes the allocation site of the object.

llvm-svn: 179221
2013-04-10 21:42:06 +00:00
Bill Wendling 2d1df6be87 Track the compact unwind encoding for when we are unable to generate compact unwind information.
Compact unwind has an encoding for when we're not able to generate compact
unwind and must generate an EH frame instead. Track that, but still emit that CU
encoding.

llvm-svn: 179220
2013-04-10 21:42:06 +00:00
Anna Zaks 7c19abeba6 [analyzer] Cleanup leak warnings: do not print the names of variables from other functions.
llvm-svn: 179219
2013-04-10 21:42:02 +00:00
Eric Christopher a75018aeba For split dwarf we should also run the objcopy action if we're
just assembling a file and have passed the option.

llvm-svn: 179218
2013-04-10 21:30:40 +00:00
Chad Rosier f2d396439a Remove unused arguments.
llvm-svn: 179217
2013-04-10 21:30:03 +00:00
Chad Rosier 153d7c616c [driver] Add a -Ofast option, which enables -O3, -ffast-math, and
-fstrict-aliasing.
rdar://13622687

llvm-svn: 179216
2013-04-10 21:26:02 +00:00
Kay Tiong Khoo 6f76c2106e fixed to disassemble with tab after mnemonic rather than space
llvm-svn: 179215
2013-04-10 21:17:58 +00:00
Reid Kleckner e494399203 FileCheck-ify some clang grep tests that use double quotes
The escaping interaction between Python and grep doesn't work on my
system.  This change fixes the tests for me.

llvm-svn: 179214
2013-04-10 21:10:39 +00:00
Benjamin Kramer 04b6e80381 Use a real union for IdentifyingPassPtr.
This avoids a nasty const correctness issue (AnalysisIDs are const, Pass* isn't).

llvm-svn: 179213
2013-04-10 20:50:44 +00:00
Bill Wendling c03998bdb5 Marking myself as release manager.
If anyone objects please let me know.

llvm-svn: 179212
2013-04-10 20:13:28 +00:00
Preston Gurd ddf96b5072 In the X86 back end, getMemoryOperandNo() returns the offset
into the operand array of the start of the memory reference descriptor.

Additional code in EncodeInstruction provides an additional adjustment.

This patch places that additional code in a separate function,
called getOperandBias, so that any caller of getMemoryOperandNo
can also call getOperandBias.

llvm-svn: 179211
2013-04-10 20:11:59 +00:00
Chad Rosier 70f47596b7 Tidy up, fix and simplify a few of the SMLocs. Prior to r179109 the Start SMLoc
wasn't always the start of the operand.  If there was a symbol reference, then
Start pointed to that token.  It's very likely there are other places that need
to be updated.

llvm-svn: 179210
2013-04-10 20:07:47 +00:00
Jyotsna Verma 9dea0955ce Add object-emission flag for lit tests. This flag is used
to disable following tests for Hexagon that require direct object
generation support.

DebugInfo/dwarf-public-names.ll
DebugInfo/dwarf-version.ll
DebugInfo/member-pointers.ll
DebugInfo/namespace.ll
DebugInfo/two-cus-from-same-file.ll

Fixes bug 15616 - http://llvm.org/bugs/show_bug.cgi?id=15616

llvm-svn: 179209
2013-04-10 19:53:26 +00:00
Howard Hinnant f2ca35cd79 Add capability to demangle invocation functions for ObjC blocks.
llvm-svn: 179208
2013-04-10 19:44:03 +00:00
Nadav Rotem 73dffa4184 Make the SLP store-merger less paranoid about function calls. We check for function calls when we check if it is safe to sink instructions.
llvm-svn: 179207
2013-04-10 19:41:36 +00:00
Nadav Rotem 88dd5f7a38 We require DataLayout for analyzing the size of stores.
llvm-svn: 179206
2013-04-10 18:57:27 +00:00
Chad Rosier 53eb7d7984 Remove unused variable.
llvm-svn: 179205
2013-04-10 18:46:58 +00:00
Dmitri Gribenko c922b71d60 -fparse-all-comments: remove redundant check, as suggested by Fariborz Jahanian
llvm-svn: 179204
2013-04-10 18:43:09 +00:00
Hal Finkel 30ae229141 PPC: Don't predicate a diamond with two counter decrements
I've not seen this happen in practice, and probably can't until we start
allowing decrement-counter-based conditional branches to be double predicated,
but just in case, don't allow predication of a diamond in which both sides have
ctr-defining branches. Even though the branching behavior of these can be
predicated, the counter-decrementing behavior cannot be.

llvm-svn: 179199
2013-04-10 18:30:16 +00:00
Chad Rosier ea1d1a2d05 [ms-inline asm] Move a few test cases from the 32-bit version to the 64-bit
version as lea is only available in 64-bit mode.

llvm-svn: 179190
2013-04-10 18:08:17 +00:00
Chad Rosier 1863f4f472 Reapply r179115, but use parsePrimaryExpression a little more judiciously.
Test cases that regressed due to r179115, plus a few more, were added in
r179182.  Original commit message below:

[ms-inline asm] Use parsePrimaryExpr in lieu of parseExpression if we need to
parse an identifier.  Otherwise, parseExpression may parse multiple tokens,
which makes it impossible to properly compute an immediate displacement.
An example of such a case is the source operand (i.e., [Symbol + ImmDisp]) in
the below example:

 __asm mov eax, [Symbol + ImmDisp]

Part of rdar://13611297

llvm-svn: 179187
2013-04-10 17:35:30 +00:00
Michel Danzer 8caa904bde R600/SI: Add pattern for AMDGPUurecip
21 more little piglits with radeonsi.

Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
llvm-svn: 179186
2013-04-10 17:17:56 +00:00
Reed Kotler fe94cc3ea0 This is for an experimental option -mips-os16. The idea is to compile all
Mips32 code as Mips16 unless it can't be compiled as Mips 16. For now this
would happen as long as floating point instructions are not needed.
Probably it would also make sense to compile as mips32 if atomic operations
are needed too. There may be other cases too.

A module pass prescans the IR and adds the mips16 or nomips16 attribute
to functions depending on the functions needs.

Mips 16 mode can result in a 40% code compression by utililizing 16 bit
encoding of many instructions.

The hope is for this to replace the traditional gcc way of dealing with
Mips16 code using floating point which involves essentially using soft float
but with a library implemented using mips32 floating point. This gcc 
method also requires creating stubs so that Mips32 code can interact with
these Mips 16 functions that have floating point needs. My conjecture is
that in reality this traditional gcc method would never win over this
new method.

I will be implementing the traditional gcc method also. Some of it is already
done but I needed to do the stubs to finish the work and those required
this mips16/32 mixed mode capability.

I have more ideas for to make this new method much better and I think the old
method will just live in llvm for anyone that needs the backward compatibility
but I don't for what reason that would be needed.

llvm-svn: 179185
2013-04-10 16:58:04 +00:00
Peter Collingbourne adac407ed9 Use a scheme closer to that of GNU as when deciding the type of a
symbol with multiple .type declarations.

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

llvm-svn: 179184
2013-04-10 16:52:15 +00:00
Sebastian Pop 1006614228 fix testcase
llvm-svn: 179183
2013-04-10 16:44:08 +00:00
Chad Rosier e6956c3ec5 [ms-inline asm] Add a few test cases that were regressed by r179115. That
commit was reverted in r179120, but I do plan on reapplying with a fix shortly.
Part of rdar://13611297

llvm-svn: 179182
2013-04-10 16:33:34 +00:00
Dmitri Gribenko 061f32847f Add testcases for -fparse-all-comments
llvm-svn: 179181
2013-04-10 16:31:58 +00:00
Dmitri Gribenko a7d16ceee6 Add an option to parse all comments as documentation comments
Patch by Amin Shali.

llvm-svn: 179180
2013-04-10 15:35:17 +00:00
Rafael Espindola 641c9bcfd5 Template MachOObjectFile over endianness too.
llvm-svn: 179179
2013-04-10 15:33:44 +00:00
Rafael Espindola 6cd7cc7e30 Simplify the templating a bit.
Since we only ever instantiate with a type that is a MachOType instantiation,
we don't need to pass template argument.

llvm-svn: 179178
2013-04-10 15:18:39 +00:00
Alexander Potapenko 227e22de5a [ASan] Do not check the shadow of NULL argument in the time() interceptor.
Add a test for time().

llvm-svn: 179177
2013-04-10 15:13:00 +00:00
Rafael Espindola 6bebee0d5c Move two methods out of line.
llvm-svn: 179176
2013-04-10 14:57:48 +00:00
Kostya Serebryany 92684efb1d [asan] implement callbacks for unaligned loads/stores
Reviewers: samsonov

Reviewed By: samsonov

CC: samsonov, llvm-commits

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

llvm-svn: 179175
2013-04-10 13:59:32 +00:00
Vincent Lejeune 04d9aa4822 R600: Add VTX_READ_* and RAT_WRITE_CACHELESS_* when computing cf addr
llvm-svn: 179174
2013-04-10 13:29:20 +00:00
Reid Kleckner d16abb7732 [test] Use lit's shell test runner on Windows
Summary:
I did a local comparison between using bash and using lit's runner, and
more of the suite passes with lit than passes with bash.  Most of the
bash failures have to do with /dev/null, which is nonsensical on
Windows, but the lit runner handles it.

The lit shell runner is also much faster than bash, so I would expect
most Windows devs would want it by default.

The behavior can be overridden on any OS by setting
LIT_USE_INTERNAL_SHELL to 0 or 1 in the environment.

Reviewers: chapuni, ddunbar

CC: llvm-commits, timurrrr

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

llvm-svn: 179173
2013-04-10 13:11:38 +00:00