diff options
| author | Nikita Popov <npopov@redhat.com> | 2023-11-07 10:36:45 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-11-07 10:36:45 +0100 |
| commit | e360a16fee2dc3cb632ace556fb715832f488a90 (patch) | |
| tree | fb73a63fd58c5a8763e519b883dc08730bf56bde /lldb/unittests/ScriptInterpreter/Python/PythonTestSuite.cpp | |
| parent | ea9d44f5ec13383372b0b972fceafca881e89186 (diff) | |
| download | llvm-e360a16fee2dc3cb632ace556fb715832f488a90.zip llvm-e360a16fee2dc3cb632ace556fb715832f488a90.tar.gz llvm-e360a16fee2dc3cb632ace556fb715832f488a90.tar.bz2 | |
[GlobalOpt] Cache whether CC is changeable (#71381)
The hasAddressTaken() call in hasOnlyColdCalls() has quadratic
complexity if there are many cold calls to a function: We're going to
visit each call of the function, and then for each of them iterate all
the users of the function.
We've recently encountered a case where GlobalOpt spends more than an
hour in these hasAddressTaken() checks when full LTO is used.
Avoid this by moving the hasAddressTaken() check into hasChangeableCC()
and caching its result, so it is only computed once per function.
Diffstat (limited to 'lldb/unittests/ScriptInterpreter/Python/PythonTestSuite.cpp')
0 files changed, 0 insertions, 0 deletions
