From f3c39fa63bddfca8b245144a478c379b545c2793 Mon Sep 17 00:00:00 2001 From: Philipp Schaad Date: Thu, 5 Sep 2024 16:45:44 +0200 Subject: [PATCH] SDFG Diff viewer (#161) * Add first prototype of SDFG Diff viewer * Refactoring * Diff outline * Add diff search * Mask unused features for diff view * Draw call * Cleanup and fixes * Add tests files * Add tests * Fix outline * Address some review comments * Switch to SDFGElements where possible * Test improvements * Update packages * Re-add package-lock * Remove type not supported by jsdom * Fix localview things * Fixes --- index.html | 27 + jest.config.ts | 387 +- mocks/monaco-editor.ts | 8 + package-lock.json | 5789 ++++++++++------- package.json | 4 + scss/color_schemes/default.scss | 5 + scss/sdfv.scss | 68 + src/index.ts | 1 + src/local_view/lview_renderer.ts | 22 +- src/overlay_manager.ts | 5 + src/overlays/diff_overlay.ts | 182 + src/overlays/generic_sdfg_overlay.ts | 2 +- src/renderer/canvas_manager.ts | 2 +- src/renderer/renderer.ts | 712 +- src/renderer/renderer_elements.ts | 6 +- src/sdfg_diff_viewer.ts | 752 +++ src/sdfv.ts | 1041 ++- src/sdfv_ui.ts | 258 + src/utils/bounding_box.ts | 26 +- src/utils/sdfv_settings.ts | 62 +- tests/test_graphs/gemm_expanded_pure.sdfg | 1687 +++++ .../gemm_expanded_pure_pre_0_16.sdfg | 1687 +++++ .../test_graphs/gemm_expanded_pure_tiled.sdfg | 2153 ++++++ .../state_machine/sm_layouter.test.ts | 8 +- tests/unit/sdfg_diff_viewer.test.ts | 89 + tests/unit/utils/sdfg/sdfg_utils.test.ts | 80 + 26 files changed, 11686 insertions(+), 3377 deletions(-) create mode 100644 mocks/monaco-editor.ts create mode 100644 scss/color_schemes/default.scss create mode 100644 src/overlays/diff_overlay.ts create mode 100644 src/sdfg_diff_viewer.ts create mode 100644 src/sdfv_ui.ts create mode 100644 tests/test_graphs/gemm_expanded_pure.sdfg create mode 100644 tests/test_graphs/gemm_expanded_pure_pre_0_16.sdfg create mode 100644 tests/test_graphs/gemm_expanded_pure_tiled.sdfg create mode 100644 tests/unit/sdfg_diff_viewer.test.ts create mode 100644 tests/unit/utils/sdfg/sdfg_utils.test.ts diff --git a/index.html b/index.html index 1b3cd7d9..823f79cc 100644 --- a/index.html +++ b/index.html @@ -50,10 +50,31 @@