1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 20:23:11 +01:00
Go to file
Roman Lebedev f6c10d3f93 [SCEV] isHighCostExpansionHelper(): use correct TTI hooks
Summary:
Cost modelling strikes again.
In PR44668 <https://bugs.llvm.org/show_bug.cgi?id=44668> patch series,
i've made the same mistake of always using generic `getOperationCost()`
that i missed in reviewing D73480/D74495 which was later fixed
in 62dd44d76da9aa596fb199bda8b1e8768bb41033.

We should be using more specific hooks instead - `getCastInstrCost()`,
`getArithmeticInstrCost()`, `getCmpSelInstrCost()`.

Evidently, this does not have an effect on the existing testcases,
with unchanged default cost budget. But if it *does* have an effect
on some target, we'll have to segregate tests that use this function
per-target, much like we already do with other TTI-aware transform tests.

There's also an issue that @samparker has brought up in post-commit-review:
>>! In D73501#1905171, @samparker wrote:
> Hi,
> Did you get performance numbers for these patches? We track the performance
> of our (Arm) open source DSP library and the cost model fixes were generally
> a notable improvement, so many thanks for that! But the final patch
> for rewriting exit values has generally been bad, especially considering
> the gains from the modelling improvements. I need to look into it further,
> but on my current test case I'm seeing +30% increase in stack accesses
> with a similar decrease in performance.
> I'm just wondering if you observed any negative effects yourself?

I don't know if this addresses that, or we need D66450 for that.

Reviewers: samparker, spatel, mkazantsev, reames, wmi

Reviewed By: reames

Subscribers: kristof.beyls, hiraditya, danielkiss, llvm-commits, samparker

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D75908
2020-03-12 11:33:38 +03:00
benchmarks
bindings Add an SDK attribute to DICompileUnit 2020-03-11 14:14:06 -07:00
cmake [clang][cmake] Include generated rst files in html built by docs-clang-html target 2020-03-05 21:30:37 -08:00
docs Fix internal links in Kaleidoscope tutorial 2020-03-09 15:07:44 -06:00
examples Add missing "llvm/Support/Host.h" header to LLVM example after recent header trimming (NFC) 2020-03-12 00:12:03 +00:00
include [X86] Reduce the number of emitted fragments due to branch align 2020-03-12 15:37:35 +08:00
lib [SCEV] isHighCostExpansionHelper(): use correct TTI hooks 2020-03-12 11:33:38 +03:00
projects
resources
runtimes [runtimes] When COMPILER_RT is enabled, consider SANITIZER prefixes 2020-03-11 14:22:20 -07:00
test [ExpandMemCmp][NFC] Add more tests. 2020-03-12 08:49:51 +01:00
tools [llvm-jitlink] Fix DEBUG_TYPE string. 2020-03-11 20:04:54 -07:00
unittests [GlobalISel] fix crash in narrowScalarExtract if DstRegs only has one register 2020-03-12 09:14:35 +01:00
utils [gn build] Port 518292dbdfc 2020-03-12 05:17:52 +00:00
.clang-format
.clang-tidy - Update .clang-tidy to ignore parameters of main like functions for naming violations in clang and llvm directory 2020-01-31 16:49:45 +00:00
.gitattributes
.gitignore Continue removing llgo. 2020-02-10 10:33:58 -08:00
CMakeLists.txt Revert "[AVR] Include AVR by default in LLVM builds" 2020-03-12 19:53:46 +13:00
CODE_OWNERS.TXT Remove myself from CODE_OWNERS. 2020-02-25 11:59:29 +00:00
configure
CREDITS.TXT
LICENSE.TXT
llvm.spec.in
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.