NAKAMURA Takumi [Thu, 13 Feb 2014 11:24:45 +0000 (11:24 +0000)]
[CMake] add_clang_library(MODULE): Create a phony target when llvm_add_library(MODULE) gave up.
llvm-svn: 201319
NAKAMURA Takumi [Thu, 13 Feb 2014 11:19:21 +0000 (11:19 +0000)]
[CMake] Move the target property PREFIX from add_llvm_loadable_module() to llvm_add_library().
llvm-svn: 201318
NAKAMURA Takumi [Thu, 13 Feb 2014 11:19:11 +0000 (11:19 +0000)]
[CMake] llvm_add_library(MODULE) may use CMAKE_MODULE_LINKER_FLAGS instead of target property LINK_FLAGS.
I mis-dropped Darwin's link flags (in clang side) since r201073.
llvm-svn: 201317
NAKAMURA Takumi [Thu, 13 Feb 2014 11:19:00 +0000 (11:19 +0000)]
[CMake] LLVM_PLUGIN_EXT: Use CMAKE_SHARED_LIBRARY_SUFFIX rather than CMAKE_SHARED_MODULE_SUFFIX in llvm tree.
FIXME: llvm/test may be aware of LLVM_PLUGIN_EXT, like as clang/test does.
FIXME: CMAKE_*_SUFFIX may be set in HandleLLVMOptions if those variables could be writable, rather than to set one as target properties.
llvm-svn: 201316
NAKAMURA Takumi [Thu, 13 Feb 2014 11:06:23 +0000 (11:06 +0000)]
llvm/test/CodeGen/AArch64/cpus.ll: Tweak to use -mtriple=aarch64-unknown-unknown, or this would crash for targeting pecoff like *-mingw32.
llvm-svn: 201315
Tim Northover [Thu, 13 Feb 2014 10:44:30 +0000 (10:44 +0000)]
ARM: remove floating-point patterns for @llvm.arm.neon.vabs
The front-end is now generating the generic @llvm.fabs for this
operation now, so the extra patterns are no longer needed.
llvm-svn: 201314
Tim Northover [Thu, 13 Feb 2014 10:44:17 +0000 (10:44 +0000)]
ARM & AArch64 NEON: share the vabs implementation.
This changes ARM to use @llvm.fabs for floating-point vabs. Patterns
already existed in the backend, and it might help mid-end phases since
it's more likely to be understood than @llvm.arm.neon.vabs.
llvm-svn: 201313
Robert Lytton [Thu, 13 Feb 2014 10:40:12 +0000 (10:40 +0000)]
XCore target pass -v flag to assembler & linker
llvm-svn: 201312
Robert Lytton [Thu, 13 Feb 2014 10:38:56 +0000 (10:38 +0000)]
add comment explaining previous commit
see 'XCore target -fexceptions flag handling'
llvm-svn: 201311
Robert Lytton [Thu, 13 Feb 2014 10:34:44 +0000 (10:34 +0000)]
XCore target -fexceptions flag handling
XCore target has -fno-exception as the default option
Pass on "-fexceptions" flag to xcc (linker)
llvm-svn: 201310
Renato Golin [Thu, 13 Feb 2014 10:26:33 +0000 (10:26 +0000)]
Remove spurious default case to silent sanitizer
llvm-svn: 201309
Alexander Kornienko [Thu, 13 Feb 2014 10:11:48 +0000 (10:11 +0000)]
Fix ExplicitConstructorCheck to warn only on in-class declarations.
Summary:
I'm not absolutely sure this is 100% correct solution, but it seems to
do what I expect.
Reviewers: djasper, klimek
Reviewed By: djasper
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D2756
llvm-svn: 201308
Renato Golin [Thu, 13 Feb 2014 10:01:16 +0000 (10:01 +0000)]
Add EXPERIMENTAL --rtlib=compiler-rt to GNU Clang
This commit is not strictly correct nor accounts for all uses (shared
objects, for example), but it allows one to test the compiler-rt library
on GNU targets.
Using this patch to run the test-suite has already shown me problems
on ARM. Since this is a Darwin-only flag, nobody is using it, so it
shouldn't be a problem.
I will need extension to deal with the shared cases, but since we're
not compiling libclang_rt.so, that's not yet applicable. Many other
problems will have to be fixed first in compiler-rt (such as removing
the 'arch' name from it and making it trully multi-arch, moving it to
the default lib directory, make both .a and .so variants, etc).
llvm-svn: 201307
Kostya Serebryany [Thu, 13 Feb 2014 09:52:15 +0000 (09:52 +0000)]
[sanitizer] findPath for deadlock detector
llvm-svn: 201306
Oliver Stannard [Thu, 13 Feb 2014 09:46:11 +0000 (09:46 +0000)]
Add Cortex-A53 and Cortex-A57 cores to the AArch64 backend
llvm-svn: 201305
Evgeniy Stepanov [Thu, 13 Feb 2014 08:50:36 +0000 (08:50 +0000)]
[asan] Avoid deadlock in CovDump.
llvm-svn: 201304
Kostya Serebryany [Thu, 13 Feb 2014 07:50:20 +0000 (07:50 +0000)]
[sanitizer] AArch64 sanitizer support; patch by Christophe Lyon and Yvan Roux
llvm-svn: 201303
Kostya Serebryany [Thu, 13 Feb 2014 07:44:51 +0000 (07:44 +0000)]
[sanitizer] more code for deadlock detector, nothing really works yet (except for small unit tests).
llvm-svn: 201302
Craig Topper [Thu, 13 Feb 2014 07:12:40 +0000 (07:12 +0000)]
Remove unused method declaration.
llvm-svn: 201301
Jason Molenda [Thu, 13 Feb 2014 07:11:08 +0000 (07:11 +0000)]
The Platform base class now maintains a list of trap handlers
aka asynchronous signal handlers, which subclasses should fill
in as appropriate. For most Unix user process environments,
the one entry in this list is _sigtramp. For bare-board and
kernel environments, there will be different sets of trap
handlers.
The unwinder needs to know when a frame is a trap handler
because the rules it enforces for the frame "above" the
trap handler is different from most middle-of-the-stack frames.
<rdar://problem/
15835846>
llvm-svn: 201300
Craig Topper [Thu, 13 Feb 2014 07:07:16 +0000 (07:07 +0000)]
Remove filtering concept from X86 disassembler table generation. It's no longer necessary.
llvm-svn: 201299
Hao Liu [Thu, 13 Feb 2014 05:42:33 +0000 (05:42 +0000)]
[AArch64]Fix the problems that can't select mul/add/sub of v1i8/v1i16/v1i32 types.
As this problems are similar to shl/sra/srl, also add patterns for shift nodes.
llvm-svn: 201298
Alexey Bataev [Thu, 13 Feb 2014 05:29:23 +0000 (05:29 +0000)]
[OPENMP] 'if' clause support (no CodeGen support)
llvm-svn: 201297
Quentin Colombet [Thu, 13 Feb 2014 05:17:37 +0000 (05:17 +0000)]
[RegAlloc] Fix the assertion in the last chance recoloring to match the
condition at the call site.
llvm-svn: 201296
Rafael Espindola [Thu, 13 Feb 2014 05:11:35 +0000 (05:11 +0000)]
Copy dll storage in copyAttributes.
llvm-svn: 201295
Aaron Ballman [Thu, 13 Feb 2014 04:31:04 +0000 (04:31 +0000)]
There is no std namespace for standards-based attributes. Removing the scope qualifier and updating the only affected test case.
llvm-svn: 201294
Rafael Espindola [Thu, 13 Feb 2014 04:22:54 +0000 (04:22 +0000)]
Use simpler version of fs::create_directory.
llvm-svn: 201293
Jason Molenda [Thu, 13 Feb 2014 04:19:32 +0000 (04:19 +0000)]
Change the ABI CallFrameAddressIsValid methods for i386 and x86_64.
They were enforcing 16-byte alignment on stack frames for Darwin x86 programs.
But we've found that trap handlers typically don't have the stack pointer
aligned correctly when a trap happens and lldb wasn't backtracing all
the way through. This method is only used as a safety guard to prevent
lldb's unwinder from using a bogus address as a stack frame - we'll still
enforce word-size alignment on stack frames so that should be fine.
Also rolled back akaylor's changes from August 2013 in r188952 which changed
the i386 ABI plugin to relax the CallFrameAddressIsValid offsets for non-Darwin
targets where only 4-byte alignment is enforced. Now Darwin is the same as
those environments.
<rdar://problem/
15982682>
llvm-svn: 201292
Juergen Ributzka [Thu, 13 Feb 2014 04:19:26 +0000 (04:19 +0000)]
[DAG] Fix the recognition of opaque constants in the SelectionDAGBuilder.
This fix checks the original LLVM IR node to identify opaque constants by
looking for the bitcast-constant pattern. Originally we looked at the generated
SDNode, but this might lead to incorrect results. The SDNode could have been
generated by an constant expression that was folded to a constant.
This fixes <rdar://problem/
16050719>
llvm-svn: 201291
Rafael Espindola [Thu, 13 Feb 2014 04:08:44 +0000 (04:08 +0000)]
Use simpler version of llvm::sys::fs::create_directories.
llvm-svn: 201290
Rafael Espindola [Thu, 13 Feb 2014 04:00:35 +0000 (04:00 +0000)]
Use simpler version of sys::fs::exists when possible.
llvm-svn: 201289
Yunzhong Gao [Thu, 13 Feb 2014 02:45:10 +0000 (02:45 +0000)]
Fixing a compiler assertion with zero-width bit-fields in packed structs.
According to the GNU docs, zero-sized bitfields should not be affected by the
packed attribute.
Differential Revision: http://llvm-reviews.chandlerc.com/D2693
llvm-svn: 201288
Hao Liu [Thu, 13 Feb 2014 02:36:58 +0000 (02:36 +0000)]
[AArch64]Add support for spilling FPR8/FPR16.
llvm-svn: 201287
Reid Kleckner [Thu, 13 Feb 2014 02:18:36 +0000 (02:18 +0000)]
GlobalOpt: Aliases don't have sections, don't copy them when replacing
As defined in LangRef, aliases do not have sections. However, LLVM's
GlobalAlias class inherits from GlobalValue, which means we can read and
set its section. We should probably ban that as a separate change,
since it doesn't make much sense for an alias to have a section that
differs from its aliasee.
Fixes PR18757, where the section was being lost on the global in code
from Clang like:
extern "C" {
__attribute__((used, section("CUSTOM"))) static int in_custom_section;
}
Reviewers: rafael.espindola
Differential Revision: http://llvm-reviews.chandlerc.com/D2758
llvm-svn: 201286
Reid Kleckner [Thu, 13 Feb 2014 01:19:59 +0000 (01:19 +0000)]
Really fix unused variable warnings in CIndex.
llvm-svn: 201285
Ed Maste [Thu, 13 Feb 2014 01:10:20 +0000 (01:10 +0000)]
Remove decorator for fixed test
llvm.org/pr18805 fixed by r201270
llvm-svn: 201284
NAKAMURA Takumi [Thu, 13 Feb 2014 01:00:52 +0000 (01:00 +0000)]
[CMake] llvm_add_library: Add handling of the parameter ADDITIONAL_HEADERS to pass through to process_source.
I was insightless then about unknown optional parameters.
(Consider that LINK_LIBS foo bar ADDITIONAL_HEADERS qux quux)
Suggested by Michael Kruse. Thanks!
llvm-svn: 201283
John McCall [Thu, 13 Feb 2014 00:50:08 +0000 (00:50 +0000)]
ms_struct layout replaces platform-specific behavior like
useBitFieldTypeAlignment() and appears to ignore the special
bit-packing semantics of __attribute__((packed)).
Further flesh out an already-extensive comment.
llvm-svn: 201282
John McCall [Thu, 13 Feb 2014 00:50:02 +0000 (00:50 +0000)]
Change testcase to use FileCheck.
llvm-svn: 201281
Reid Kleckner [Thu, 13 Feb 2014 00:44:34 +0000 (00:44 +0000)]
Fix uninitialized read in vtordisp pragma code.
llvm-svn: 201280
Lang Hames [Thu, 13 Feb 2014 00:31:14 +0000 (00:31 +0000)]
Fix misleading comment.
llvm-svn: 201279
Reid Kleckner [Thu, 13 Feb 2014 00:22:04 +0000 (00:22 +0000)]
Fix some -Wdocumentation warnings in Sema.h and try to fix test for win64
llvm-svn: 201278
Lang Hames [Thu, 13 Feb 2014 00:16:36 +0000 (00:16 +0000)]
The new MCJIT C-API unit test is generating objects without constant data
sections, at least on MachO. Relax expectations to keep the bots green while I
investigate.
llvm-svn: 201277
Reid Kleckner [Wed, 12 Feb 2014 23:56:20 +0000 (23:56 +0000)]
Silence unused variable warning in CIndex.cpp with NDEBUG
llvm-svn: 201276
Owen Anderson [Wed, 12 Feb 2014 23:54:07 +0000 (23:54 +0000)]
Remove a very old instcombine where we would turn sequences of selects into
logical operations on the i1's driving them. This is a bad idea for every
target I can think of (confirmed with micro tests on all of: x86-64, ARM,
AArch64, Mips, and PowerPC) because it forces the i1 to be materialized into
a general purpose register, whereas consuming it directly into a select generally
allows it to exist only transiently in a predicate or flags register.
Chandler ran a set of performance tests with this change, and reported no
measurable change on x86-64.
llvm-svn: 201275
Reid Kleckner [Wed, 12 Feb 2014 23:50:26 +0000 (23:50 +0000)]
MS ABI: Implement #pragma vtordisp() and clang-cl /vdN
These features are new in VS 2013 and are necessary in order to layout
std::ostream correctly. Currently we have an ABI incompatibility when
self-hosting with the 2013 stdlib in our convertible_fwd_ostream wrapper
in gtest.
This change adds another implicit attribute, MSVtorDispAttr, because
implicit attributes are currently the best way to make sure the
information stays on class templates through instantiation.
Reviewers: majnemer
Differential Revision: http://llvm-reviews.chandlerc.com/D2746
llvm-svn: 201274
Greg Clayton [Wed, 12 Feb 2014 23:46:08 +0000 (23:46 +0000)]
Fixed the TestLogging test.
llvm-svn: 201273
Andrea Di Biagio [Wed, 12 Feb 2014 23:43:47 +0000 (23:43 +0000)]
[Vectorizer] Add a new 'OperandValueKind' in TargetTransformInfo called
'OK_NonUniformConstValue' to identify operands which are constants but
not constant splats.
The cost model now allows returning 'OK_NonUniformConstValue'
for non splat operands that are instances of ConstantVector or
ConstantDataVector.
With this change, targets are now able to compute different costs
for instructions with non-uniform constant operands.
For example, On X86 the cost of a vector shift may vary depending on whether
the second operand is a uniform or non-uniform constant.
This patch applies the following changes:
- The cost model computation now takes into account non-uniform constants;
- The cost of vector shift instructions has been improved in
X86TargetTransformInfo analysis pass;
- BBVectorize, SLPVectorizer and LoopVectorize now know how to distinguish
between non-uniform and uniform constant operands.
Added a new test to verify that the output of opt
'-cost-model -analyze' is valid in the following configurations: SSE2,
SSE4.1, AVX, AVX2.
llvm-svn: 201272
Andrea Di Biagio [Wed, 12 Feb 2014 23:42:28 +0000 (23:42 +0000)]
[X86] Teach the backend how to lower vector shift left into multiply rather than scalarizing it.
Instead of expanding a packed shift into a sequence of scalar shifts,
the backend now tries (when possible) to convert the vector shift into a
vector multiply.
Before this change, a shift of a MVT::v8i16 vector by a
build_vector of constants was always scalarized into a long sequence of "vector
extracts + scalar shifts + vector insert".
With this change, if there is SSE2 support, we emit a single vector multiply.
This change also affects SSE4.1, AVX, AVX2 shifts:
- A shift of a MVT::v4i32 vector by a build_vector of non uniform constants
is now lowered when possible into a single SSE4.1 vector multiply.
- Packed v16i16 shift left by constant build_vector are now expanded when
possible into a single AVX2 vpmullw.
This change also improves the lowering of AVX512f vector shifts.
Added test CodeGen/X86/vec_shift6.ll with some code examples that are affected
by this change.
llvm-svn: 201271
Greg Clayton [Wed, 12 Feb 2014 23:40:31 +0000 (23:40 +0000)]
Fixed the functionalities/abbreviation/TestAbbreviations.py test case.
llvm-svn: 201270
Hans Wennborg [Wed, 12 Feb 2014 23:26:29 +0000 (23:26 +0000)]
VS Integration: install toolsets for x64 too (PR18738)
This does exactly the same thing as for Win32, except it passes -m64 to
the compiler and the files go in a different directory.
Differential Revision: http://llvm-reviews.chandlerc.com/D2749
llvm-svn: 201269
Greg Clayton [Wed, 12 Feb 2014 23:16:19 +0000 (23:16 +0000)]
Add support for DW_OP_piece and DW_OP_bit_piece.
llvm-svn: 201268
David Blaikie [Wed, 12 Feb 2014 23:03:54 +0000 (23:03 +0000)]
DebugInfo: Demonstrate that we're not currently uniquing address table entries in fission
Since I just discovered this while poking at other things, here's the
test case so I have it to come back to later.
llvm-svn: 201267
David Blaikie [Wed, 12 Feb 2014 23:03:51 +0000 (23:03 +0000)]
DebugInfo: Merge fission and non-fission (and 32 and 64 bit) tests for TLS support.
llvm-svn: 201266
Eric Christopher [Wed, 12 Feb 2014 22:47:09 +0000 (22:47 +0000)]
Reformat a few lines with clang-format.
llvm-svn: 201265
Eric Christopher [Wed, 12 Feb 2014 22:38:04 +0000 (22:38 +0000)]
80-col.
llvm-svn: 201264
Juergen Ributzka [Wed, 12 Feb 2014 22:17:13 +0000 (22:17 +0000)]
[Stackmaps] Improve the stackmap lowering code in the SelectionDAGBuilder.
We are now no longer relying on the target-specific call lowering implementation
to lower a stackmap intrinsic call. Instead we perform the call lowering in a
target-independent way directly in the stackmap lowering code. This simplifies
the code and removes the need to fixup the code after the target-specific call
lowering.
llvm-svn: 201263
Juergen Ributzka [Wed, 12 Feb 2014 22:17:10 +0000 (22:17 +0000)]
[Stackmaps] Fix the ID type to be i64 also for stackmaps (as we claim in the documenation)
The ID type for the stackmap and patchpoint intrinsics are in both cases i64.
This fixes an zero extend in the SelectionDAGBuilder that still used i32. This
also updates the target independent instructions STACKMAP and PATCHPOINT to use
the correct type.
llvm-svn: 201262
Rafael Espindola [Wed, 12 Feb 2014 21:47:15 +0000 (21:47 +0000)]
Don't try to build ExceptionDemo on ARM.
The demo uses _Unwind_GetIP which is not available on that platform.
llvm-svn: 201261
Hans Wennborg [Wed, 12 Feb 2014 21:40:46 +0000 (21:40 +0000)]
Remove FIXME and hardcoded triple from this test (PR18251)
We don't support using the MS ABI with non-x86/x86_64 targets anyway.
llvm-svn: 201260
Lang Hames [Wed, 12 Feb 2014 21:30:07 +0000 (21:30 +0000)]
Extend RTDyld API to enable optionally precomputing the total amount of memory
required for all sections in a module. This can be useful when targets or
code-models place strict requirements on how sections must be laid out
in memory.
If RTDyldMemoryManger::needsToReserveAllocationSpace() is overridden to return
true then the JIT will call the following method on the memory manager, which
can be used to preallocate the necessary memory.
void RTDyldMemoryManager::reserveAllocationSpace(uintptr_t CodeSize,
uintptr_t DataSizeRO,
uintptr_t DataSizeRW)
Patch by Vaidas Gasiunas. Thanks very much Viadas!
llvm-svn: 201259
Reid Kleckner [Wed, 12 Feb 2014 21:26:20 +0000 (21:26 +0000)]
Rename Windows.h to WindowsSupport.h to avoid ambiguity
llvm-svn: 201258
Benjamin Kramer [Wed, 12 Feb 2014 21:25:40 +0000 (21:25 +0000)]
Remove unused diagnostic.
llvm-svn: 201257
Jordan Rose [Wed, 12 Feb 2014 21:04:23 +0000 (21:04 +0000)]
[examples] Use loadable modules instead of shared libraries for Clang plugins.
This avoids linking in extra copies of, say, LLVMSupport.
llvm-svn: 201256
David Fang [Wed, 12 Feb 2014 21:02:12 +0000 (21:02 +0000)]
_CS_DARWIN_USER macros available on darwin>=9. Thanks, Dave Odell!
llvm-svn: 201255
David Majnemer [Wed, 12 Feb 2014 20:36:10 +0000 (20:36 +0000)]
Sema: Restrict alignment to 2**28.
Allowing alignment past this point causes wrap around within clang.
N.B. GCC has the same restriction.
llvm-svn: 201254
Adrian Prantl [Wed, 12 Feb 2014 19:34:44 +0000 (19:34 +0000)]
Debug info: Bugfix for r201190: DW_OP_piece takes bytes, not bits.
rdar://problem/
16015314
llvm-svn: 201253
Sergey Matveev [Wed, 12 Feb 2014 19:29:49 +0000 (19:29 +0000)]
[sanitizer] Intercept capget()/capset().
Also, fix incorrect syscall hooks for the corresponding syscalls.
llvm-svn: 201252
Reid Kleckner [Wed, 12 Feb 2014 19:26:24 +0000 (19:26 +0000)]
Attributes: Avoid a big useless copy in the emitter
llvm-svn: 201251
Adrian Prantl [Wed, 12 Feb 2014 19:26:19 +0000 (19:26 +0000)]
relax testcase and make ppc64 buildbots happy.
llvm-svn: 201250
Dmitri Gribenko [Wed, 12 Feb 2014 19:12:37 +0000 (19:12 +0000)]
libclang: report error code for bad PCH files
This commit improves libclang to report the error condition when
CXTranslationUnit can not be created because of a stale PCH file. This allows
the caller, for example, to rebuild the PCH file and retry the request.
There two are APIs in libclang that return a CXTranslationUnit and don't
support reporting detailed errors (the only error condition is a NULL result).
For these APIs, a second, superior, version is introduced --
clang_createTranslationUnit2 and clang_parseTranslationUnit2. These functions
return a CXTranslationUnit indirectly and also return an error code. Old
functions are still supported and are nothing more than convenience wrappers
that ignore extended error codes.
As a cleanup, this commit also categorizes some libclang errors in the
functions I had to modify anyway.
llvm-svn: 201249
Adrian Prantl [Wed, 12 Feb 2014 18:24:07 +0000 (18:24 +0000)]
Document and improve the debug-property-synth.m test based on the
information provided in the referenced radar.
llvm-svn: 201248
Adrian Prantl [Wed, 12 Feb 2014 18:24:04 +0000 (18:24 +0000)]
Revert "Remove bad debug info test."
This reverts commit r201183.
The test, albeit undocumented and badly written is still testing something
useful. It will be updated in a subsequent commit.
llvm-svn: 201247
Reid Kleckner [Wed, 12 Feb 2014 18:22:18 +0000 (18:22 +0000)]
Attributes: Emit enumerators in td file declaration order
llvm-svn: 201246
Akira Hatanaka [Wed, 12 Feb 2014 18:09:18 +0000 (18:09 +0000)]
Pass edges weights to MachineBasicBlock::addSuccessor in TailDuplicatePass to
preserve branch probability information.
<rdar://problem/
15893208>
llvm-svn: 201245
Todd Fiala [Wed, 12 Feb 2014 17:50:26 +0000 (17:50 +0000)]
Change TestAbbreviations test to expected failure on Linux.
See http://llvm.org/bugs/show_bug.cgi?id=18816.
Likely the same issue as http://llvm.org/bugs/show_bug.cgi?id=18805.
llvm-svn: 201244
Renato Golin [Wed, 12 Feb 2014 17:17:41 +0000 (17:17 +0000)]
PC-rel implemented in AArch64, test now pass
llvm-svn: 201243
Eli Bendersky [Wed, 12 Feb 2014 16:48:02 +0000 (16:48 +0000)]
Move more self-contained functionality away from tools/opt/opt.cpp
BreakpointPrinter moves to its own module.
llvm-svn: 201242
Daniel Sanders [Wed, 12 Feb 2014 15:39:20 +0000 (15:39 +0000)]
Revert r201237+r201238: Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTextSupport() call
It introduced multiple test failures in the buildbots.
llvm-svn: 201241
Evgeniy Stepanov [Wed, 12 Feb 2014 15:29:22 +0000 (15:29 +0000)]
[asan] Handle OpenFile errors in CovDump.
llvm-svn: 201240
Tom Stellard [Wed, 12 Feb 2014 14:54:17 +0000 (14:54 +0000)]
Revert "Enforce python2 for systems that use python3 as their default."
This reverts commit r200413.
This was breaking the build on systems where the python 2.x executable
was called python.
llvm-svn: 201239
Daniel Sanders [Wed, 12 Feb 2014 14:46:15 +0000 (14:46 +0000)]
Arcanist failed to commit the two clang test corrections that should have been in r201237.
llvm-svn: 201238
Daniel Sanders [Wed, 12 Feb 2014 14:44:54 +0000 (14:44 +0000)]
Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTextSupport() call
Summary:
AsmPrinter::EmitInlineAsm() will no longer use the EmitRawText() call for targets with mature MC support. Such targets will always parse the inline assembly (even when emitting assembly). Targets without mature MC support continue to use EmitRawText() for assembly output.
The hasRawTextSupport() check in AsmPrinter::EmitInlineAsm() has been replaced with MCAsmInfo::UseIntegratedAs which when true, causes the integrated assembler to parse inline assembly (even when emitting assembly output). UseIntegratedAs is set to true for targets that consider any failure to parse valid assembly to be a bug. Target specific subclasses generally enable the integrated assembler in their constructor. The default value can be overridden with -no-integrated-as.
All tests that rely on inline assembly supporting invalid assembly (for example, those that use mnemonics such as 'foo' or 'hello world') have been updated to disable the integrated assembler.
Reviewers: rafael
Reviewed By: rafael
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D2686
llvm-svn: 201237
Dmitri Gribenko [Wed, 12 Feb 2014 14:17:58 +0000 (14:17 +0000)]
libclang: fix a crash in clang_disposeDiagnosticSet when it is passed a NULL argument
llvm-svn: 201236
Evgeniy Stepanov [Wed, 12 Feb 2014 13:05:17 +0000 (13:05 +0000)]
[sanitizer] Fix wait4 interceptor on Android.
It's called __wait4 there.
llvm-svn: 201235
Tim Northover [Wed, 12 Feb 2014 12:56:48 +0000 (12:56 +0000)]
Whitespace cleanup (mostly stray tabs, a few not-quite-empty lines).
llvm-svn: 201234
Tim Northover [Wed, 12 Feb 2014 12:08:06 +0000 (12:08 +0000)]
ARM & NEON: add test for r101232
rdar://problem/
16035743
llvm-svn: 201233
Tim Northover [Wed, 12 Feb 2014 12:04:59 +0000 (12:04 +0000)]
ARM NEON: fix range checking on immediates.
Previously, range checking on the __builtin_neon_XYZ_v Clang intrinsics didn't
take account of the type actually passed to the call, which meant a request
like "vext_s16(a, b, 7)" was allowed through (TableGen was conservative and
allowed 0-7 for all types). This caused an assert in the backend because the
lane doesn't make sense.
llvm-svn: 201232
Dmitri Gribenko [Wed, 12 Feb 2014 11:50:37 +0000 (11:50 +0000)]
Don't use find | xargs in test/Modules/fmodules-validate-once-per-build-session.c
With -fdisable-module-hash, we can implement this with a simple 'cp'.
llvm-svn: 201231
NAKAMURA Takumi [Wed, 12 Feb 2014 11:50:22 +0000 (11:50 +0000)]
Windows/Path.inc: Move <shlobj.h> after "Windows.h" for some API available.
I found that swapping the order of some header files helped fix a
build issue that we're seeing on mingw32. Without the swap, windows.h
was being included before _WIN32_WINNT was being defined and the
CreateHardLinkW function was #ifdef'd out.
It looks like the header is mainly used to get the SHGetFolderPathW
function, so I don't think that there'll be much fallout from the
switch.
Suggested by Alex Crichton. Thanks!
llvm-svn: 201230
NAKAMURA Takumi [Wed, 12 Feb 2014 11:50:11 +0000 (11:50 +0000)]
Teach tablegen() macro to check needed variables
This macro depends on several variables to be set in the calling
context. Check them and report an error if they are not set.
Without this, custom commands may be silently specified that
will fail at build time.
Patch by Brad King.
llvm-svn: 201229
NAKAMURA Takumi [Wed, 12 Feb 2014 11:42:12 +0000 (11:42 +0000)]
clang/test/Modules/fmodules-validate-once-per-build-session.c: Tweak for gnuwin32 with %/t (instead of %t).
xargs didn't handle dosish paths, while find foo\bar\ emits dosish paths.
llvm-svn: 201228
NAKAMURA Takumi [Wed, 12 Feb 2014 11:42:02 +0000 (11:42 +0000)]
clang/lib/Driver/Multilib.cpp: Rewrite normalizePathSegment() to be tolerant dosish pathsep.
FIXME: It could be more simple...
llvm-svn: 201227
Kostya Serebryany [Wed, 12 Feb 2014 11:28:09 +0000 (11:28 +0000)]
[sanitizer] added class BVGraph, to be used in a deadlock detector; added more methods to the bit vectors
llvm-svn: 201226
Dmitri Gribenko [Wed, 12 Feb 2014 10:40:07 +0000 (10:40 +0000)]
'svn add' files I forgot for r201224 (Add an option to allow Clang verify
source files for a module only once during)
llvm-svn: 201225
Dmitri Gribenko [Wed, 12 Feb 2014 10:33:14 +0000 (10:33 +0000)]
Add an option to allow Clang verify source files for a module only once during
the build
When Clang loads the module, it verifies the user source files that the module
was built from. If any file was changed, the module is rebuilt. There are two
problems with this:
1. correctness: we don't verify system files (there are too many of them, and
stat'ing all of them would take a lot of time);
2. performance: the same module file is verified again and again during a
single build.
This change allows the build system to optimize source file verification. The
idea is based on the fact that while the project is being built, the source
files don't change. This allows us to verify the module only once during a
single build session. The build system passes a flag,
-fbuild-session-timestamp=, to inform Clang of the time when the build started.
The build system also requests to enable this feature by passing
-fmodules-validate-once-per-build-session. If these flags are not passed, the
behavior is not changed. When Clang verifies the module the first time, it
writes out a timestamp file. Then, when Clang loads the module the second
time, it finds a timestamp file, so it can compare the verification timestamp
of the module with the time when the build started. If the verification
timestamp is too old, the module is verified again, and the timestamp file is
updated.
llvm-svn: 201224
Amara Emerson [Wed, 12 Feb 2014 10:22:35 +0000 (10:22 +0000)]
[ARM] Fix NEON wrongly being enabled with soft-float when targeting armv8/Cortex-A53/A57.
This was caused by r200708 which enabled the crypto feature for these cores.
llvm-svn: 201223
Benjamin Kramer [Wed, 12 Feb 2014 10:17:54 +0000 (10:17 +0000)]
R600: Always implement both versions of isTruncateFree and add a sanity check.
llvm-svn: 201222
Alexander Kornienko [Wed, 12 Feb 2014 09:52:07 +0000 (09:52 +0000)]
Consume checker names from clang static analyzer.
Summary: This patch depends on patches D2556 and D2557.
Reviewers: klimek
Reviewed By: klimek
CC: cfe-commits, jordan_rose, krememek
Differential Revision: http://llvm-reviews.chandlerc.com/D2620
llvm-svn: 201221
Daniel Jasper [Wed, 12 Feb 2014 08:45:05 +0000 (08:45 +0000)]
Fix memory leak introduced by r201010.
llvm-svn: 201220