Fangrui Song
53a62241d3
Use llvm::copy. NFC
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@347126 91177308-0d34-0410-b5e6-96231b3b80d8
2018-11-17 01:44:25 +00:00
Fangrui Song
3b35e17b21
llvm::sort(C.begin(), C.end(), ...) -> llvm::sort(C, ...)
...
Summary: The convenience wrapper in STLExtras is available since rL342102.
Reviewers: dblaikie, javed.absar, JDevlieghere, andreadb
Subscribers: MatzeB, sanjoy, arsenm, dschuff, mehdi_amini, sdardis, nemanjai, jvesely, nhaehnle, sbc100, jgravelle-google, eraman, aheejin, kbarton, JDevlieghere, javed.absar, gbedwell, jrtc27, mgrang, atanasyan, steven_wu, george.burgess.iv, dexonsmith, kristina, jsji, llvm-commits
Differential Revision: https://reviews.llvm.org/D52573
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@343163 91177308-0d34-0410-b5e6-96231b3b80d8
2018-09-27 02:13:45 +00:00
Mandeep Singh Grang
bffcc487e3
[llvm] Change 2 instances of std::sort to llvm::sort
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@337192 91177308-0d34-0410-b5e6-96231b3b80d8
2018-07-16 17:26:37 +00:00
Benjamin Kramer
fd83828e5d
Move helper classes into anonymous namespaces. NFCI.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332400 91177308-0d34-0410-b5e6-96231b3b80d8
2018-05-15 21:26:47 +00:00
Nicola Zaghen
0818e789cb
Rename DEBUG macro to LLVM_DEBUG.
...
The DEBUG() macro is very generic so it might clash with other projects.
The renaming was done as follows:
- git grep -l 'DEBUG' | xargs sed -i 's/\bDEBUG\s\?(/LLVM_DEBUG(/g'
- git diff -U0 master | ../clang/tools/clang-format/clang-format-diff.py -i -p1 -style LLVM
- Manual change to APInt
- Manually chage DOCS as regex doesn't match it.
In the transition period the DEBUG() macro is still present and aliased
to the LLVM_DEBUG() one.
Differential Revision: https://reviews.llvm.org/D43624
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332240 91177308-0d34-0410-b5e6-96231b3b80d8
2018-05-14 12:53:11 +00:00
Puyan Lotfi
0ff8dbe4d6
Fixing build bot error: adding const qualifiers to std::sort lambda.
...
Errors were not reproducible on clang-6.0 on ubuntu 16.04.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332192 91177308-0d34-0410-b5e6-96231b3b80d8
2018-05-13 06:50:55 +00:00
Puyan Lotfi
d8ca4dd711
[NFC] MIR-Canon: switching to a stable string sorting of instructions.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332191 91177308-0d34-0410-b5e6-96231b3b80d8
2018-05-13 06:07:20 +00:00
Puyan Lotfi
f1f8a6d536
[MIR-Canon] Adding ISA-Agnostic COPY Folding.
...
Transforms the following:
%vreg1234:gpr32 = COPY %42
%vreg1235:gpr32 = COPY %vreg1234
%vreg1236:gpr32 = COPY %vreg1235
$w0 = COPY %vreg1236
into:
$w0 = COPY %42
Assuming %42 is also a gpr32
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@330113 91177308-0d34-0410-b5e6-96231b3b80d8
2018-04-16 09:03:03 +00:00
Puyan Lotfi
388ad3d2f7
[NFC][MIR-Canon] clang-format cleanup of Mir Canonicalizer Pass.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@330111 91177308-0d34-0410-b5e6-96231b3b80d8
2018-04-16 08:12:15 +00:00
Puyan Lotfi
1fb4289a13
[MIR-Canon] Fixing warnings in Non-assert builds.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@329258 91177308-0d34-0410-b5e6-96231b3b80d8
2018-04-05 06:56:44 +00:00
Puyan Lotfi
a7f9b6aaad
[MIR-Canon] Improving performance by switching to named vregs.
...
No more skipping thounsands of vregs. Much faster running time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@329246 91177308-0d34-0410-b5e6-96231b3b80d8
2018-04-05 00:27:15 +00:00
Puyan Lotfi
29bc6472de
[MIR-Canon] Adding support for multi-def -> user distance reduction.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@329243 91177308-0d34-0410-b5e6-96231b3b80d8
2018-04-05 00:08:15 +00:00
Puyan Lotfi
a96b9330a2
[MIR-Canon] Adding support for local idempotent instruction hoisting.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@328915 91177308-0d34-0410-b5e6-96231b3b80d8
2018-03-31 05:48:51 +00:00
Michael Zolotukhin
41b2567ccb
Remove redundant includes from lib/CodeGen.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@320619 91177308-0d34-0410-b5e6-96231b3b80d8
2017-12-13 21:30:47 +00:00
Benjamin Kramer
9a31efbf5b
Make helpers static. NFC.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@318953 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-24 14:55:41 +00:00
David Blaikie
48319238e4
Target/TargetInstrInfo.h -> CodeGen/TargetInstrInfo.h to match layering
...
This header includes CodeGen headers, and is not, itself, included by
any Target headers, so move it into CodeGen to match the layering of its
implementation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@317647 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08 01:01:31 +00:00
Craig Topper
aaf1db11f9
[CodeGen] Remove unnecessary semicolons to fix a warning. NFC
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@317342 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03 18:02:46 +00:00
Puyan Lotfi
0ae3f32f56
mir-canon: First commit.
...
mir-canon (MIRCanonicalizerPass) is a pass designed to reorder instructions and
rename operands so that two similar programs will diff more cleanly after being
run through mir-canon than they would otherwise. This project is still a work
in progress and there are ideas still being discussed for improving diff
quality.
M include/llvm/InitializePasses.h
M lib/CodeGen/CMakeLists.txt
M lib/CodeGen/CodeGen.cpp
A lib/CodeGen/MIRCanonicalizerPass.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@317285 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-02 23:37:32 +00:00