| Commit message (Collapse) | Author | Age | Files | Lines | 
| ... |  | 
| | 
| 
| 
| 
| 
|  | 
Differential Revision: https://reviews.llvm.org/D34001
llvm-svn: 304995
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Summary:
- Implements TargetInfo class for Nios2 target.
- Enables handling of -march and -mcpu options for Nios2 target.
- Definition of Nios2 builtin functions.
Reviewed By: craig.topper
Differential Revision: https://reviews.llvm.org/D33356
Author: belickim <mateusz.belicki@intel.com>
llvm-svn: 304994
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
|  | 
ordering.
This is a temporarily fix which needs additional work, as it triggers a test3 failure.
test3 is commented out till then.
llvm-svn: 304993
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
This patch adds build vector patterns to exploit the vector integer
extend instructions:
vextsb2w - Vector Extend Sign Byte To Word
vextsb2d - Vector Extend Sign Byte To Doubleword
vextsh2w - Vector Extend Sign Halfword To Word
vextsh2d - Vector Extend Sign Halfword To Doubleword
vextsw2d - Vector Extend Sign Word To Doubleword
Differential Revision: https://reviews.llvm.org/D33510
llvm-svn: 304992
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
In SDAG, we don't expand libcalls with a nobuiltin attribute.
It's not clear if that's correct from the existing code comment:
"Don't do the check if marked as nobuiltin for some reason."
...adding a test here either way to show that there is currently
a different behavior implemented in the CGP-based expansion.
llvm-svn: 304991
 | 
| | 
| 
| 
| 
| 
|  | 
reference so we don't copy ConstantRanges unless we need to.
llvm-svn: 304990
 | 
| | 
| 
| 
|  | 
llvm-svn: 304989
 | 
| | 
| 
| 
|  | 
llvm-svn: 304988
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
The test diff for PowerPC shows we can better optimize if this case is one block.
For x86, there's would be a substantial difference if CGP expansion was enabled because branches are assumed 
cheap and SDAG can't optimize across blocks. 
Instead of this:
_cmp_eq8:
  movq  (%rdi), %rax
  cmpq  (%rsi), %rax
  je  LBB23_1
## BB#2:                                ## %res_block
  movl  $1, %ecx
  jmp LBB23_3
LBB23_1:
  xorl  %ecx, %ecx
LBB23_3:                                ## %endblock
  xorl  %eax, %eax
  testl %ecx, %ecx
  sete  %al
  retq
We get this:
cmp_eq8:   
  movq  (%rdi), %rcx
  xorl  %eax, %eax
  cmpq  (%rsi), %rcx
  sete  %al
  retq
And that matches the optimal codegen that we get from the current expansion in SelectionDAGBuilder::visitMemCmpCall(). 
If this looks right, then I just need to confirm that vector-sized expansion will work from here, and we can enable 
CGP memcmp() expansion for x86. Ie, we'll bypass the power-of-2 special cases currently optimized in SDAG because we 
can lower the IR produced here optimally.
Differential Revision: https://reviews.llvm.org/D34005
llvm-svn: 304987
 | 
| | 
| 
| 
| 
| 
| 
|  | 
This patch will close PR32801.
Differential Revision: https://reviews.llvm.org/D33203
llvm-svn: 304986
 | 
| | 
| 
| 
| 
| 
|  | 
Fixed spelling errors on function description.
llvm-svn: 304985
 | 
| | 
| 
| 
|  | 
llvm-svn: 304984
 | 
| | 
| 
| 
|  | 
llvm-svn: 304983
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Apparently support for /debug:fastlink PDBs isn't part of the
DIA SDK (!), and it was causing llvm-pdbdump to crash because
we weren't checking for a null pointer return value.  This
manifests when calling findChildren on the IDiaSymbol, and
it returns E_NOTIMPL.
llvm-svn: 304982
 | 
| | 
| 
| 
|  | 
llvm-svn: 304981
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Summary:
This patch adds information about the parameters and return types of completion
candidates.
Previously, for the following code:
```
struct S {
  int func(int a, double b) const;
};
```
the completer would only return the label of the candidate `func`.
Now it will also return the return type `int` and will format the label for the
candidate as `func(int a, double b) const`.
Reviewers: bkramer, ilya-biryukov
Reviewed By: ilya-biryukov
Subscribers: cfe-commits
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D34033
llvm-svn: 304980
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
We already had a test to demonstrate PR33325:
https://bugs.llvm.org/show_bug.cgi?id=33325
I'm adding tests for general memcmp expansion (see D34005 / D33963) and:
https://bugs.llvm.org/show_bug.cgi?id=33329
...plus non-power-of-2 sizes, so we can see what that looks like currently or if expanded.
llvm-svn: 304979
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Expose the following functions:
 - clang_getTypedefName
 - clang_getAddressSpace
Patch by Simon Perretta.
Differential Revision: https://reviews.llvm.org/D33598
llvm-svn: 304978
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Summary:
New checker to replace dynamic exception
specifications
This is an alternative to D18575 which relied on reparsing the decl to
find the location of dynamic exception specifications, but couldn't
deal with preprocessor conditionals correctly without reparsing the
entire file.
This approach uses D20428 to find dynamic exception specification
locations and handles all cases correctly.
Reviewers: aaron.ballman, alexfh
Reviewed By: aaron.ballman, alexfh
Subscribers: xazax.hun, mgehre, malcolm.parsons, mgorny, JDevlieghere, cfe-commits, Eugene.Zelenko, etienneb
Patch by Don Hinton!
Differential Revision: https://reviews.llvm.org/D20693
llvm-svn: 304977
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Summary:
When a call instruction is the last instruction in a function, the
backtrace PC will point past the end of the function. We already had
special code to handle that, but we did not handle the case where the PC
ends up outside of the bounds of the module containing the function,
which is a situation that occured in TestNoreturnUnwind on android for
some arch/compiler combinations.
I fix this by adding an argument to Address resolution code which states
that we are ok with addresses pointing to the end of a module/section to
resolve to that module/section.
I create a reproducible test case for this situation by hand-crafting an
executable which has a noreturn function at the end of a module.
Reviewers: jasonmolenda, jingham
Subscribers: lldb-commits
Differential Revision: https://reviews.llvm.org/D32022
llvm-svn: 304976
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
cloned constexpr
Have cloneConstantExprWithNewAddressSpaces return nullptr when
returning initial ConstantExpr.
Reviewers: arsenm
Subscribers: jholewinski, wdng, llvm-commits
Differential Revision: https://reviews.llvm.org/D33995
llvm-svn: 304975
 | 
| | 
| 
| 
|  | 
llvm-svn: 304974
 | 
| | 
| 
| 
|  | 
llvm-svn: 304973
 | 
| | 
| 
| 
| 
| 
| 
| 
|  | 
constants.
The initial patch was rejected: I fixed the issue and re-apply it.
llvm-svn: 304972
 | 
| | 
| 
| 
| 
| 
| 
| 
|  | 
Add a couple of tests to increase coverage for the TableGen'erated code,
in particular for rules where 2 generic instructions may be combined
into a single machine instruction.
llvm-svn: 304971
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
The zero heuristic assumes that integers are more likely positive than negative,
but this also has the effect of assuming that strcmp return values are more
likely positive than negative. Given that for nonzero strcmp return values it's
the ordering of arguments that determines the sign of the result there's no
reason to assume that's true.
Fix this by inspecting the LHS of the compare and using TargetLibraryInfo to
decide if it's strcmp-like, and if so only assume that nonzero is more likely
than zero i.e. strings are more often different than the same. This causes a
slight code generation change in the spec2006 benchmark 403.gcc, but with no
noticeable performance impact. The intent of this patch is to allow better
optimisation of dhrystone on Cortex-M cpus, but currently it won't as there are
also some changes that need to be made to if-conversion.
Differential Revision: https://reviews.llvm.org/D33934
llvm-svn: 304970
 | 
| | 
| 
| 
|  | 
llvm-svn: 304969
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
This patch adds LLVMGetSubtypes to Go API (as Type.Subtypes), tests included.
Patch by Ekaterina Vaartis!
Differential Revision: https://reviews.llvm.org/D33901
llvm-svn: 304968
 | 
| | 
| 
| 
|  | 
llvm-svn: 304967
 | 
| | 
| 
| 
| 
| 
| 
| 
|  | 
Richard decided to fix these cases in Clang, even though they are
representative of a larger problem for more complex
cases.
llvm-svn: 304966
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
A function declared in a friend declaration may have declarations prior
to the containing class definition. If such declaration defines default
argument, the friend function declaration inherits them. This behavior
causes problems if the class where the friend is declared is a template:
during the class instantiation the friend function looks like if it had
default arguments, so error is triggered.
With this change friend functions declared in class templates do not
inherit default arguments. Actual set of them will be defined at the
point where the containing class is instantiated.
This change fixes PR12724.
Differential Revision: https://reviews.llvm.org/D30393
llvm-svn: 304965
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Clang makes check for function redefinition after it merged the new
declaration with the existing one. As a result, it produces poor
diagnostics in the case of a friend function defined inline, as in
the code:
```
    void func() {}
    class C { friend void func() {} };
```
Error message in this case states that `inline declaration of 'func'
follows non-inline definition`, which is misleading, as `func` does
not have explicit `inline` specifier.
With this changes compiler reports function redefinition if the new
function is a friend defined inline and it does not have explicit
`inline` specifier.
Differential Revision: https://reviews.llvm.org/D26065
llvm-svn: 304964
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
Bitwise complement applied to vector of floats described with
attribute `ext_vector_type` is not diagnosed as error. Attempt to
compile such construct causes assertion violation in Instruction.cpp.
With this change the complement is treated similar to the case of
vector type described with attribute `vector_size`.
Differential Revision: https://reviews.llvm.org/D33732
llvm-svn: 304963
 | 
| | 
| 
| 
| 
| 
| 
|  | 
Change the diagnostic message from r304956 to be less confusing by reordering
the flow of information.
llvm-svn: 304962
 | 
| | 
| 
| 
| 
| 
|  | 
This then requires delaying a call to getHeaderSize.
llvm-svn: 304961
 | 
| | 
| 
| 
|  | 
llvm-svn: 304960
 | 
| | 
| 
| 
| 
| 
| 
| 
|  | 
The FirePro and Radeon versions of Hawaii have different 64 bit floating point configurations so use distinct target names for them. Rename the target name for Kabini to accommodate.
Differential Revision: https://reviews.llvm.org/D34016
llvm-svn: 304959
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
bitcode file.
This code now lives in lib/Object. The idea is that it can now be reused by
IRObjectFile among other things.
Differential Revision: https://reviews.llvm.org/D31921
llvm-svn: 304958
 | 
| | 
| 
| 
| 
| 
| 
|  | 
the injected-class-name of a specialization that uses a partial / explicit
specialization.
llvm-svn: 304957
 | 
| | 
| 
| 
| 
| 
| 
|  | 
Provide a little more information when a ODR violation is detected, but the
specific error could not be diagnosed.
llvm-svn: 304956
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
|  | 
r304862 changed how CTD handles deducing a non-primary class template
using a non-dependent constructor of the primary template. This change
requires libc++ to provide explicit deduction guides to make scoped_lock
work again.
llvm-svn: 304955
 | 
| | 
| 
| 
| 
| 
|  | 
warnings; other minor fixes (NFC).
llvm-svn: 304954
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
The test in r304929 broke multiple buildbots as it expected mips target to
be registered and available (which is not necessarily true). Updating the
test with this condition.
Original commit:
  [mips] Add runtime options to enable/disable madd.fmt and msub.fmt
  Add options to clang: -mmadd4 and -mno-madd4, use it to enable or disable
  generation of madd.fmt and similar instructions respectively, as per GCC.
  Patch by Stefan Maksimovic.
llvm-svn: 304953
 | 
| | 
| 
| 
| 
| 
|  | 
This allows moving clearOutputSections earlier.
llvm-svn: 304952
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
sure that non-template functions don't end up in the candidate set.
Fixes PR14211.
Patch by Don Hinton!
llvm-svn: 304951
 | 
| | 
| 
| 
| 
| 
| 
|  | 
The real offsets are computed in assignAddresses and we compute the
special cases we need earlier after this.
llvm-svn: 304950
 | 
| | 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
| 
|  | 
suppressed.
Summary:  "misc-noexcept-move-constructor" is better not to be issued when "-fno-exceptions" is set.
Reviewers: chh, alexfh, aaron.ballman
Reviewed By: aaron.ballman
Subscribers: aaron.ballman, cfe-commits, xazax.hun
Tags: #clang-tools-extra
Differential Revision: https://reviews.llvm.org/D34002
llvm-svn: 304949
 | 
| | 
| 
| 
|  | 
llvm-svn: 304948
 | 
| | 
| 
| 
| 
| 
|  | 
This allows moving clearOutputSections a bit earlier.
llvm-svn: 304947
 | 
| | 
| 
| 
| 
| 
| 
| 
|  | 
This is not required by the standard (yet), but there seems to be reasonable
support for this being a defect according to CWG discussion, and libstdc++ 7.1
relies on it working.
llvm-svn: 304946
 |