| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
Some inputs would after r278974 without this fix (see
http://lab.llvm.org:8080/green/job/clang-stage2-cmake-RgSan_build/2733/console
for an example)
llvm-svn: 279022
|
|
|
|
|
|
|
|
| |
This will allow tail duplication and tail merging during layout to have a
shared threshold to make sure that they don't overlap. No observable change
intended.
llvm-svn: 278981
|
|
|
|
|
|
|
| |
This will cause minsize functions to have the same threshold as optsize
functions, but otherwise should have no effects.
llvm-svn: 278980
|
|
|
|
|
|
| |
Follow up to r278902. I had missed "fall through", with a space.
llvm-svn: 278970
|
|
|
|
| |
llvm-svn: 278969
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This is part of the "NodeType* -> NodeRef" migration. Notice that since
GraphWriter prints object address as identity, I added a static_assert on
NodeRef to be a pointer type.
Reviewers: dblaikie
Subscribers: llvm-commits, MatzeB
Differential Revision: https://reviews.llvm.org/D23580
llvm-svn: 278966
|
|
|
|
|
|
|
|
|
|
|
| |
This is a fix for https://llvm.org/bugs/show_bug.cgi?id=29010
Root cause of the bug is that the register class of the machine instruction operand does not fully reflect if this registers that can be allocated.
Both for i386 and x86_64 the operand's register class is VR128RegClass and thus contains xmm0-xmm15, though in i386 we can only use xmm0-xmm8.
In order to get the actual allocable registers of the class we need to use RegisterClassInfo.
Differential Revision: https://reviews.llvm.org/D23613
llvm-svn: 278954
|
|
|
|
|
|
|
|
|
|
|
| |
This is used to mark functions with the C++11 [[ noreturn ]] or C11 _Noreturn
attributes.
Patch by Victor Leschuk!
https://reviews.llvm.org/D23167
llvm-svn: 278940
|
|
|
|
|
|
|
|
|
|
| |
In theory the indices of RC (and thus the index used for LiveRegs) may differ from the indices of OpRC.
Fixed the code to extract the correct RC index.
OpRC contains the first X consecutive elements of RC, and thus their indices are currently de facto the same, therefore a test cannot be added at this point.
Differential Revision: https://reviews.llvm.org/D23491
llvm-svn: 278923
|
|
|
|
|
|
|
| |
Replacing the usage of MVT with EVT in case the vector type is expanded.
Differential Revision: https://reviews.llvm.org/D23306
llvm-svn: 278913
|
|
|
|
| |
llvm-svn: 278910
|
|
|
|
|
|
|
| |
This is a mechanical change of comments in switches like fallthrough,
fall-through, or fall-thru to use the LLVM_FALLTHROUGH macro instead.
llvm-svn: 278902
|
|
|
|
|
|
| |
Also put some commonly used subexpressions into variables.
llvm-svn: 278895
|
|
|
|
|
|
|
|
| |
Also avoid some pointless use of auto! Because that's friendlier to
readers and avoids several types accidentally resolving to unnecessary
references here (MachineInstr *&, unsigned &).
llvm-svn: 278894
|
|
|
|
| |
llvm-svn: 278893
|
|
|
|
| |
llvm-svn: 278879
|
|
|
|
|
|
|
|
| |
Rather than doing a funny dance that relies on dereferencing end() not
crashing, add some API to MachineInstrBundleIterator to get a non-const
version of the iterator.
llvm-svn: 278870
|
|
|
|
|
|
|
|
|
|
|
|
| |
If AnalyzeBranch can't analyze a block and it is possible to
fallthrough, then duplicating the block doesn't make sense, as only one
block can be the layout predecessor for the un-analyzable fallthrough.
Submitted wit a test case, but NOTE: the test case doesn't currently
fail. However, the test case fails with D20505 and would have saved me
some time debugging.
llvm-svn: 278866
|
|
|
|
|
|
|
|
| |
The current MachineBasicBlock might be the last block, so FallThru may
be past the end(). Use getNextNode(), which will convert to nullptr,
rather than &*++, which is invalid if we reach the end().
llvm-svn: 278858
|
|
|
|
| |
llvm-svn: 278847
|
|
|
|
|
|
|
|
|
|
| |
Do not reorder and move up a loop latch block before a loop header
when optimising for size because this will generate an extra
unconditional branch.
Differential Revision: https://reviews.llvm.org/D22521
llvm-svn: 278840
|
|
|
|
|
|
|
|
|
|
|
|
| |
location from the instruction
that immediately follows the rematerialization point.
Patch by Andrea DiBiagio.
Differential Revision: http://reviews.llvm.org/D23539
llvm-svn: 278822
|
|
|
|
| |
llvm-svn: 278810
|
|
|
|
|
|
|
|
|
|
|
|
| |
The pipeliner was generating an invalid Phi name for an operand
in the epilog block, which caused an assert in the live variable
analysis pass. The fix is to the code that generates new Phis
in the epilog block. In this case, there is an existing Phi that
needs to be reused rather than creating a new Phi instruction.
Differential Revision: https://reviews.llvm.org/D23513
llvm-svn: 278805
|
|
|
|
|
|
| |
And mark it as legal.
llvm-svn: 278802
|
|
|
|
|
|
|
|
| |
Following the discussion on D22038, this refactors a PowerPC specific setcc -> srl(ctlz) transformation so it can be used by other targets.
Differential Revision: https://reviews.llvm.org/D23445
llvm-svn: 278799
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: dblaikie
Subscribers: mzolotukhin, llvm-commits
Differential Revision: https://reviews.llvm.org/D23522
llvm-svn: 278752
|
|
|
|
|
|
|
|
| |
Regression from r259791.
Differential Revision: https://reviews.llvm.org/D23374
llvm-svn: 278750
|
|
|
|
|
|
|
| |
Before we mischaracterized structs and i1 types as a scalar with size 0 in
various ways.
llvm-svn: 278744
|
|
|
|
|
|
|
|
|
|
|
| |
in debug info using their stack slots instead of as an indirection of param reg + 0
offset. This is done by detecting FrameIndexSDNodes in SelectionDAG and generating
FrameIndexDbgValues for them. This ultimately generates DBG_VALUEs with stack
location operands.
Differential Revision: http://reviews.llvm.org/D23283
llvm-svn: 278703
|
|
|
|
|
|
|
|
|
|
|
| |
This adds two new utility functions findLoopControlBlock and findLoopPreheader
to MachineLoop and MachineLoopInfo. These functions are refactored and taken
from the Hexagon target as they are target independent; thus this is intendend to
be a non-functional change.
Differential Revision: https://reviews.llvm.org/D22959
llvm-svn: 278661
|
|
|
|
|
|
|
|
|
| |
This reverts commit r278287.
This commit broke the clang-cmake-thumbv7-a15-full-sh bot.
See https://llvm.org/bugs/show_bug.cgi?id=28949
llvm-svn: 278621
|
|
|
|
|
|
|
|
|
| |
This reverts commit r278288.
r278287 broke the clang-cmake-thumbv7-a15-full-sh bot.
Revert this so we can get to r278287.
llvm-svn: 278620
|
|
|
|
| |
llvm-svn: 278578
|
|
|
|
|
|
|
|
|
| |
Fixed a bug in the test case.
To fix PR28104, this patch restricts tail merging to blocks that belong to the
same loop after MBP.
llvm-svn: 278575
|
|
|
|
|
|
| |
This reverts commit r278463 because it hits the bot.
llvm-svn: 278484
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove all ilist_iterator to pointer casts. There were two reasons for
casts:
- Checking for an uninitialized (i.e., null) iterator. I added
MachineInstrBundleIterator::isValid() to check for that case.
- Comparing an iterator against the underlying pointer value while
avoiding converting the pointer value to an iterator. This is
occasionally necessary in MachineInstrBundleIterator, since there is
an assertion in the constructors that the underlying MachineInstr is
not bundled (but we don't care about that if we're just checking for
pointer equality).
To support the latter case, I rewrote the == and != operators for
ilist_iterator and MachineInstrBundleIterator.
- The implicit constructors now use enable_if to exclude
const-iterator => non-const-iterator conversions from overload
resolution (previously it was a compiler error on instantiation, now
it's SFINAE).
- The == and != operators are now global (friends), and are not
templated.
- MachineInstrBundleIterator has overloads to compare against both
const_pointer and const_reference. This avoids the implicit
conversions to MachineInstrBundleIterator that assert, instead just
checking the address (and I added unit tests to confirm this).
Notably, the only remaining uses of ilist_iterator::getNodePtrUnchecked
are in ilist.h, and no code outside of ilist*.h directly relies on this
UB end-iterator-to-pointer conversion anymore. It's still needed for
ilist_*sentinel_traits, but I'll clean that up soon.
llvm-svn: 278478
|
|
|
|
|
|
| |
No functionality change is intended.
llvm-svn: 278475
|
|
|
|
|
|
|
|
|
| |
If the result of the find is only used to compare against end(), just
use is_contained instead.
No functionality change is intended.
llvm-svn: 278469
|
|
|
|
|
|
|
|
|
| |
To fix PR28014, this patch restricts tail merging to blocks that belong to the
same loop after MBP.
Differential Revision: https://reviews.llvm.org/D23191
llvm-svn: 278463
|
|
|
|
|
|
| |
No functionality change is intended.
llvm-svn: 278443
|
|
|
|
|
|
|
|
|
| |
If the result of the find is only used to compare against end(), just
use is_contained instead.
No functionality change is intended.
llvm-svn: 278433
|
|
|
|
|
|
|
|
| |
It's sharing the integer G_CONSTANT for now since I don't *think* it creates
any ambiguity (even on weird archs). If that turns out wrong we can create a
G_PTRCONSTANT or something.
llvm-svn: 278423
|
|
|
|
|
|
| |
No functionality change is intended.
llvm-svn: 278417
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Check MachineInstr::isDebugValue for the same instruction as we're
calling isSchedBoundary, avoiding the possibility of dereferencing
end().
This is a functionality change even when I!=end(). Matthias had a look
and agrees this is the right resolution (as opposed to checking for
end()).
This is triggered by a huge number of tests, but they happen to
magically pass right now. I found this because WIP patches for PR26753
convert them into crashes.
llvm-svn: 278394
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D23207
llvm-svn: 278383
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Some backends, like WebAssembly, use virtual registers instead of physical registers. This crashes the DbgValueHistoryCalculator pass, which assumes that all registers are physical. Instead, skip virtual registers when iterating aliases, and assume that they are clobbered.
Reviewers: dexonsmith, dschuff, aprantl
Subscribers: yurydelendik, llvm-commits, jfb, sunfish
Differential Revision: https://reviews.llvm.org/D22590
llvm-svn: 278371
|
|
|
|
|
|
|
|
| |
This fixes PR28824.
Differential Revision: https://reviews.llvm.org/D23220
llvm-svn: 278370
|
|
|
|
|
|
| |
Differential revision: https://reviews.llvm.org/D23291
llvm-svn: 278364
|
|
|
|
|
|
|
| |
Otherwise we only materialize (shared) constants in the first function they
appear in. This doesn't go well.
llvm-svn: 278351
|