| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
| |
This commit introduces functionality that's used to serialize machine operands.
Only the physical register operands are serialized by this commit.
Reviewers: Duncan P. N. Exon Smith
Differential Revision: http://reviews.llvm.org/D10525
llvm-svn: 240425
|
| |
|
|
|
|
|
|
|
|
|
|
| |
When UpdateBaseRegUses sees an instruction that defines the base
register it must stop, as the base register value it is updating is no
longer live. Ideally we would already have seen the register be killed
(which is already checked for), but the kill flags may be inaccurate
and we have to account for this.
Differential Revision: http://reviews.llvm.org/D10566
llvm-svn: 240424
|
| |
|
|
|
|
| |
Found by ubsan.
llvm-svn: 240420
|
| |
|
|
|
|
|
|
| |
The class has a non-trivial dtor so we have to clean up before we move
in new members. Remove misleading comment as a default move assignment
operator will never be synthesized for this class.
llvm-svn: 240417
|
| |
|
|
| |
llvm-svn: 240416
|
| |
|
|
|
|
| |
doesn't work
llvm-svn: 240415
|
| |
|
|
|
|
| |
Use it in CodeGen where applicable. No functionality change intended.
llvm-svn: 240414
|
| |
|
|
|
|
| |
NFC.
llvm-svn: 240413
|
| |
|
|
|
|
|
|
| |
This makes sure the same mangling is used.
Should fix the OS X bots.
llvm-svn: 240411
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This only adds support for ULHU of an immediate address with/without a source register.
It does not include support for ULHU of the address of a symbol.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D9671
llvm-svn: 240410
|
| |
|
|
| |
llvm-svn: 240408
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: This isn't used right now, but it will be in some upcoming changes.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10568
llvm-svn: 240407
|
| |
|
|
|
|
|
| |
We only need to pass in a DataLayout when mangling a raw string, not when
constructing the mangler.
llvm-svn: 240405
|
| |
|
|
|
|
|
|
|
|
|
| |
So far, LLVM has not emitted correct addend for N64 and N32 ABI. This patch
fixes that. It also removes fixup from MCJIT for R_MIPS_PC16 relocation.
Patch by Vladimir Radosavljevic.
Differential Revision: http://reviews.llvm.org/D10565
llvm-svn: 240404
|
| |
|
|
| |
llvm-svn: 240403
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: For the sake of consistency and to make some upcoming changes a little less noisy.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10639
llvm-svn: 240398
|
| |
|
|
|
|
|
|
|
|
|
| |
The summary is that it moves the mangling earlier and replaces a few
calls to .addExternalSymbol with addSym.
I originally wanted to replace all the uses of addExternalSymbol with
addSym, but noticed it was a lot of work and doesn't need to be done
all at once.
llvm-svn: 240395
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This causes errors like:
ld: error: blah.o: requires dynamic R_X86_64_PC32 reloc against '' which
may overflow at runtime; recompile with -fPIC
blah.cc:function f(): error: undefined reference to ''
blah.o:g(): error: undefined reference to ''
I have not yet come up with an appropriate reproduction.
llvm-svn: 240394
|
| |
|
|
|
|
| |
Apparently, the style needs to be agreed upon first.
llvm-svn: 240390
|
| |
|
|
|
|
| |
Added all intrinsics, tests for encoding, tests for intrinsics.
llvm-svn: 240386
|
| |
|
|
|
|
|
|
| |
We hit undefined behaviour in some MCExpr tests when the LHS of a left
shift is -1. Twos-complement semantics are completely reasonable here,
so we should just do the shift in unsigned.
llvm-svn: 240385
|
| |
|
|
|
|
|
|
| |
Avoid shifting a negative value by sign-extending after the shift.
Fixes a couple of tests that were failing under ubsan.
llvm-svn: 240381
|
| |
|
|
|
|
|
| |
This patch copies the metadata of the unswitched branch to the newly
crreated branch in loop unswitch pass.
llvm-svn: 240378
|
| |
|
|
|
|
| |
I will add an explicit test in a second, but this fixes the bots.
llvm-svn: 240372
|
| |
|
|
|
|
|
| |
This came up when examining some code generated by clang's IRGen for
certain member pointers.
llvm-svn: 240369
|
| |
|
|
|
|
| |
I will add a second user in the next commit.
llvm-svn: 240366
|
| |
|
|
| |
llvm-svn: 240365
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
That way llvm-objdump can rely on it without adding an extra dependency
on CodeGen.
This change duplicates the FaultKind enum and the code that serializes
it to a string. I could not figure out a way to get around this without
adding a new dependency to Object
Reviewers: rafael, ab
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10619
llvm-svn: 240364
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instructions
Currently ( D10321, http://reviews.llvm.org/rL239486 ), we can use the machine combiner pass
to reassociate the following sequence to reduce the critical path:
A = ? op ?
B = A op X
C = B op Y
-->
A = ? op ?
B = X op Y
C = A op B
'op' is currently limited to x86 AVX scalar FP adds (with fast-math on), but in theory, it could
be any associative math/logic op (see TODO in code comment).
This patch generalizes the pattern match to ignore the instruction that defines 'A'. So instead of
a sequence of 3 adds, we now only need to find 2 dependent adds and decide if it's worth
reassociating them.
This generalization has a compile-time cost because we can now match more instruction sequences
and we rely more heavily on the machine combiner to discard sequences where reassociation doesn't
improve the critical path.
For example, in the new test case:
A = M div N
B = A add X
C = B add Y
We'll match 2 reassociation patterns, but this transform doesn't reduce the critical path:
A = M div N
B = A add Y
C = B add X
We need the combiner to reject that pattern but select this:
A = M div N
B = X add Y
C = B add A
Differential Revision: http://reviews.llvm.org/D10460
llvm-svn: 240361
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
reference. NFC"
This version fixes a missing include that MSVC noticed and
clarifies the ownership of the counter buffer that's passed to
InstrProfRecord.
This restores r240206, which was reverted in r240208.
Patch by Betul Buyukkurt.
llvm-svn: 240360
|
| |
|
|
|
|
|
| |
r226830 moved the declaration of Buf to a nested scope, resulting
in a dangling reference (in StringRef Name), and a use-after-free.
llvm-svn: 240357
|
| |
|
|
|
|
|
|
|
|
|
| |
Remove std::move() around xvalue so that copy elision is eligible.
In case that copy elision is not appliable, the c++ standard also
guarantees the move semantics on xvalue. Thus, it is not necessary
to wrap Args with std::move.
This also silence a warning since r240345.
llvm-svn: 240355
|
| |
|
|
|
|
|
|
| |
As with the previous patch, the goal is to turn the class into a general
loop-versioning class. This patch removes any references to loop
distribution.
llvm-svn: 240352
|
| |
|
|
|
|
|
|
|
|
|
|
| |
dynamic allocation/ownership here
The one caller that does anything other than keep this variable on the
stack is the single use of DerivedArgList in Clang, which is a bit more
interesting but can probably be cleaned up/simplified a bit further
(have DerivedArgList take ownership of the InputArgList rather than
needing to reference its Args indirectly) which I'll try to after this.
llvm-svn: 240345
|
| |
|
|
| |
llvm-svn: 240343
|
| |
|
|
| |
llvm-svn: 240342
|
| |
|
|
| |
llvm-svn: 240341
|
| |
|
|
|
|
|
| |
I inadvertently checked these in with Windows-style line
endings in r240288.
llvm-svn: 240340
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MachOUniversalBinary::getObjectForArch()
The reason we need to search by name rather than by Triple::ArchType
is to handle subarchitecture correclty. There is no different ArchType
for the x86_64h architecture (it identifies itself as x86_64), or for
the various ARM subarches. The only way to get to the subarch slice
in an universal binary is to search by name.
This issue led to hard to debug and transient symbolication failures
in Asan tests (it mostly works, because the files are very similar).
This also affects the Profiling infrastucture as it is the other user
of that API.
Reviewers: samsonov, bogner
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10604
llvm-svn: 240339
|
| |
|
|
|
|
|
|
|
|
| |
Reviewers: arsenm, rafael
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10392
llvm-svn: 240331
|
| |
|
|
|
|
|
|
|
|
| |
Reviewers: arsenm, rafael
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10390
llvm-svn: 240330
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The _Int instructions are special, in that they operate on the full
VR128 instead of FR32. The load folding then looks at MOVSS, at the
user, and bails out when it sees a size mismatch.
What we really know is that the rm_Int instructions don't load the
higher lanes, so folding is fine.
This happens for the straightforward intrinsic code, e.g.:
_mm_add_ss(a, _mm_load_ss(p));
Fixes PR23349.
Differential Revision: http://reviews.llvm.org/D10554
llvm-svn: 240326
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This commit adds a function that tokenizes the string containing
the machine instruction. This commit also adds a struct called
'MIToken' which is used to represent the lexer's tokens.
Reviewers: Sean Silva
Differential Revision: http://reviews.llvm.org/D10521
llvm-svn: 240323
|
| |
|
|
|
|
|
| |
This avoids creating an unnecessary undefined reference on targets such as
NVPTX that require such references to be declared in asm output.
llvm-svn: 240321
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a reapplication of r239440 which was reverted in r239441.
There are no changes to this patch from then, but this had instead exposed
a bug in .thumb_set which was fixed in r240318. Having fixed that bug, it
is now safe to re-apply this code.
Original commit message below:
It wasn't possible to have a variable Symbol with offset or 'isCommon' so
this just enables better packing of the MCSymbol class.
Reviewed by Rafael Espindola.
llvm-svn: 240320
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to the documentation, .thumb_set is 'the equivalent of a .set directive'.
We didn't have equivalent behaviour in terms of all the errors we could throw, for
example, when a symbol is redefined.
This change refactors parseAssignment so that it can be used by .set and .thumb_set
and implements tests for .thumb_set for all the errors thrown by that method.
Reviewed by Rafael Espíndola.
llvm-svn: 240318
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
D8982 ( checked in at http://reviews.llvm.org/rL239001 ) added command-line
options to allow reciprocal estimate instructions to be used in place of
divisions and square roots.
This patch changes the default settings for x86 targets to allow that recip
codegen (except for scalar division because that breaks too much code) when
using -ffast-math or its equivalent.
This matches GCC behavior for this kind of codegen.
Differential Revision: http://reviews.llvm.org/D10396
llvm-svn: 240310
|
| |
|
|
|
|
|
|
| |
I had some unnecessary `typename`s left in after addressing review.
This compiled successfully with clang++ but MSVC reported an error. Fix
the build error by removing the redundant `typename`s.
llvm-svn: 240307
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Having different code paths for streamed and regular bitcode reading was a
source of bugs in the past and this defines them away.
It has a small but noticeable impact on performance. I timed running
"opt -disable-output -disable-verify" on a ltoed clang. It goes from
14.752845231 seconds time elapsed ( +- 0.16% )
to
15.012463721 seconds time elapsed ( +- 0.11% )
Extracted from a patch by Karl Schimpf.
llvm-svn: 240305
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
The parser is exercised by llvm-objdump using -print-fault-maps. As is
probably obvious, the code itself was "heavily inspired" by
http://reviews.llvm.org/D10434.
Reviewers: reames, atrick, JosephTremoulet
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10491
llvm-svn: 240304
|