> For the complete documentation index, see [llms.txt](https://docs.appflowy.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.appflowy.io/docs/documentation/software-contributions/architecture/backend/profiling.md).

# Profiling

AppFlowy uses [tokio-console](https://github.com/tokio-rs/console) to debug the Rust backend. It would be very useful when having the high CPU usage issues.

## Prerequisites

Install the tokio-console by running the following command

```shell
cargo install --locked tokio-console
```

and run locally

```shell
tokio-console
```

## Enable profiling

The `flowy-core` crate has a feature called `profiling`. Just enable this feature in the cargo.toml.

### Profiling with Tauri

![img.png](/files/qLHZvnlUQ8RqeenTfouv)

The profiling data will be displayed in terminal after the application run.

![img.png](/files/MGv8E6kIRsoCq7zFsRib)

### Profiling with Flutter

Using [Xcode instruments](https://github.com/cmyr/cargo-instruments) to profile the backend.
