forked from qt-creator/qt-creator
Doc: Add info about troubleshooting Performance Analyzer
Fixes: QTCREATORBUG-27707 Change-Id: Icd2c5ad8ef79ecb7a2a2e37574a269e24bf55e71 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
10
README.md
10
README.md
@@ -147,6 +147,16 @@ like Qt and LLVM, additionally run
|
||||
|
||||
cmake --install . --prefix /path/to/qtcreator_install --component Dependencies
|
||||
|
||||
### Performance Analyzer
|
||||
|
||||
If you have not installed Qt with the Maintenance Tool, you must
|
||||
either set the path to the `perfparser` executable as a value of
|
||||
the `PERFPROFILER_PARSER_FILEPATH` environment variable or copy
|
||||
the executable to from the Qt Creator installation directory to
|
||||
the build directory. That is, copy it from
|
||||
`/path/to/qtcreator_install/Tools/QtCreator/libexec/qtcreator/` to
|
||||
/path/to/qtcreator_buid/libexec/qtcreator/`.
|
||||
|
||||
## Getting LLVM/Clang for the Clang Code Model
|
||||
|
||||
The Clang code model uses `Clangd` and the ClangFormat plugin depends on the
|
||||
|
@@ -1,6 +1,6 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2021 The Qt Company Ltd.
|
||||
** Copyright (C) 2022 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of the Qt Creator documentation.
|
||||
@@ -471,14 +471,23 @@
|
||||
|
||||
The Performance Analyzer might fail to record data for the following reasons:
|
||||
|
||||
\list 1
|
||||
\li Perf events may be globally disabled on your system. The
|
||||
preconfigured \l Boot2Qt images come with perf events enabled. For
|
||||
a custom configuration you need to make sure that the file
|
||||
\list
|
||||
\li Perf events may be globally disabled on your system.
|
||||
The preconfigured \l Boot2Qt images come with perf events enabled.
|
||||
For a custom configuration you need to make sure that the file
|
||||
\c {/proc/sys/kernel/perf_event_paranoid} contains a value smaller
|
||||
than \c {2}. For maximum flexibility in recording traces you can
|
||||
set the value to \c {-1}. This allows any user to record any kind
|
||||
of trace, even using raw kernel trace points.
|
||||
|
||||
The way to enable Perf events depends on your Linux distribution.
|
||||
On some distributions, you can run the following command with
|
||||
root (or equivalent) privileges:
|
||||
|
||||
\badcode
|
||||
echo -e "kernel.perf_event_paranoid=-1\nkernel.kptr_restrict=0" | sudo tee /etc/sysctl.d/10-perf.conf
|
||||
\endcode
|
||||
|
||||
\li The connection between the target device and the host may not be
|
||||
fast enough to transfer the data produced by Perf. Try modifying
|
||||
the values of the \uicontrol {Stack snapshot size} or
|
||||
@@ -501,8 +510,21 @@
|
||||
drives the sampling from software. After the sampling has failed,
|
||||
reboot the device. The kernel may have disabled important parts of
|
||||
the performance counters system.
|
||||
\li Perf might not be installed. The way to install it depends on your
|
||||
Linux distribution. For example, you might try the following
|
||||
commands:
|
||||
|
||||
\list
|
||||
\li On Ubuntu 22.04:
|
||||
\c {sudo apt install linux-tools-$(uname -r)}
|
||||
\li On Debian:
|
||||
\c {apt install linux-perf}
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
Output from the helper program that processes the data is displayed in
|
||||
\l{Viewing Output}{General Messages}.
|
||||
|
||||
Some information is displayed in \l {Application Output} even if the
|
||||
Performance Analyzer displays error messages.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user