| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
address spaces which is both (1) a "semantic" concept and
(2) possibly a hardware level restriction. It is desirable to
be able to discard/merge the LLVM-level address spaces on arguments for which
there is no difference to the current backend while keeping
track of the semantic address spaces in a funciton prototype. To do this
enable addition of the address space into the name-mangling process. Add
some tests to document this behaviour against inadvertent changes.
Patch by Michele Scandale!
llvm-svn: 190684
|
| |
|
|
|
|
|
|
| |
non-x-compile-safe tests
Patch by Artyom Skrobov!
llvm-svn: 190681
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Functions named "main", "wmain", "WinMain", "wWinMain", and "DllMain"
are never mangled regardless of linkage, even when compiling for kernel
mode.
Depends on D1655
Reviewers: timurrrr, pcc, rnk, whunt
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1670
llvm-svn: 190675
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This is a first step to getting extern "C" working properly inside
clang. There are a number of quirks but mangling declarations inside
such a function are a good first step.
Reviewers: timurrrr, pcc, cdavis5x
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1655
llvm-svn: 190671
|
| |
|
|
| |
llvm-svn: 190670
|
| |
|
|
|
|
|
| |
later in the code so that the expressions will have addition processing first.
This catches a few additional cases of uninitialized uses of class fields.
llvm-svn: 190657
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This restores the sqrt -> llvm.sqrt mapping, but only in fast-math mode
(specifically, when the UnsafeFPMath or NoNaNsFPMath CodeGen options are
enabled). The @llvm.sqrt* intrinsics have slightly different semantics from the
libm call, specifically, they are undefined when given a non-zero negative
number (the libm calls will always return NaN for any negative number).
This mapping was removed in r100613, and replaced with a TODO, but at that time
the fast-math flags were not yet implemented. Now that we have these, restoring
this mapping is important because it will enable autovectorization of sqrt
calls in loops (at least in fast-math mode).
llvm-svn: 190646
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a comma occurs in a default argument or default initializer within a
class, disambiguate whether it is part of the initializer or whether it ends
the initializer.
The way this works (which I will be proposing for standardization) is to treat
the comma as ending the default argument or default initializer if the
following token sequence matches the syntactic constraints of a
parameter-declaration-clause or init-declarator-list (respectively).
This is both consistent with the disambiguation rules elsewhere (where entities
are treated as declarations if they can be), and should have no regressions
over our old behavior. I think it might also disambiguate all cases correctly,
but I don't have a proof of that.
There is an annoyance here: because we're performing a tentative parse in a
situation where we may not have seen declarations of all relevant entities (if
the comma is part of the initializer, lookup may find entites declared later in
the class), we need to turn off typo-correction and diagnostics during the
tentative parse, and in the rare case that we decide the comma is part of the
initializer, we need to revert all token annotations we performed while
disambiguating.
Any diagnostics that occur outside of the immediate context of the tentative
parse (for instance, if we trigger the implicit instantiation of a class
template) are *not* suppressed, mirroring the usual rules for a SFINAE context.
llvm-svn: 190639
|
| |
|
|
|
|
| |
<rdar://problem/14970968>
llvm-svn: 190635
|
| |
|
|
|
|
|
|
|
|
|
| |
variable uninitialized every time we reach its (reachable) declaration, or
every time we call the surrounding function, promote the warning from
-Wmaybe-uninitialized to -Wsometimes-uninitialized.
This is still slightly weaker than desired: we should, in general, warn
if a use is uninitialized the first time it is evaluated.
llvm-svn: 190623
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This moves the code to Job.cpp, which seems like a more natural fit,
and replaces the "is this a JobList? is this a Command?" logic with
a virtual function call.
It also removes the code duplication between PrintJob and
PrintDiagnosticJob and simplifies the code a little.
There's no functionality change here, except that the Executable is
now always printed within quotes, whereas it would previously not be
quoted in crash reports, which I think was a bug.
Differential Revision: http://llvm-reviews.chandlerc.com/D1653
llvm-svn: 190620
|
| |
|
|
|
|
|
|
| |
initializer_list.
rdar://14887351
llvm-svn: 190561
|
| |
|
|
|
|
|
|
| |
It'd be another issue that the terminal and stdout(including redirects) with utf8. This test XPASSed on Win32, at least on Lit.
FYI, we don't use a triplet like "-win64" anywhere.
llvm-svn: 190559
|
| |
|
|
|
|
|
| |
unknown methods which return Cocoa objects. No need to annotate
such methods.
llvm-svn: 190555
|
| |
|
|
|
|
| |
arguments to map strings to the proper enumeration value. This makes error checking more consistent and reduces the amount of hand-written code required.
llvm-svn: 190545
|
| |
|
|
|
|
|
|
| |
such that it does not lower case the staring property
name if getter name (after "get" prefix) starts with
two upper case letters.
llvm-svn: 190539
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This test only works on systems capable of outputting UTF-8 encoded
text on the standard output (tested on linux and OS X, should XFAIL on windows,
if I haven't messed up the XFAIL line).
Reviewers: jordan_rose
Reviewed By: jordan_rose
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1607
llvm-svn: 190537
|
| |
|
|
|
|
| |
start with "get" are inferreed as a readonly properties.
llvm-svn: 190532
|
| |
|
|
| |
llvm-svn: 190531
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RegionStore tries to protect against accidentally initializing the same
region twice, but it doesn't take subregions into account very well. If
the outer region being initialized is a struct with an empty base class,
the offset of the first field in the struct will be 0. When we initialize
the base class, we may invalidate the contents of the struct by providing
a default value of Unknown (or some new symbol). We then go to initialize
the member with a zeroing constructor, only to find that the region at
that offset in the struct already has a value. The best we can do here is
to invalidate that value and continue; neither the old default value nor
the new 0 is correct for the entire struct after the member constructor call.
The correct solution for this is to track region extents in the store.
<rdar://problem/14914316>
llvm-svn: 190530
|
| |
|
|
|
|
|
| |
This also bakes the /M options into a separate option group to make
them easier to refer to from the code.
llvm-svn: 190529
|
| |
|
|
| |
llvm-svn: 190526
|
| |
|
|
| |
llvm-svn: 190525
|
| |
|
|
| |
llvm-svn: 190516
|
| |
|
|
|
|
|
|
|
|
|
| |
With r190382, -Wunused-variable warns about unused const variables when
appropriate. For codebases that use -Werror, this poses a problem as
existing unused const variables need to be cleaned up first. To make the
transistion easier, this patch splits -Wunused-variable by pulling out
an additional -Wunused-const-variable (by default activated along with
-Wunused-variable).
llvm-svn: 190508
|
| |
|
|
|
|
|
| |
The elements of the operands should be half the width of the elements of
the result.
llvm-svn: 190505
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch is the first step to make module-map-files modular (instead
of requiring a single "module.map"-file per include directory). This
step adds a new "extern module" declaration that enables
module-map-files to reference one another along with a very basic
implementation.
The next steps are:
* Combine this with the use-declaration (from
http://llvm-reviews.chandlerc.com/D1546) in order to only load module
map files required for a specific compilation.
* Add an additional flag to start with a specific module-map-file (instead
of requiring there to be at least one "module.map").
Review: http://llvm-reviews.chandlerc.com/D1637
llvm-svn: 190497
|
| |
|
|
| |
llvm-svn: 190496
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
More accurately characterize the nature of array parameters. Doing this
removes false back-reference opportunities. Remove some hacks now that
we characterize these better.
Reviewers: rnk, timurrrr, whunt, cdavis5x
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1626
llvm-svn: 190488
|
| |
|
|
|
|
| |
PR17123.
llvm-svn: 190484
|
| |
|
|
| |
llvm-svn: 190483
|
| |
|
|
|
|
|
|
|
| |
Fixes a crash in cases where the first argument was an incomplete type
or an uninstantiated template type.
<rdar://problem/14938471>
llvm-svn: 190482
|
| |
|
|
|
|
| |
constructor, copy assignment operator and move assignment operator.
llvm-svn: 190481
|
| |
|
|
|
|
| |
argument. Instead, it takes an expression that is fully resolved.
llvm-svn: 190476
|
| |
|
|
|
|
|
|
|
|
|
| |
non-member function, the number of arguments in the two candidate calls
will be different (the non-member call will have one extra argument).
We used to get confused by this, and fail to compare the last argument
when testing whether the member is better, resulting in us always
thinking it is, even if the non-member is more specialized in the last
argument.
llvm-svn: 190470
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Some build systems use pipes for stdin/stderr. On nix-ish platforms colored
output can be forced by -fcolor-diagnostics. On Windows this option has
no effect in these cases because LLVM uses the console API (which only
operates on the console buffer) even if a console wrapper capable of
interpreting ANSI escape codes is used.
The -fansi-escape-codes option allows switching from the console API to
ANSI escape codes. It has no effect on other platforms.
llvm-svn: 190464
|
| |
|
|
|
|
|
|
|
|
| |
As requested when applying the same logic to calling conventions.
Reviewers: rsmith
Differential Revision: http://llvm-reviews.chandlerc.com/D1634
llvm-svn: 190441
|
| |
|
|
|
|
|
| |
treat such subtractions as being non-constant. Patch by Serge Pavlov! With a
few tweaks by me.
llvm-svn: 190439
|
| |
|
|
|
|
|
|
|
| |
Make sure we perform the correct "referenced-but-not-used" check for
static member constants.
Fixes bug reported on cfe-commits by Alexey Samsonov.
llvm-svn: 190437
|
| |
|
|
|
|
|
| |
The test filename (%s) is easily confused with an option when
it starts with /Users...
llvm-svn: 190435
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Summary: Dynamic initializers are mangled as ??__E <name> YAXXZ.
Reviewers: timurrrr
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1477
llvm-svn: 190434
|
| |
|
|
| |
llvm-svn: 190432
|
| |
|
|
|
|
|
|
| |
This adds driver support for building DLLs (the /LD and /LDd flags).
It basically does two things: runtime selection and passing -dll and
-implib to the linker.
llvm-svn: 190428
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Static locals requiring initialization are not thread safe on Windows.
Unfortunately, it's possible to create static locals that are actually
externally visible with inline functions and templates. As a result, we
have to implement an initialization guard scheme that is compatible with
TUs built by MSVC, which makes thread safety prohibitively difficult.
MSVC's scheme is that every function that requires a guard gets an i32
bitfield. Each static local is assigned a bit that indicates if it has
been initialized, up to 32 bits, at which point a new bitfield is
created. MSVC rejects inline functions with more than 32 static locals,
and the externally visible mangling (?_B) only allows for one guard
variable per function.
On Eli's recommendation, I used MangleNumberingContext to track which
bit each static corresponds to.
Implements PR16888.
Reviewers: rjmccall, eli.friedman
Differential Revision: http://llvm-reviews.chandlerc.com/D1416
llvm-svn: 190427
|
| |
|
|
|
|
| |
with a suitable 'getter' attribute.
llvm-svn: 190420
|
| |
|
|
|
|
|
|
|
|
|
| |
Dotfiles are impractical on Windows. This makes clang-format search
for the style configuration file as '_clang-format' in addition to
the usual '.clang-format'. This is similar to how VIM searches for
'_vimrc' on Windows.
Differential Revision: http://llvm-reviews.chandlerc.com/D1629
llvm-svn: 190413
|
| |
|
|
|
|
| |
The dotp_[su].b instructions never existed in any revision of the MSA spec.
llvm-svn: 190399
|
| |
|
|
|
|
|
| |
Enabling sse4.2 will implicitly enable popcnt unless popcnt is explicitly disabled.
Disabling sse4.2 will not disable popcnt if popcnt is explicitly enabled.
llvm-svn: 190387
|
| |
|
|
|
|
| |
for the copy assignment operator.
llvm-svn: 190385
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch does a few different things.
This patch improves unused var diags for const vars: we no longer
unconditionally suppress diagnostics for const vars, instead only suppressing
the diagnostic when the declaration appears to be useful.
This patch also makes us more consistently use whether a variable/function
is declared in the main file to suppress diagnostics where appropriate.
Fixes <rdar://problem/14907887>.
llvm-svn: 190382
|