Kaelyn Uhrain
055e9479eb
Fix up the 'typename' suggestion logic introduced in r157085, based on
...
feedback from Doug Gregor.
llvm-svn: 158185
2012-06-08 01:07:26 +00:00
Richard Smith
f76568591c
PR13047: Fix various abuses of clang::Type in the MS mangler, to make it work
...
in the presence of type sugar.
llvm-svn: 158184
2012-06-08 00:37:04 +00:00
Owen Anderson
da6bd3e603
Teach the AsmMatcherEmitter to allow InstAlias' where the suboperands of a complex operand are called out explicitly in the asm string.
...
llvm-svn: 158183
2012-06-08 00:25:03 +00:00
Douglas Gregor
aadbfafcd1
Fix typo "CursorKind.CONDITONAL_OPERATOR" in Python bindings, from
...
Manish Verma!
llvm-svn: 158182
2012-06-08 00:16:27 +00:00
Chandler Carruth
392357eea0
Rename a test case to a more generic name. This is a completely useless
...
test, but David Sehr is looking at spiffing it up and adding some proper
tests for our alloca codegen.
llvm-svn: 158181
2012-06-08 00:06:56 +00:00
Anna Zaks
b60908db3a
[analyzer] Add experimental "issue hash" to the plist diagnostic.
...
CmpRuns.py can be used to compare issues from different analyzer runs.
Since it uses the issue line number to unique 2 issues, adding a new
line to the beginning of a file makes all issues in the file reported as
new.
The hash will be an opaque value which could be used (along with the
function name) by CmpRuns to identify the same issues. This way, we only
fail to identify the same issue from two runs if the function it appears
in changes (not perfect, but much better than nothing).
llvm-svn: 158180
2012-06-08 00:04:43 +00:00
Anna Zaks
93205d0d12
[analyze] Change some of the malloc tests to use clang_analyzer_eval.
...
Thanks, Jordan.
llvm-svn: 158179
2012-06-08 00:04:40 +00:00
Kaelyn Uhrain
1dac08da4b
Teach the FixIt in DiagnoseInvalidRedeclaration how to replace the written
...
nested name specifiers in addition to the function's identifier when the
correction has a different nested name specifier.
llvm-svn: 158178
2012-06-07 23:57:12 +00:00
Kaelyn Uhrain
389e9c2d7c
Ignore corrections to functions with bodies when deciding which
...
correction to use for an invalid function redeclaration.
llvm-svn: 158177
2012-06-07 23:57:08 +00:00
Michael J. Spencer
aeb59e1d0d
[CMake] Promote extension warnings to errors.
...
llvm-svn: 158176
2012-06-07 23:33:56 +00:00
Manman Ren
2cdc8afccf
X86: optimize generated code for integer ABS
...
This patch will generate the following for integer ABS:
movl %edi, %eax
negl %eax
cmovll %edi, %eax
INSTEAD OF
movl %edi, %ecx
sarl $31, %ecx
leal (%rdi,%rcx), %eax
xorl %ecx, %eax
There exists a target-independent DAG combine for integer ABS, which converts
integer ABS to sar+add+xor. For X86, we match this pattern back to neg+cmov.
This is implemented in PerformXorCombine.
rdar://10695237
llvm-svn: 158175
2012-06-07 22:39:10 +00:00
Douglas Gregor
cb8cf4916f
Minor comments and changes to clang-completion-mode.el, from David Wood!
...
llvm-svn: 158174
2012-06-07 22:33:29 +00:00
Sean Callanan
64c0cf2134
Added a setting (target.process.disable-memory-cache)
...
that controls whether memory is cached. This is off
by default (i.e., memory is cached) because it greatly
improves performance.
llvm-svn: 158173
2012-06-07 22:26:42 +00:00
Douglas Gregor
07db340438
Fix warning flags for CMake builds, from Andrew C. Morrow!
...
llvm-svn: 158172
2012-06-07 22:26:00 +00:00
Michael J. Spencer
08180c325f
[CMake] Order MSVC warnings numerically.
...
llvm-svn: 158171
2012-06-07 21:34:31 +00:00
Michael J. Spencer
6d45d834a7
[CMake] Adjust MSVC warnings.
...
Remove /Wall from LLVM_ENABLE_WARNINGS (it's useless) and promote 4239
to a level 1 warning.
llvm-svn: 158170
2012-06-07 21:34:15 +00:00
Nadav Rotem
bbd40f67d8
Do not optimize the used bits of the x86 vselect condition operand, when the condition operand is a vector of 1-bit predicates.
...
This may happen on MIC devices.
llvm-svn: 158168
2012-06-07 20:53:48 +00:00
Nadav Rotem
4e50efead6
Fix a bug in FoldSelectOpOp. Bitcast ops may change the number of vector elements, which may disagree with the select condition type.
...
llvm-svn: 158166
2012-06-07 20:28:57 +00:00
Anna Zaks
a7dcc996a9
[analyzer] Fixit for r158136.
...
I falsely assumed that the memory spaces are equal when we reach this
point, they might not be when memory space of one or more is stack or
Unknown. We don't want a region from Heap space alias something with
another memory space.
llvm-svn: 158165
2012-06-07 20:18:08 +00:00
Andrew Trick
a5d24ca453
Continue factoring computeOperandLatency. Use it for ARM hasHighOperandLatency.
...
llvm-svn: 158164
2012-06-07 19:42:04 +00:00
Andrew Trick
5b1cadf9f7
ARM getOperandLatency rewrite.
...
Match expectations of the new latency API. Cleanup and make the logic consistent.
llvm-svn: 158163
2012-06-07 19:42:00 +00:00
Andrew Trick
3564bdfa61
ARM getOperandLatency should return -1 for unknown, consistent with API
...
llvm-svn: 158162
2012-06-07 19:41:58 +00:00
Andrew Trick
fb1a74c2b2
Fix ARM getInstrLatency logic to work with the current API.
...
llvm-svn: 158161
2012-06-07 19:41:55 +00:00
Manman Ren
746e4859d0
PR13046: we can't replace usage of SUB with CMP in the lowering phase.
...
It will cause assertion failure later on.
llvm-svn: 158160
2012-06-07 19:27:33 +00:00
Jim Ingham
aebdf1bed2
Add API logging for SBDebugger::MemoryPressureDetected.
...
llvm-svn: 158159
2012-06-07 19:08:07 +00:00
Rafael Espindola
55d1145bd5
Use a base register instead of an index register with the local dynamic model.
...
Fixes pr13048.
llvm-svn: 158158
2012-06-07 18:39:19 +00:00
Fariborz Jahanian
5d53fcda7c
User better API for vla in compund literals.
...
// rdar://11485774
llvm-svn: 158157
2012-06-07 18:15:55 +00:00
Douglas Gregor
fed6699dd9
Add ext_vector type code for builtins, from John Garvin!
...
llvm-svn: 158156
2012-06-07 18:08:25 +00:00
Chandler Carruth
48687a5a00
Fix many doxygen formatting errors.
...
This patch affects docs only, and includes formatting changes only
(though those include some fixes for broken Doxygen markup that caused
some content to be missing from generated pages). It avoids generating
many spurious pages such as
http://clang.llvm.org/doxygen/classRepresents.html , but likely not all
yet.
Patch by James Dennett.
llvm-svn: 158155
2012-06-07 17:55:42 +00:00
Pete Cooper
cd72016cab
Move terminator machine verification to check MachineBasicBlock::instr_iterator instead of MBB::iterator
...
llvm-svn: 158154
2012-06-07 17:41:39 +00:00
Fariborz Jahanian
bbc5bbf4f1
When emitting compund literal of vla pointer elements, make
...
sure to emit vla size to prevent an irgen crash.
// rdar://11485774
llvm-svn: 158153
2012-06-07 17:07:15 +00:00
Benjamin Kramer
5d4cff72b4
Reuse APInt's getNumWords, which gets rounding right (my ad-hoc solution missed it).
...
llvm-svn: 158151
2012-06-07 15:54:03 +00:00
Benjamin Kramer
6003ad5848
Plug a long standing memory leak in TemplateArgument.
...
The integral APSInt value is now stored in a decomposed form and the backing
store for large values is allocated via the ASTContext. This way its not
leaked as TemplateArguments are never destructed when they are allocated in
the ASTContext. Since the integral data is immutable it is now shared between
instances, making copying TemplateArguments a trivial operation.
Currently getting the integral data out of a TemplateArgument requires creating
a new APSInt object. This is cheap when the value is small but can be expensive
if it's not. If this turns out to be an issue a more efficient accessor could
be added.
llvm-svn: 158150
2012-06-07 15:09:51 +00:00
NAKAMURA Takumi
29aaccda13
test/Frontend/rewrite-includes.c: Tweak for win32's pathsep.
...
llvm-svn: 158149
2012-06-07 14:21:02 +00:00
Alexey Samsonov
91e1a7eb17
[Sanitizer] move internal_strdup and internal_memcpy to common runtime. Make internal allocations from TSan runtime call InternalAlloc from common runtime
...
llvm-svn: 158148
2012-06-07 11:54:08 +00:00
Alexey Samsonov
8b9aea522f
[Sanitizer] use unsigned int as a parameter for placement new on 32 bits
...
llvm-svn: 158147
2012-06-07 10:09:41 +00:00
Benjamin Kramer
b696a3639d
Move sideeffecting call out of assert().
...
llvm-svn: 158146
2012-06-07 09:57:21 +00:00
Alexey Samsonov
8bd9098b32
[Sanitizer] move placement_new definiton from TSan to common runtime
...
llvm-svn: 158145
2012-06-07 09:50:16 +00:00
Alexey Samsonov
94e2b7d040
[Sanitizer] include stdlib.h header to get malloc/free
...
llvm-svn: 158144
2012-06-07 09:26:13 +00:00
Kostya Serebryany
0b14fd855b
[asan] slow 16-byte redzones (still experimental)
...
llvm-svn: 158143
2012-06-07 09:15:48 +00:00
Alexey Samsonov
3a6ddb86e8
[Sanitizer] Allocator for internal runtime purposes. Currently it calls libcmalloc, but we might have to make it more low-level in future
...
llvm-svn: 158142
2012-06-07 08:52:56 +00:00
Alexey Samsonov
cf4d3a027d
[Sanitizer] Fix mac build.
...
llvm-svn: 158141
2012-06-07 07:32:00 +00:00
Alexey Samsonov
4b1f1031e6
[Sanitizer] factor out GetThreadStackTopAndBottom from ASan runtime to common.
...
llvm-svn: 158140
2012-06-07 07:13:46 +00:00
Alexey Samsonov
28a9895ee0
[Sanitizer] __asan::AsanProcMaps -> __sanitizer::ProcessMaps.
...
llvm-svn: 158139
2012-06-07 06:15:12 +00:00
Alexey Samsonov
fe44fbd750
[Sanitizer] Move ReadFileToBuffer to sanitizer_common.
...
llvm-svn: 158138
2012-06-07 05:38:26 +00:00
Pete Cooper
f8d60d36c2
Add internal read flags to MachineInstrBuilder and hook them into the MachineOperand flag of the same name
...
llvm-svn: 158137
2012-06-07 04:43:52 +00:00
Anna Zaks
3563fde6a0
[analyzer] Anti-aliasing: different heap allocations do not alias
...
Add a concept of symbolic memory region belonging to heap memory space.
When comparing symbolic regions allocated on the heap, assume that they
do not alias.
Use symbolic heap region to suppress a common false positive pattern in
the malloc checker, in code that relies on malloc not returning the
memory aliased to other malloc allocations, stack.
llvm-svn: 158136
2012-06-07 03:57:32 +00:00
Nick Kledzik
5fb2e4dabe
put the public function createReaderPECOFF() in the lld namespace and everything else in is own namespace
...
llvm-svn: 158135
2012-06-07 02:23:48 +00:00
Nick Kledzik
98211f6d19
fix warnings found after cranking up warnings
...
llvm-svn: 158134
2012-06-07 01:53:39 +00:00
Nick Kledzik
40b8655082
abstract load commands to that WriterMachO can write 64-bit and 32-bit mach-o files
...
llvm-svn: 158133
2012-06-07 01:45:39 +00:00