Manman Ren
5750c1c07e
X86 SSE Intrinsics: update header for sqrt_ss, rsqrt_ss and rcp_ss.
...
There intrinsics pass through the upper FP values from the input.
rdar://12558838
llvm-svn: 166743
2012-10-26 00:25:10 +00:00
Bill Wendling
9d1ee1175d
Recommit Eric's code to validate ASM string's constraints and modifiers.
...
This code checks the ASM string to see if the output size is able to fit within
the variable specified as the output. For instance, scalar-to-vector conversions
may not really work. It's on by default, but can be turned off with a flag if
you think you know what you're doing.
This is placed under a flag ('-Wasm-operand-widths') and flag group ('-Wasm').
<rdar://problem/12284092>
llvm-svn: 166737
2012-10-25 23:28:48 +00:00
Richard Smith
3750e7776b
Fix the other occurrence of the problem fixed by r166731.
...
llvm-svn: 166735
2012-10-25 23:05:00 +00:00
Richard Smith
9421156acc
LLVM's hashing routines produce a size_t, and thus generate different values for 32- and 64-bit host compilers. This really needs to be fixed -- the IR generated should not depend on the host -- but this change will get the bots green again. Proper fix to follow.
...
llvm-svn: 166731
2012-10-25 22:27:30 +00:00
Ted Kremenek
a5958869f6
TrackConstraintBRVisitor and ConditionBRVisitor can emit similar
...
path notes for cases where a value may be assumed to be null, etc.
Instead of having redundant diagnostics, do a pass over the generated
PathDiagnostic pieces and remove notes from TrackConstraintBRVisitor
that are already covered by ConditionBRVisitor, whose notes tend
to be better.
Fixes <rdar://problem/12252783>
llvm-svn: 166728
2012-10-25 22:07:10 +00:00
Richard Smith
1048356524
Add a more direct test for r166661.
...
llvm-svn: 166727
2012-10-25 21:59:45 +00:00
Chad Rosier
77c8aca06a
[ms-inline asm] Add a test case for r166723 and r166724.
...
llvm-svn: 166725
2012-10-25 21:52:03 +00:00
Kaelyn Uhrain
f1ecb7c62c
Move the input files for test/PCH/badpch.c under test/PCH/Inputs/.
...
llvm-svn: 166711
2012-10-25 19:43:57 +00:00
Douglas Gregor
d814a05f6b
When capturing 'this' in a lambda, make sure to update the set of
...
array-index starting values for the 'this' capture. Fixes
<rdar://problem/12426831>.
llvm-svn: 166709
2012-10-25 18:39:16 +00:00
NAKAMURA Takumi
920cff606b
clang/test/CodeGenCXX/debug-info-thunk.cpp: Suppress it for now with XFAIL:*, due to failing on i686-*-*.
...
llvm-svn: 166683
2012-10-25 14:43:34 +00:00
David Tweed
d8bb236e18
Correct test inovocations to use %clang_cc1 rather than direct invocation (so that it can have additional options set when trying to debug issues causing regressions).
...
llvm-svn: 166681
2012-10-25 13:56:30 +00:00
Alexey Samsonov
9b502e512c
Initialize debug info for special cases of functions that lack declarations and are generated by Clang (global initializers/destructors, thunks) . Fixes PR13942.
...
llvm-svn: 166676
2012-10-25 10:18:50 +00:00
Argyrios Kyrtzidis
d53d0daab9
Take into account that there may be a BOM at the beginning of the file,
...
when computing the size of the precompiled preamble.
llvm-svn: 166659
2012-10-25 01:51:45 +00:00
Douglas Gregor
79ae600e8f
Update warning-flag test
...
llvm-svn: 166656
2012-10-25 00:34:38 +00:00
Bill Wendling
d75987dde9
Revert r166647 to rethink the patch...
...
llvm-svn: 166655
2012-10-25 00:32:44 +00:00
Eli Friedman
ade609770e
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
2012-10-25 00:12:49 +00:00
Bill Wendling
753c8782df
Add some support for diagnosing possibly mismatched constraint, type size and
...
modifiers. (From an idea by Eric...)
<rdar://problem/12284092>
llvm-svn: 166647
2012-10-25 00:05:55 +00:00
Richard Smith
d16fe12e77
'constexpr' and 'friend' are both declaration specifiers. Teach the parser this, for better error recovery.
...
llvm-svn: 166645
2012-10-25 00:00:53 +00:00
Richard Smith
527b15e8f1
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
2012-10-24 23:51:56 +00:00
Douglas Gregor
b636875196
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
2012-10-24 23:41:50 +00:00
Chad Rosier
602d09d0aa
[ms-inline asm] Test case for r166632.
...
llvm-svn: 166633
2012-10-24 22:22:12 +00:00
David Blaikie
a9d4a936a8
Fix false positive in -Wunused-variable when a ctor call make involve cleanups.
...
llvm-svn: 166625
2012-10-24 21:29:06 +00:00
Eli Friedman
be20d43232
Update regression tests for r166617.
...
llvm-svn: 166619
2012-10-24 20:28:18 +00:00
Eli Friedman
6fd26424af
Don't print scope qualifiers for references to a type defined locally in a function. Patch by Grzegorz Jablonski.
...
llvm-svn: 166617
2012-10-24 20:21:25 +00:00
Eli Friedman
82dc260385
Add an additional test for namespaces and -Wmissing-variable-declarations. Move C++ test into SemaCXX.
...
llvm-svn: 166616
2012-10-24 20:14:09 +00:00
Rafael Espindola
c9d17591d9
Add a test showing that nodebug is accepted in methods too. Patch by
...
Paul Robinson.
llvm-svn: 166606
2012-10-24 18:34:26 +00:00
Douglas Gregor
360d3a5b06
Explicitly specify C++98 when building the C++ precompiled header for this test, so that the test will work on Windows.
...
llvm-svn: 166601
2012-10-24 17:49:01 +00:00
Chad Rosier
340c1ca0f3
[ms-inline asm] Add test cases for r166451.
...
llvm-svn: 166600
2012-10-24 17:48:01 +00:00
Chad Rosier
42146d9a06
[ms-inline asm] Add test cases for r166592. The test cases only works if the
...
source operand is a register.
llvm-svn: 166594
2012-10-24 17:23:06 +00:00
Douglas Gregor
2b0a568cdc
Add a simple test involving decltype on Objective-C properties and ivars
...
llvm-svn: 166562
2012-10-24 14:13:21 +00:00
Ulrich Weigand
35668cc401
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
2012-10-24 12:22:56 +00:00
NAKAMURA Takumi
f1f6e99c53
Revert r166541, "clang/test: Add appropriate requirements as REQUIRES, corresponding to r166532."
...
According to r166543, it is not needed for now.
llvm-svn: 166544
2012-10-24 03:59:09 +00:00
NAKAMURA Takumi
a22fe582d2
clang/test: Add appropriate requirements as REQUIRES, corresponding to r166532.
...
llvm-svn: 166541
2012-10-24 02:57:57 +00:00
Nico Weber
2643452746
Add a test for -Warc-abi as requested by Fariborz.
...
llvm-svn: 166540
2012-10-24 02:37:03 +00:00
Rafael Espindola
fad28de40c
Add padding inreg registers to cause llvm to skip ecx when needed with
...
the x86_fastcallcc calling convention.
llvm-svn: 166538
2012-10-24 01:59:00 +00:00
Rafael Espindola
077dd59371
Add inreg markers with the x86_fastcallcc calling convention.
...
llvm-svn: 166537
2012-10-24 01:58:58 +00:00
Matt Beaumont-Gay
53e767bf6b
Address feedback from Eli Friedman on r166522.
...
In particular, we do want to warn on some unused cast subexpressions within
macros.
llvm-svn: 166534
2012-10-24 01:14:28 +00:00
Jordan Rose
1bbd143945
[analyzer] Handle 'SomeVar.SomeEnumConstant', which is legal in C++.
...
This caused assertion failures analyzing LLVM.
<rdar://problem/12560282>
llvm-svn: 166529
2012-10-23 23:59:08 +00:00
Jordan Rose
746c06d0bc
[analyzer] Replace -analyzer-no-eagerly-trim-egraph with graph-trim-interval.
...
After every 1000 CFGElements processed, the ExplodedGraph trims out nodes
that satisfy a number of criteria for being "boring" (single predecessor,
single successor, and more). Rather than controlling this with a cc1 option,
which can only disable this behavior, we now have an analyzer-config option,
'graph-trim-interval', which can change this interval from 1000 to something
else. Setting the value to 0 disables reclamation.
The next commit relies on this behavior to actually test anything.
llvm-svn: 166528
2012-10-23 23:59:05 +00:00
Chad Rosier
a96da4773c
[ms-inline asm] Test case for r166526.
...
llvm-svn: 166527
2012-10-23 23:42:25 +00:00
Chad Rosier
03c181b021
[ms-inline asm] Update the triple to test r166523.
...
llvm-svn: 166524
2012-10-23 23:32:21 +00:00
Matt Beaumont-Gay
493d6d55ba
Don't emit -Wunused-value warnings from macro expansions.
...
llvm-svn: 166522
2012-10-23 23:19:32 +00:00
Fariborz Jahanian
6f5309cf50
Objective-C: check that when a category method is being implemented,
...
method type in cateogry matches the implementation.
// rdar://12519216
llvm-svn: 166518
2012-10-23 23:06:22 +00:00
Eli Friedman
9cc8ac523c
Fix pretty-printing pseudo-destructor calls. Patch by Grzegorz Jablonski.
...
llvm-svn: 166500
2012-10-23 20:26:57 +00:00
Eli Friedman
4e2e13edb7
Delete junk that snuck into r166498.
...
llvm-svn: 166499
2012-10-23 20:23:23 +00:00
Eli Friedman
7d14b3c9b3
Add a new warning -Wmissing-variable-declarations, to warn about variables
...
defined without a previous declaration. This is similar to
-Wmissing-prototypes, but for variables instead of functions.
Patch by Ed Schouten.
llvm-svn: 166498
2012-10-23 20:19:32 +00:00
Richard Smith
40c180db13
When rebuilding a DependentScopeDeclRefExpr, perform a lookup into the scope
...
even if it's dependent, in case it now names a member of the current instantiation.
llvm-svn: 166496
2012-10-23 19:56:01 +00:00
Chad Rosier
b8097dec8f
[ms-inline asm] Update for r166433.
...
llvm-svn: 166489
2012-10-23 17:44:40 +00:00
Rafael Espindola
1ad26f0423
Handle -pthread, -pg and -shared correctly on bitrig.
...
Patch by David Hill.
llvm-svn: 166483
2012-10-23 17:07:31 +00:00
NAKAMURA Takumi
660489c49f
clang/test/PCH/pch-dir.c: Update a comment for msvc. msvc(*-win32) implies -std=c++11.
...
llvm-svn: 166478
2012-10-23 10:43:00 +00:00