Commit Graph

92440 Commits

Author SHA1 Message Date
Gabor Greif 61edf47ec6 typo
llvm-svn: 115148
2010-09-30 15:22:01 +00:00
Jason W Kim 6c233c141e Fix two tiny issues (ARM does not need COFF) and comment sanity.
llvm-svn: 115147
2010-09-30 14:58:19 +00:00
Howard Hinnant a31e741ac9 Name change of intrinsics as suggested by Jeffrey Yasskin
llvm-svn: 115145
2010-09-30 14:04:35 +00:00
Benjamin Kramer 5d66e5feb8 Tighten up prototype verification of strchr and strrchr to avoid a crash in the very unlikely case that someone passes an integer > i64 to strchr.
llvm-svn: 115144
2010-09-30 11:21:59 +00:00
Chandler Carruth f44d350614 Silence a GCC warning about not handling all flags in this switch, we
specifically assert on unexpected flags.

llvm-svn: 115143
2010-09-30 10:59:51 +00:00
Marcin Swiderski 99a9040a1f Added two new command line arguments:
-cfg-add-implicit-dtors - sets CFG::BuildOptions::AddImplicitDtors for AnalysisCosumer to true,
-cfg-add-initializers - sets CFG::BuildOptions::AddInitializers for AnalysisCosumer to true.

llvm-svn: 115142
2010-09-30 07:41:24 +00:00
Jan Wen Voung efbdbe5565 Move logic of determining ELF entsize from the .s printer to initialization
time. That way, the EntrySize field is initialized for other code paths, 
namely, the .ll -> .o code path.

llvm-svn: 115141
2010-09-30 05:59:22 +00:00
Rafael Espindola 9d98ac645e Add another test that now passes.
llvm-svn: 115137
2010-09-30 04:22:07 +00:00
Jim Grosbach 689651c767 trailing whitespace
llvm-svn: 115136
2010-09-30 03:21:00 +00:00
Jim Grosbach 58bce99385 Remove misplaced ';'. Make buildbots happy, hopefully.
llvm-svn: 115135
2010-09-30 03:20:34 +00:00
Rafael Espindola 70d6e0e0ff Correctly produce R_X86_64_32 or R_X86_64_32S.
With this patch in

movq    $foo, foo(%rip)
foo:
.long   foo

We produce a R_X86_64_32S for the first relocation and R_X86_64_32 for the
second one.

llvm-svn: 115134
2010-09-30 03:11:42 +00:00
Jason W Kim 645f6c2bef Tiny patch for proof-of-concept cleanup of ARMAsmPrinter::EmitStartOfAsmFile()
Small test for sanity check of resulting ARM .s file.
Tested against -r115129.

llvm-svn: 115133
2010-09-30 02:45:56 +00:00
Jan Wen Voung b96b2d8e4d Have ELFAsmParser.cpp use the already parsed "Size" (entry size) when
constructing a section. Test for a few cases also included.

llvm-svn: 115132
2010-09-30 02:41:46 +00:00
Rafael Espindola 2ebaee9c75 Make it possible for the MCObjectWriter to decide if a given fixup is fully
resolved or not. Different object files have different restrictions and
different native assemblers have different idiosyncrasies we want to emulate
for now.

Move the existing MachO logic to the new place and implement an ELF one that
gets fixups to globals right.

llvm-svn: 115131
2010-09-30 02:22:20 +00:00
Jim Grosbach 4a9cb8f10e Go ahead and jump!
Now that the MC lowering handles the expansion of the pseudos, kill the horrible
blobs of text.

llvm-svn: 115130
2010-09-30 02:18:06 +00:00
Jason W Kim b32124545b I added a new file ARMAsmBackend which stubs out in similar ways to
the eqv X86 class.
For now, I split the ELFARMAsmBackend from the DarwinARMAsmBackend
(also mimicking X86)

Tested against -r115126

llvm-svn: 115129
2010-09-30 02:17:26 +00:00
Jim Grosbach 2ff7de0264 Now that the pseudos that needed this are all custom lowered, we can go back
to an empty PrintSpecial()

llvm-svn: 115128
2010-09-30 02:02:22 +00:00
Jim Grosbach 080fdf4609 Nuke it from orbit. It's the only way to be sure.
(Kill the dead non-MC asm printer for the ARM target.)

llvm-svn: 115127
2010-09-30 01:57:53 +00:00
Jim Grosbach 4a57b76eea Let a target specify whether it wants an assembly printer to be the MC version
or not. TableGen needs to generate the printInstruction() function as taking
an MCInstr* or a MachineInstr*, depending. Default to the old non-MC
version so that everything not yet using MC continues to just work without
fidding.

llvm-svn: 115126
2010-09-30 01:29:54 +00:00
Johnny Chen 832d2333a5 Added a utility function to return the counterpart C++ compiler of $(CC) and use
it inside Makefile.rules to return clang++ on clang and llvm-g++ on llvm-gcc.

Removed CPLUSPLUSFLAGS which is simply wrong and CPPFLAGS which is unnecessary.

llvm-svn: 115125
2010-09-30 01:22:34 +00:00
Chris Lattner 510a81a89b fix incorrect link!
llvm-svn: 115124
2010-09-30 01:12:09 +00:00
Tom Care ea7c48ccf7 Updated scan-build:
- Idempotent operations are on by default, to match --analyze in the driver.
- Integrated stats calculation based on parsing warnings emitted with the -analyzer-stats flag. The new -stats flag enables this.
- New -maxloop flag to pass down a maxloop value to the analyzer.

llvm-svn: 115123
2010-09-30 01:12:05 +00:00
Jan Wen Voung c768287968 Test commit - Deleted some whitespace at the end of a line.
llvm-svn: 115122
2010-09-30 01:09:20 +00:00
Evan Cheng 2fb20b1d37 ARM instruction itinerary fixes:
1. Cortex-a9 8-bit and 16-bit loads / stores AGU cycles are 1 cycle longer than 32-bit ones.
2. Cortex-a9 is out-of-order so model all read cycles as cycle 1.
3. Lots of other random fixes for A8 and A9.

llvm-svn: 115121
2010-09-30 01:08:25 +00:00
Ted Kremenek b0e7d77729 Include changes to VisitCXXMemberCallExpr (call visitor functions).
llvm-svn: 115120
2010-09-30 01:06:29 +00:00
Ted Kremenek e18dd0a84e Change CheckerVisitor so that [Pre,Post]VisitCallExpr only handles CallExprs for simple C functions, not
all CallExprs (including CXXMemberCallExpr, etc.).  Now the generic handler for all CallExprs is [Pre,Post]VisitGenericCallExpr.

Also add [Pre,Post]Visit hooks for CXXMemberCallExpr.

Change GRExprEngine::VisitCXXMemberCallExpr() to do pre/post checker visits of the call.

llvm-svn: 115119
2010-09-30 01:06:26 +00:00
Sebastian Redl 99219f16b9 Make the FileID import map key on FileID.
llvm-svn: 115118
2010-09-30 01:03:06 +00:00
Sebastian Redl 517523014d In MeasureTokenLength, the FileLoc supplied to the lexer must point to the start of the buffer, or we risk overflow.
llvm-svn: 115117
2010-09-30 01:03:03 +00:00
Benjamin Kramer 2b76c66fd6 Add constant folding for strspn and strcspn to SimplifyLibCalls.
llvm-svn: 115116
2010-09-30 00:58:35 +00:00
Jim Ingham 6c68fb4549 Add "-o" option to "expression" which prints the object description if available.
llvm-svn: 115115
2010-09-30 00:54:27 +00:00
Francois Pichet 083f368be1 Revert r114320(move file = copy + delete on Win32). r115040 is a better solution for the Win32 ACCESS_DENIED lit error.
llvm-svn: 115114
2010-09-30 00:44:58 +00:00
Ted Kremenek 3d6c0c0091 Tweak nil receiver checker to not warning about 64-bit return values.
Fixes: <rdar://problem/7513117>
llvm-svn: 115113
2010-09-30 00:37:10 +00:00
Chris Lattner 3458ab6001 add a bunch of entries for external projects.
llvm-svn: 115112
2010-09-30 00:34:43 +00:00
Benjamin Kramer 38d22f69fc Add strpbrk folding to SimplifyLibCalls.
llvm-svn: 115111
2010-09-29 23:52:12 +00:00
Tom Care 2f0419e1f8 AnalyzerStatsChecker improvements:
- Use BlockEntrance rather than BlockEdge to bring in line with UnreachableCodeChecker. Fixes an issue where unreached blocks would still be counted as reachable.
- Added warnings for all BlockAborted locations. This allows us to see where the analyzer stopped analyzing.

llvm-svn: 115110
2010-09-29 23:48:34 +00:00
Tom Care a5f13c866c Modified the ccc-analyzer script to print the compiler command when log level verbosity is enabled. This is handy for debugging.
llvm-svn: 115109
2010-09-29 23:48:31 +00:00
Tom Care 472205be35 Change -analyzer-max-nodes to allow 0 as a parameter. This allows the analyzer to completely analyze a worklist regardless of time taken.
llvm-svn: 115108
2010-09-29 23:48:13 +00:00
Nick Lewycky 83e471180c Silence compiler warning.
llvm-svn: 115107
2010-09-29 23:32:20 +00:00
Owen Anderson 74c06b202f Revert r115099 (adding early jump threading). It's not clear if the benefits are worth the compile time cost.
llvm-svn: 115106
2010-09-29 23:31:09 +00:00
Eric Christopher 7939806ecc Refactor arm fast isel libcall handling so that pieces can be used
for generic call handling.

llvm-svn: 115105
2010-09-29 23:11:09 +00:00
Devang Patel 7c086227e6 Attach aritifical attribute with implicit parameters.
Radar 8493141.

llvm-svn: 115104
2010-09-29 23:09:21 +00:00
Devang Patel a3dc31d8ee ImplicitParamDecl is always implicit.
llvm-svn: 115103
2010-09-29 23:08:00 +00:00
Devang Patel bea08d1c85 Let FE mark a variable as artificial variable.
llvm-svn: 115102
2010-09-29 23:07:21 +00:00
Eric Christopher 0574cc556a Noticed by inspection when looking for other cmov bits.
llvm-svn: 115100
2010-09-29 23:00:29 +00:00
Owen Anderson 6d33f59952 Early CFG simplification can fold conditionals down to selects, which is often a good thing, but it can also
hide jump threading opportunities by turning control flow into data flow.  Run an early JumpThreading pass
(adds approximately an additional 1% to optimization time on SPEC), allowing it to get a shot at these cases
first.  Fixes <rdar://problem/8447345>.

llvm-svn: 115099
2010-09-29 22:57:02 +00:00
Evan Cheng 4a010fd1ea Model Cortex-a9 load to SUB, RSB, ADD, ADC, SBC, RSC, CMN, MVN, or CMP
pipeline forwarding path.

llvm-svn: 115098
2010-09-29 22:42:35 +00:00
Benjamin Kramer 2016f0eaac Silence msvc warnings.
llvm-svn: 115097
2010-09-29 22:38:50 +00:00
Jim Grosbach a5497345ad trailing whitespace
llvm-svn: 115096
2010-09-29 22:32:50 +00:00
Benjamin Kramer 8e861d7eee Simplify the loop in StrChrOptimizer. FileCheckize test.
llvm-svn: 115095
2010-09-29 22:29:12 +00:00
Eric Christopher b024be3162 Add a convenience variable so I'm not chasing all over looking for
a context.

llvm-svn: 115094
2010-09-29 22:24:45 +00:00