8138cdc3d9
Build: split Dart debug info out of libapp.so (13.96 -> 11.27 MB, symbols kept in the cache) and fix icon tree shaking, which Flutter 3.44's Linux CMake backend silently disables by quoting the define; the build image patches its SDK copy (MaterialIcons 1.6 MB -> 25 KB). Impeller cannot be enabled in a Linux release build and was slower in a profile-build bench. Install: `./install --linux --install` installs the bundle into <prefix>/lib/app-linux with com.pipelines.app.desktop (the GTK/Wayland app id), its icon and a ~/.local/bin/pipelines-app link, through scripts/install-linux-app.sh. Linux gaps: notifications through the freedesktop daemon; HTML artifacts explain the missing web view instead of throwing; no Share for files; a GTK clipboard reader for pasting files and screenshots (Ctrl+V and Omarchy's Super+V); GTK header bar only on GNOME; window icon. Bench: native fixture frame log, wheel/mark steps and tool/perf/linux_desktop_bench.py (private Xvfb); results in app/notes/linux-desktop-optimized.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
29 lines
1.1 KiB
Dart
29 lines
1.1 KiB
Dart
// Frame report for native fixture builds (the Linux desktop bench,
|
|
// tool/perf/linux_desktop_bench.py), the native twin of frame_log.dart.
|
|
//
|
|
// With `perf=1` in FIXTURE_QUERY it prints every frame's Flutter timings as
|
|
// `PERF_FRAME <build us> <raster us> <total us>`, and the first rasterised
|
|
// frame as `PERF_FIRST_FRAME_EPOCH <ms since the Unix epoch>`, which the
|
|
// bench subtracts from its own launch time. Without the flag nothing is
|
|
// installed.
|
|
import 'package:flutter/widgets.dart';
|
|
|
|
void installNativeFrameLog(Map<String, String> params) {
|
|
if (params['perf'] != '1') return;
|
|
final binding = WidgetsFlutterBinding.ensureInitialized();
|
|
binding.addTimingsCallback((timings) {
|
|
for (final timing in timings) {
|
|
// ignore: avoid_print
|
|
print(
|
|
'PERF_FRAME ${timing.buildDuration.inMicroseconds} '
|
|
'${timing.rasterDuration.inMicroseconds} '
|
|
'${timing.totalSpan.inMicroseconds}',
|
|
);
|
|
}
|
|
});
|
|
binding.waitUntilFirstFrameRasterized.then((_) {
|
|
// ignore: avoid_print
|
|
print('PERF_FIRST_FRAME_EPOCH ${DateTime.now().millisecondsSinceEpoch}');
|
|
});
|
|
}
|