Jason Molenda [Thu, 25 Oct 2012 00:25:13 +0000 (00:25 +0000)]
Identify a kdp session that is connecting to an EFI monitor,
use a DynamicLoaderStatic dynamic loader for the session
instead of a kernel or user dynamic loader.
llvm-svn: 166652
Eli Friedman [Thu, 25 Oct 2012 00:12:49 +0000 (00:12 +0000)]
When we're devirtualizing a method call, make sure the method has the correct IR type.
Reported in the thread "devirtualisation appears to crash clang on covariant functions on ARM" on cfe-dev.
llvm-svn: 166651
Douglas Gregor [Thu, 25 Oct 2012 00:09:28 +0000 (00:09 +0000)]
ASTUnit doesn't actually care about the predefines; don't record them.
llvm-svn: 166650
Nadav Rotem [Thu, 25 Oct 2012 00:08:41 +0000 (00:08 +0000)]
Add support for additional reduction variables: AND, OR, XOR.
Patch by Paul Redmond <paul.redmond@intel.com>.
llvm-svn: 166649
Douglas Gregor [Thu, 25 Oct 2012 00:07:54 +0000 (00:07 +0000)]
The the preprocessor option validator to compute suggested
predefines. We're not quite ready to cut over to these suggested
predefines yet, however.
llvm-svn: 166648
Bill Wendling [Thu, 25 Oct 2012 00:05:55 +0000 (00:05 +0000)]
Add some support for diagnosing possibly mismatched constraint, type size and
modifiers. (From an idea by Eric...)
<rdar://problem/
12284092>
llvm-svn: 166647
Jakob Stoklund Olesen [Thu, 25 Oct 2012 00:05:39 +0000 (00:05 +0000)]
Stop running the machine code verifier unconditionally.
llvm-svn: 166646
Richard Smith [Thu, 25 Oct 2012 00:00:53 +0000 (00:00 +0000)]
'constexpr' and 'friend' are both declaration specifiers. Teach the parser this, for better error recovery.
llvm-svn: 166645
Richard Smith [Wed, 24 Oct 2012 23:51:56 +0000 (23:51 +0000)]
PR14171: Don't crash if we hit one of the paths where GetFullTypeForDeclarator
rebuilds a function type, and that function type has parens around its name.
llvm-svn: 166644
Nadav Rotem [Wed, 24 Oct 2012 23:48:57 +0000 (23:48 +0000)]
revert accidental change
llvm-svn: 166643
Nadav Rotem [Wed, 24 Oct 2012 23:47:38 +0000 (23:47 +0000)]
Implement a basic cost model for vector and scalar instructions.
llvm-svn: 166642
Douglas Gregor [Wed, 24 Oct 2012 23:41:50 +0000 (23:41 +0000)]
Teach the PCH validator to check the preprocessor options, especially
the macros that are #define'd or #undef'd on the command line. This
checking happens much earlier than the current macro-definition
checking and is far cleaner, because it does a direct comparison
rather than a diff of the predefines buffers. Moreover, it allows us
to use the result of this check to skip over PCH files within a
directory that have non-matching -D's or -U's on the command
line. Finally, it improves the diagnostics a bit for mismatches,
fixing <rdar://problem/8612222>.
The old predefines-buffer diff'ing will go away in a subsequent commit.
llvm-svn: 166641
Chad Rosier [Wed, 24 Oct 2012 23:34:38 +0000 (23:34 +0000)]
Tell llvm-mc we're using intel syntax, so we don't have to use directives.
llvm-svn: 166640
Kevin Enderby [Wed, 24 Oct 2012 23:30:22 +0000 (23:30 +0000)]
Add a bit of documentation on the annotated disassembly output.
llvm-svn: 166639
Chad Rosier [Wed, 24 Oct 2012 23:10:28 +0000 (23:10 +0000)]
[ms-inline asm] Add back-end test case for r166632. Make sure we emit the
correct .s output as well as get the correct encoding by the integrated
assembler.
llvm-svn: 166638
Bob Wilson [Wed, 24 Oct 2012 22:56:32 +0000 (22:56 +0000)]
Don't try to install c-index-test with BUILD_CLANG_ONLY. rdar://
12492703
llvm-svn: 166637
NAKAMURA Takumi [Wed, 24 Oct 2012 22:52:04 +0000 (22:52 +0000)]
c-index-test.c: Split a format string. [-Woverlength-strings]
FIXME: They are still long strings without formatter in printf(3)!
llvm-svn: 166636
Sean Callanan [Wed, 24 Oct 2012 22:45:39 +0000 (22:45 +0000)]
Added --framework and --executable arguments
to dotest.py so that the testsuite can run against
any LLDB.
<rdar://problem/
12512268>
llvm-svn: 166635
Micah Villmow [Wed, 24 Oct 2012 22:32:26 +0000 (22:32 +0000)]
Fix a compiler warning with an unused variable.
llvm-svn: 166634
Chad Rosier [Wed, 24 Oct 2012 22:22:12 +0000 (22:22 +0000)]
[ms-inline asm] Test case for r166632.
llvm-svn: 166633
Chad Rosier [Wed, 24 Oct 2012 22:21:50 +0000 (22:21 +0000)]
[ms-inline asm] Add support for parsing the '.' operator. Given,
[register].field
The operator returns the value at the location pointed to by register plus the
offset of field within its structure or union. This patch only handles
immediate fields (i.e., [eax].4). The original displacement has to be a
MCConstantExpr as well.
Part of rdar://
12470415 and rdar://
12470514
llvm-svn: 166632
Enrico Granata [Wed, 24 Oct 2012 22:15:04 +0000 (22:15 +0000)]
Fixing the test case for rdar://
12481949 to do the right thing with our new rules for sign-extension in GetValueAsUnsigned()
llvm-svn: 166631
Chad Rosier [Wed, 24 Oct 2012 22:13:37 +0000 (22:13 +0000)]
Tidy up. No functional change intended.
llvm-svn: 166630
Joerg Sonnenberger [Wed, 24 Oct 2012 22:03:59 +0000 (22:03 +0000)]
Don't use stack unwinding to provide the location information for
SetTheory, but pass down the location explicitly.
llvm-svn: 166629
Enrico Granata [Wed, 24 Oct 2012 21:54:04 +0000 (21:54 +0000)]
And one more logging message goes away
llvm-svn: 166628
Enrico Granata [Wed, 24 Oct 2012 21:44:48 +0000 (21:44 +0000)]
Reverting unwanted changes to the test suite
llvm-svn: 166627
Enrico Granata [Wed, 24 Oct 2012 21:42:49 +0000 (21:42 +0000)]
Reverting the changes to Scalar since this class needs to follow C rules for type promotion
llvm-svn: 166626
David Blaikie [Wed, 24 Oct 2012 21:29:06 +0000 (21:29 +0000)]
Fix false positive in -Wunused-variable when a ctor call make involve cleanups.
llvm-svn: 166625
Hal Finkel [Wed, 24 Oct 2012 21:22:30 +0000 (21:22 +0000)]
Update GVN to support vectors of pointers.
GVN will now generate ptrtoint instructions for vectors of pointers.
Fixes PR14166.
llvm-svn: 166624
Nadav Rotem [Wed, 24 Oct 2012 20:59:17 +0000 (20:59 +0000)]
Make LegalizeKind public so that we can use it outside of TargetLowering.
llvm-svn: 166623
Nadav Rotem [Wed, 24 Oct 2012 20:58:40 +0000 (20:58 +0000)]
whitespace
llvm-svn: 166622
Nadav Rotem [Wed, 24 Oct 2012 20:47:55 +0000 (20:47 +0000)]
Document the -force-vector-width flag.
llvm-svn: 166621
Nadav Rotem [Wed, 24 Oct 2012 20:36:32 +0000 (20:36 +0000)]
LoopVectorizer: Add a basic cost model which uses the VTTI interface.
llvm-svn: 166620
Eli Friedman [Wed, 24 Oct 2012 20:28:18 +0000 (20:28 +0000)]
Update regression tests for r166617.
llvm-svn: 166619
Enrico Granata [Wed, 24 Oct 2012 20:24:39 +0000 (20:24 +0000)]
Reimplementing SBValue/ValueObject.GetValueAsUnsigned() in terms of appropriate calls in Scalar - Making sure Scalar does the right thing when casting signed values to unsigned ones.
llvm-svn: 166618
Eli Friedman [Wed, 24 Oct 2012 20:21:25 +0000 (20:21 +0000)]
Don't print scope qualifiers for references to a type defined locally in a function. Patch by Grzegorz Jablonski.
llvm-svn: 166617
Eli Friedman [Wed, 24 Oct 2012 20:14:09 +0000 (20:14 +0000)]
Add an additional test for namespaces and -Wmissing-variable-declarations. Move C++ test into SemaCXX.
llvm-svn: 166616
Douglas Gregor [Wed, 24 Oct 2012 20:05:57 +0000 (20:05 +0000)]
(De-)serialize the preprocessor options, including macros defined,
-include'd files, etc.
llvm-svn: 166614
Evan Cheng [Wed, 24 Oct 2012 19:53:01 +0000 (19:53 +0000)]
Fix a miscompilation caused by a typo. When turning a adde with negative value
into a sbc with a positive number, the immediate should be complemented, not
negated. Also added a missing pattern for ARM codegen.
rdar://
12559385
llvm-svn: 166613
Hal Finkel [Wed, 24 Oct 2012 19:46:44 +0000 (19:46 +0000)]
getSmallConstantTripMultiple should never return zero.
When the trip count is -1, getSmallConstantTripMultiple could return zero,
and this would cause runtime loop unrolling to assert. Instead of returning
zero, one is now returned (consistent with the existing overflow cases).
Fixes PR14167.
llvm-svn: 166612
Kaelyn Uhrain [Wed, 24 Oct 2012 19:17:42 +0000 (19:17 +0000)]
Make ~Operator() protected so subclasses can inherit it and not have
a bunch of errors for all the Operator subclasses such as:
include/llvm/Operator.h:76:7: error: deleted function 'virtual llvm::OverflowingBinaryOperator::~OverflowingBinaryOperator()'
include/llvm/Operator.h:43:3: error: overriding non-deleted function 'virtual llvm::Operator::~Operator()'
include/llvm/Operator.h:76:7: error: 'virtual llvm::OverflowingBinaryOperator::~OverflowingBinaryOperator()' is implicitly deleted because the default definition would be ill-formed:
include/llvm/Operator.h:43:3: error: 'virtual llvm::Operator::~Operator()' is private
include/llvm/Operator.h:76:7: error: within this context
llvm-svn: 166611
Enrico Granata [Wed, 24 Oct 2012 19:05:32 +0000 (19:05 +0000)]
Changing the NSDate data formatter to use GetData().uint64[] instead of relying on SBValue.GetValueAsUnsigned() to reinterpret a double as a uint64_t
llvm-svn: 166610
Pete Cooper [Wed, 24 Oct 2012 18:50:44 +0000 (18:50 +0000)]
Improve DenseMap checks for power of 2 growth. Thanks for the tip Jakob
llvm-svn: 166609
Greg Clayton [Wed, 24 Oct 2012 18:39:14 +0000 (18:39 +0000)]
Added process and thread logging the python OperatingSystem plug-in.
llvm-svn: 166608
Micah Villmow [Wed, 24 Oct 2012 18:36:13 +0000 (18:36 +0000)]
Add some cleanup to the DataLayout changes requested by Chandler.
llvm-svn: 166607
Rafael Espindola [Wed, 24 Oct 2012 18:34:26 +0000 (18:34 +0000)]
Add a test showing that nodebug is accepted in methods too. Patch by
Paul Robinson.
llvm-svn: 166606
Argyrios Kyrtzidis [Wed, 24 Oct 2012 18:29:15 +0000 (18:29 +0000)]
[libclang] Add "-index-file-full" option that recursively indexes any imported
modules/PCH files.
llvm-svn: 166605
Greg Clayton [Wed, 24 Oct 2012 18:24:14 +0000 (18:24 +0000)]
Patch from Ashok Thirumurthi that enabled FPU registers for POSIX x86_64.
llvm-svn: 166604
Enrico Granata [Wed, 24 Oct 2012 18:14:21 +0000 (18:14 +0000)]
<rdar://problem/
12481949> Fixing SBValue.GetValueAsSigned() to do the right thing when dealing with a 32-bit negative value
llvm-svn: 166603
Nadav Rotem [Wed, 24 Oct 2012 17:55:53 +0000 (17:55 +0000)]
Opt does not need to initialize the Asm printer/parser
llvm-svn: 166602
Douglas Gregor [Wed, 24 Oct 2012 17:49:01 +0000 (17:49 +0000)]
Explicitly specify C++98 when building the C++ precompiled header for this test, so that the test will work on Windows.
llvm-svn: 166601
Chad Rosier [Wed, 24 Oct 2012 17:48:01 +0000 (17:48 +0000)]
[ms-inline asm] Add test cases for r166451.
llvm-svn: 166600
Douglas Gregor [Wed, 24 Oct 2012 17:46:57 +0000 (17:46 +0000)]
Teach the preprocessor to hold onto the preprocessor options.
llvm-svn: 166599
Greg Clayton [Wed, 24 Oct 2012 17:37:53 +0000 (17:37 +0000)]
Cleanup some variable names to indicate auto pointers and also manager the llvm::Module memory more correctly.
llvm-svn: 166598
Micah Villmow [Wed, 24 Oct 2012 17:27:47 +0000 (17:27 +0000)]
Delete the empty directory that was accidently added in 166578.
llvm-svn: 166597
Micah Villmow [Wed, 24 Oct 2012 17:25:11 +0000 (17:25 +0000)]
Back out r166591, not sure why this made it through since I cancelled the command. Bleh, sorry about this!
llvm-svn: 166596
Nadav Rotem [Wed, 24 Oct 2012 17:23:50 +0000 (17:23 +0000)]
Opt needs to initialize the different targets.
llvm-svn: 166595
Chad Rosier [Wed, 24 Oct 2012 17:23:06 +0000 (17:23 +0000)]
[ms-inline asm] Add test cases for r166592. The test cases only works if the
source operand is a register.
llvm-svn: 166594
Nadav Rotem [Wed, 24 Oct 2012 17:22:41 +0000 (17:22 +0000)]
Implement a basic VectorTargetTransformInfo interface to be used by the loop and bb vectorizers for modeling the cost of instructions.
llvm-svn: 166593
Chad Rosier [Wed, 24 Oct 2012 17:22:29 +0000 (17:22 +0000)]
[ms-inline asm] Create a register operand, rather than a memory operand when we
see the offsetof operator. Previously, we were matching something like MOVrm
in the front-end and later matching MOVrr in the back-end. This change makes
things more consistent. It also fixes cases where we can't match against a
memory operand as the source (test cases coming).
Part of rdar://
12470317
llvm-svn: 166592
Micah Villmow [Wed, 24 Oct 2012 17:20:04 +0000 (17:20 +0000)]
Delete a directory that wasn't supposed to be checked in yet.
llvm-svn: 166591
Douglas Gregor [Wed, 24 Oct 2012 17:01:35 +0000 (17:01 +0000)]
Move PreprocessorOptions into the Lex library, and make it intrusively
reference-counted.
llvm-svn: 166587
Douglas Gregor [Wed, 24 Oct 2012 16:50:34 +0000 (16:50 +0000)]
(De-)serialize header search options.
llvm-svn: 166586
Douglas Gregor [Wed, 24 Oct 2012 16:24:38 +0000 (16:24 +0000)]
Update unit tests for HeaderSearch change
llvm-svn: 166584
Douglas Gregor [Wed, 24 Oct 2012 16:19:39 +0000 (16:19 +0000)]
Move HeaderSearchOptions into the Lex library, make it intrusively
reference-counted, and hold a reference to it in HeaderSearch.
llvm-svn: 166583
Douglas Gregor [Wed, 24 Oct 2012 15:53:39 +0000 (15:53 +0000)]
Undef SEMANTIC_VALUE_DIAGOPT appropriately
llvm-svn: 166579
Micah Villmow [Wed, 24 Oct 2012 15:52:52 +0000 (15:52 +0000)]
Add in support for getIntPtrType to get the pointer type based on the address space.
This checkin also adds in some tests that utilize these paths and updates some of the
clients.
llvm-svn: 166578
Douglas Gregor [Wed, 24 Oct 2012 15:49:58 +0000 (15:49 +0000)]
(De-)serialize the file system options.
llvm-svn: 166577
Douglas Gregor [Wed, 24 Oct 2012 15:17:15 +0000 (15:17 +0000)]
Serialize DiagnosticOptions to the AST file.
llvm-svn: 166572
Mahesha S [Wed, 24 Oct 2012 15:12:40 +0000 (15:12 +0000)]
Removed an extra blank line.
llvm-svn: 166571
Manuel Klimek [Wed, 24 Oct 2012 14:47:44 +0000 (14:47 +0000)]
Adds the possibility to run ASTMatchFinder over arbitrary AST nodes.
llvm-svn: 166567
Elena Demikhovsky [Wed, 24 Oct 2012 14:46:16 +0000 (14:46 +0000)]
Special calling conventions for Intel OpenCL built-in library.
llvm-svn: 166566
Douglas Gregor [Wed, 24 Oct 2012 14:13:21 +0000 (14:13 +0000)]
Add a simple test involving decltype on Objective-C properties and ivars
llvm-svn: 166562
Douglas Gregor [Wed, 24 Oct 2012 14:11:55 +0000 (14:11 +0000)]
Remove the HiddenWeakTemplateVTables CodeGen option. It's currently unused.
llvm-svn: 166561
Evgeniy Stepanov [Wed, 24 Oct 2012 14:05:29 +0000 (14:05 +0000)]
Pass LLVM_ANDROID_TOOLCHAIN_DIR if set.
This lets one build ASan runtime for ARM/Android by running
make -C tools/clang/runtime/ \
LLVM_ANDROID_TOOLCHAIN_DIR=/path/to/ndk/toolchain
in an existing build tree.
llvm-svn: 166560
Evgeniy Stepanov [Wed, 24 Oct 2012 14:03:41 +0000 (14:03 +0000)]
Build ASan runtime for ARM/Android.
llvm-svn: 166559
Alexey Samsonov [Wed, 24 Oct 2012 13:34:53 +0000 (13:34 +0000)]
Update docs about TSan availability in CMake build
llvm-svn: 166558
Alexey Samsonov [Wed, 24 Oct 2012 13:21:51 +0000 (13:21 +0000)]
Fix some wordings in AddressSanitizer docs.
llvm-svn: 166557
NAKAMURA Takumi [Wed, 24 Oct 2012 12:26:08 +0000 (12:26 +0000)]
[CMake] Introduce LLVM_EXTERNAL_COMPILER_RT_SOURCE_DIR.
llvm-svn: 166552
Ulrich Weigand [Wed, 24 Oct 2012 12:22:56 +0000 (12:22 +0000)]
A number of test cases assume that an "int" parameter or return value
will be represented in the IR as a plain "i32" type. This causes the
tests to spuriously fail on platforms where int is not a 32-bit type,
or where the ABI requires attributes like "signext" or "zeroext" to
be used.
This patch adds -triple or -target parameters to force those tests
to use the i386-unknown-unknown target.
llvm-svn: 166551
Alexander Potapenko [Wed, 24 Oct 2012 09:35:23 +0000 (09:35 +0000)]
[ASan] Rename ReplaceCFAllocator to MaybeReplaceCFAllocator.
Replace the allocator only if the replace_cfallocator flag is set (in some cases it wasn't checked)
llvm-svn: 166550
Alexander Potapenko [Wed, 24 Oct 2012 09:19:16 +0000 (09:19 +0000)]
[ASan] Use internal_memmove() in both static and dynamic runtime libraries if asan_inited != 0.
llvm-svn: 166549
Alexey Samsonov [Wed, 24 Oct 2012 09:19:11 +0000 (09:19 +0000)]
[ASan] Due to data races, ASan malloc stats are inaccurate, which may cause certain ASan interface functions returning negative values (casted to unsigned). Return a reasonable value if such a case is detected.
llvm-svn: 166548
Duncan Sands [Wed, 24 Oct 2012 07:17:20 +0000 (07:17 +0000)]
Add a testcase that would have noticed the typo fixed in commit 166475.
llvm-svn: 166547
Michael Liao [Wed, 24 Oct 2012 04:14:18 +0000 (04:14 +0000)]
Teach DAG combine to fold (buildvec (Xint2fp x)) to (Xint2fp (buildvec x))
- If more than 1 elemennts are defined and target supports the vectorized
conversion, use the vectorized one instead to reduce the strength on
conversion operation.
llvm-svn: 166546
Michael Liao [Wed, 24 Oct 2012 04:09:32 +0000 (04:09 +0000)]
Add custom conversion from v2u32 to v2f32 in 32-bit mode
- As there's no 64-bit GPRs in 32-bit mode, a custom conversion from v2u32 to
v2f32 is added to improve the efficiency of the code generated.
llvm-svn: 166545
NAKAMURA Takumi [Wed, 24 Oct 2012 03:59:09 +0000 (03:59 +0000)]
Revert r166541, "clang/test: Add appropriate requirements as REQUIRES, corresponding to r166532."
According to r166543, it is not needed for now.
llvm-svn: 166544
Nadav Rotem [Wed, 24 Oct 2012 03:52:31 +0000 (03:52 +0000)]
Clang now attempts to create a TargetMachine whenever a triple is given.
Many of our tests specify triples that are not built into clang.
In this commit we allow clang to fail loading the triple if we are only
using clang to emit llvm ir.
llvm-svn: 166543
Jason Molenda [Wed, 24 Oct 2012 03:29:40 +0000 (03:29 +0000)]
eArgTypePath was removed in r166533; change -c to
expect eArgTypeFilename.
llvm-svn: 166542
NAKAMURA Takumi [Wed, 24 Oct 2012 02:57:57 +0000 (02:57 +0000)]
clang/test: Add appropriate requirements as REQUIRES, corresponding to r166532.
llvm-svn: 166541
Nico Weber [Wed, 24 Oct 2012 02:37:03 +0000 (02:37 +0000)]
Add a test for -Warc-abi as requested by Fariborz.
llvm-svn: 166540
Akira Hatanaka [Wed, 24 Oct 2012 02:10:54 +0000 (02:10 +0000)]
[mips] Make sure sret argument is returned in register V0.
llvm-svn: 166539
Rafael Espindola [Wed, 24 Oct 2012 01:59:00 +0000 (01:59 +0000)]
Add padding inreg registers to cause llvm to skip ecx when needed with
the x86_fastcallcc calling convention.
llvm-svn: 166538
Rafael Espindola [Wed, 24 Oct 2012 01:58:58 +0000 (01:58 +0000)]
Add inreg markers with the x86_fastcallcc calling convention.
llvm-svn: 166537
Rafael Espindola [Wed, 24 Oct 2012 01:58:48 +0000 (01:58 +0000)]
Change x86_fastcallcc to require inreg markers. This allows it to known
the difference from "int x" (which should go in registers and
"struct y {int x;}" (which should not).
Clang will be updated in the next patches.
llvm-svn: 166536
Enrico Granata [Wed, 24 Oct 2012 01:23:57 +0000 (01:23 +0000)]
<rdar://problem/
12523238> Commit 3 of 3
Changed all relevant test cases to verify that MightHaveChildren() works correctly for objects of interest
Added a bunch of convenience methods for test cases to use: target(), process(), thread() and frame() which mimic the lldb.X convenience variables
As a bonus, edited the documentation on the website to describe the new method available for synthetic children providers writers to implement!
That's all folks!
llvm-svn: 166535
Matt Beaumont-Gay [Wed, 24 Oct 2012 01:14:28 +0000 (01:14 +0000)]
Address feedback from Eli Friedman on r166522.
In particular, we do want to warn on some unused cast subexpressions within
macros.
llvm-svn: 166534
Sean Callanan [Wed, 24 Oct 2012 01:12:14 +0000 (01:12 +0000)]
This is a fix for the command option parser.
There was a generic catch-all type for path arguments
called "eArgTypePath," and a specialized version
called "eArgTypeFilename." It turns out all the
cases where we used eArgTypePath we could have
used Filename or we explicitly meant a directory.
I changed Path to DirectoryName, made it use the
directory completer, and rationalized the uses of
Path.
<rdar://problem/
12559915>
llvm-svn: 166533
Nadav Rotem [Wed, 24 Oct 2012 00:53:38 +0000 (00:53 +0000)]
Change EmitAssemblyHelper to create the target machine early
and use it to initialize the TargetTransformInfo analysis pass.
We need the TTI information for the loop vectorizer.
rdar://
12464901
llvm-svn: 166532
Jakub Staszak [Wed, 24 Oct 2012 00:38:25 +0000 (00:38 +0000)]
Keep coding standard. Don't evaluate getNumOperands() every time.
llvm-svn: 166531