| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
method to be correct. Right now it correctly computes the cache, then
goes ahead and computes the result the hard way, then asserts that they
match. Next I'll actually turn it on.
llvm-svn: 103231
|
|
|
|
| |
llvm-svn: 103192
|
|
|
|
|
|
|
|
|
|
| |
SourceManager::isBeforeInTranslationUnit() where the
method will sometimes return different results for the same input SourceLocations. I haven't
unraveled this method completely yet, so this truly is a workaround until a better fix comes
along.
llvm-svn: 103143
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
print the diagnostic category number in the [] at the end
of the line. For example:
$ cat t.c
#include <stdio.h>
void foo() {
printf("%s", 4);
}
$ clang t.c -fsyntax-only -fdiagnostics-print-source-range-info
t.c:3:11:{3:10-3:12}{3:15-3:16}: warning: conversion specifies type 'char *' but the argument has type 'int' [-Wformat,1]
printf("%s", 4);
~^ ~
1 warning generated.
Clients that want category information can now pick the number
out of the output, rdar://7928231.
More coming.
llvm-svn: 103053
|
|
|
|
|
|
|
|
|
| |
and diagnostic groups. This allows the compiler to group
diagnostics together (e.g. "Logic Warning",
"Format String Warning", etc) like the static analyzer does.
This is not exposed through anything in the compiler yet.
llvm-svn: 103051
|
|
|
|
|
|
| |
variants. This fixes neon inline asm which my patch for PR6780 broke.
llvm-svn: 102181
|
|
|
|
| |
llvm-svn: 102098
|
|
|
|
|
|
|
|
|
|
|
| |
- This fixes the last known ABI issues with ARM/APCS.
- I've run the first 1k ABITests with '--no-unsigned --no-vector --no-complex'
on {armv6, armv7} x {-mno-thumb, -mthumb}, and the first 10k tests for armv7
-mthumb, for both function return types and single argument calls. These all
pass now (they failed horribly before without --no-bitfield).
llvm-svn: 102070
|
|
|
|
|
|
|
| |
and only define it where we know we need it---Linux and Cygwin. Thanks
to Chris for the prodding.
llvm-svn: 101989
|
|
|
|
|
|
| |
a const_cast.
llvm-svn: 101940
|
|
|
|
|
|
|
|
| |
into ContentCache::getBuffer. This allows it to produce
diagnostics on the broken #include line instead of without a
location.
llvm-svn: 101939
|
|
|
|
|
|
|
|
|
| |
about it instead of producing tons of garbage from the lexer.
It would be even better for sourcemgr to dynamically transcode (e.g.
from UTF16 -> UTF8).
llvm-svn: 101924
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
we will print with each error that occurs during template
instantiation. When the backtrace is longer than that, we will print
N/2 of the innermost backtrace entries and N/2 of the outermost
backtrace entries, then skip the middle entries with a note such as:
note: suppressed 2 template instantiation contexts; use
-ftemplate-backtrace-limit=N to change the number of template
instantiation entries shown
This should eliminate some excessively long backtraces that aren't
providing any value.
llvm-svn: 101882
|
|
|
|
|
|
|
|
| |
implemented precisely the same as GCC, but the distinction GCC makes isn't
useful to represent. This allows parsing code which uses GCC-specific keywords
('asm', etc.) without parsing in a fully GNU mode.
llvm-svn: 101667
|
|
|
|
| |
llvm-svn: 101370
|
|
|
|
| |
llvm-svn: 101369
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Used to determine whether the alignment of the type in a bit-field is
respected when laying out structures. The default is true, targets can
override this as needed.
- This is designed to correspond to the PCC_BITFIELD_TYPE_MATTERS macro in
gcc. The AST/Sema implementation only affects one line, unless I have
forgotten something. I'd appreciate further review.
- IRgen still needs to be updated to fully support this (which is effectively
PR5591).
llvm-svn: 101356
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
separate count of "suppressed" errors. This way, semantic analysis
bits that depend on the error count to determine whether problems
occured (e.g., some template argument deduction failures, jump-scope
checking) will not get confused.
The actual problem here is that a missing #include (which is a fatal
error) could cause the jump-scope checker to run on invalid code,
which it is not prepared to do. Trivial fix for both
<rdar://problem/7775941> and <rdar://problem/7775709>.
llvm-svn: 101297
|
|
|
|
|
|
|
|
| |
actually turned it on. If a diag is produced by a warning which
is an extension but defaults to on, and has no warning group, don't
print any option info.
llvm-svn: 101071
|
|
|
|
| |
llvm-svn: 101060
|
|
|
|
| |
llvm-svn: 100982
|
|
|
|
|
|
|
| |
it. PR6812.
- This is another attempt at silencing annoying buildbot failures.
llvm-svn: 100914
|
|
|
|
|
|
|
|
| |
precompiled headers and/or when reading the contents of the file into
memory. These checks seem to be causing spurious regression-test
failures on Windows.
llvm-svn: 100866
|
|
|
|
| |
llvm-svn: 100687
|
|
|
|
|
|
| |
Right now the limit is 0 (aka disabled)
llvm-svn: 100684
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
of errors and warnings. This allows us to emit something like this:
2 warnings and 1 error generated.
instead of:
3 diagnostics generated.
This also stops counting 'notes' because they are just follow-on information
about the previous diag, not a diagnostic in themselves.
llvm-svn: 100675
|
|
|
|
|
|
| |
assembly for testcases.
llvm-svn: 100253
|
|
|
|
|
|
| |
the C-only "optimization".
llvm-svn: 100022
|
|
|
|
| |
llvm-svn: 100018
|
|
|
|
|
|
|
| |
term "fix-it" everywhere and even *I* get tired of long names
sometimes. No functionality change.
llvm-svn: 100008
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
cache of PartialDiagnostic::Storage objects into an allocator within
the ASTContext. This eliminates a significant amount of malloc
traffic, for a 10% performance improvement in -fsyntax-only wall-clock
time with 403.gcc's combine.c.
Also, eliminate the RequireNonAbstractType hack I put in earlier,
which was but a symptom of this larger problem.
Fixes <rdar://problem/7806091>.
llvm-svn: 99849
|
|
|
|
|
|
|
|
|
| |
how to handle a diagnostic during template argument deduction, which
may be "substitution failure", "suppress", or "report". This keeps us
from, e.g., emitting warnings while performing template argument
deduction.
llvm-svn: 99560
|
|
|
|
| |
llvm-svn: 99513
|
|
|
|
| |
llvm-svn: 99178
|
|
|
|
|
|
|
|
|
|
|
|
| |
Diagnostic subsystem, which is used in the rare case where we find a
serious problem (i.e., an inconsistency in the file system) while
we're busy formatting another diagnostic. In this case, the delayed
diagnostic will be emitted after we're done with the other
diagnostic. This is only to be used for fatal conditions detected at
very inconvenient times, where we can neither stop the current
diagnostic in flight nor can we suppress the second error.
llvm-svn: 99175
|
|
|
|
|
|
|
| |
entry in a precompiled header, so that we can detect modified files
even when we miss in the stat cache.
llvm-svn: 99149
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
deserialization of precompiled headers, where the deserialization of
the source location entry for a buffer (e.g., macro instantiation
scratch space) would overwrite a one-element FileID cache in the
source manager. When tickled at the wrong time, we would return the
wrong decomposed source location and eventually cause c-index-test to
crash.
Found by dumb luck. It's amazing this hasn't shown up before.
llvm-svn: 98940
|
|
|
|
|
|
| |
whether a file has changed since it was originally read.
llvm-svn: 98726
|
|
|
|
|
|
|
| |
changed, rather than trying to point out how it changed. The "why"
doesn't matter.
llvm-svn: 98725
|
|
|
|
|
|
|
|
|
| |
buffer was invalid when it was created, and use that bit to always set
the "Invalid" flag according to whether the buffer is invalid. This
ensures that all accesses to an invalid buffer are marked invalid,
improving recovery.
llvm-svn: 98690
|
|
|
|
|
|
|
| |
Invalid bit through; there are no safety-critical callers of these
functions.
llvm-svn: 98674
|
|
|
|
|
|
| |
them to recover more gracefully on failure.
llvm-svn: 98672
|
|
|
|
|
|
|
| |
SourceManager versions), updating those callers that need to recover
gracefully from failure.
llvm-svn: 98665
|
|
|
|
| |
llvm-svn: 98631
|
|
|
|
|
|
| |
const char*.
llvm-svn: 98630
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SourceManager's getBuffer() and, therefore, could fail, along with
Preprocessor::getSpelling(). Use the Invalid parameters in the literal
parsers (string, floating point, integral, character) to make them
robust against errors that stem from, e.g., PCH files that are not
consistent with the underlying file system.
I still need to audit every use caller to all of these routines, to
determine which ones need specific handling of error conditions.
llvm-svn: 98608
|
|
|
|
|
|
| |
simplifying the SourceManager interfaces somewhat.
llvm-svn: 98598
|
|
|
|
|
|
| |
and start simplifying the interfaces in SourceManager that can fail.
llvm-svn: 98594
|
|
|
|
| |
llvm-svn: 98591
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SourceManager's getBuffer() (and similar) operations. This abstract
can be used to force callers to cope with errors in getBuffer(), such
as missing files and changed files. Fix a bunch of callers to use the
new interface.
Add some very basic checks for file consistency (file size,
modification time) into ContentCache::getBuffer(), although these
checks don't help much until we've updated the main callers (e.g.,
SourceManager::getSpelling()).
llvm-svn: 98585
|