{"id":13648499,"url":"https://github.com/ThePerfectComputer/FastWaveBackend","last_synced_at":"2025-04-22T11:32:50.123Z","repository":{"id":46824900,"uuid":"481469062","full_name":"ThePerfectComputer/FastWaveBackend","owner":"ThePerfectComputer","description":"A Rust VCD parser intended to be the backend of a Waveform Viewer(built using egui) that supports dynamically loaded rust plugins.","archived":true,"fork":false,"pushed_at":"2024-12-30T23:32:49.000Z","size":9816,"stargazers_count":43,"open_issues_count":10,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-21T14:58:47.033Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ThePerfectComputer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-GPLV3","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-14T04:48:28.000Z","updated_at":"2025-03-12T07:33:49.000Z","dependencies_parsed_at":"2023-10-23T16:00:06.841Z","dependency_job_id":"8206c8fa-b9db-480e-b343-4d855e49a2d6","html_url":"https://github.com/ThePerfectComputer/FastWaveBackend","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThePerfectComputer%2FFastWaveBackend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThePerfectComputer%2FFastWaveBackend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThePerfectComputer%2FFastWaveBackend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ThePerfectComputer%2FFastWaveBackend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ThePerfectComputer","download_url":"https://codeload.github.com/ThePerfectComputer/FastWaveBackend/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250232387,"owners_count":21396631,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T01:04:18.523Z","updated_at":"2025-04-22T11:32:50.082Z","avatar_url":"https://github.com/ThePerfectComputer.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# Migrating !!!\n\nThis codebase has now been migrated to https://git.joyofhardware.com/Yehowshua/FastWaveBackend\n\nCopyright(2023) - Yehowshua Immanuel\n\n# Vision\nImagine being able to visualize a CPU pipeline diagram by merely loading a simulation waveform dump, sprinkling in a bit of code, and dragging and dropping some diagram blocks into the visualizer. This project aims to offer such an experience.\n\nSince this project is written in Rust, it should also be able to run in the browser via web-assembly.\n\n# Status\nAs of January 2024, work on the Fastwave Backend is stalled. It has been a fun journey watching Fastwave enable the first iterations of the [surfer waveform viewer](https://surfer-project.org). Now surfer uses an even better backend called [Wellen](https://github.com/ekiwi/wellen?tab=readme-ov-file). Go check it out! I hear it's really good. Perhaps I will soon archive the Fastwave Backend.\n\nBrowser demo: https://app.surfer-project.org/\n\nScreenshot of surfer frontend below:\n\u003cimg width=\"1609\" alt=\"image\" src=\"https://github.com/ThePerfectComputer/FastWaveBackend/assets/103011002/63deffc0-98b0-405f-b093-74d10b422b01\"\u003e\n\n# A High performance, VCD Parser written in Rust\n\nI hope for a GUI that eventually looks like the following...\n\n![](assets/FastWaveMockup.png)\n\n# Current Features\n\n - Robust Error Handling\n   \n   FastWave currently offers highly robust error handling(at least on the sample \n   VCD files in this repository) which GTKWave doesn't have. For\n   example, selecting the ``UTILIZATON_ENABLED`` signal after opening \n   [test2x2_regex22_string1.vcd](./test-vcd-files/xilinx_isim/test2x2_regex22_string1.vcd)\n   (one of the sample xilinx vcd test files) in GtkWave, will crash GtkWave since\n   this signal is malformed. FastWave on the otherhand simply notes that the\n   signal is malformed.\n\n# Performance\n\n## Methods\nI have been testing performance on a 3.04GB VCD file that can be found \n[here](https://drive.google.com/file/d/1pfm2qo2l8fGTHHJ8TLrg1vSGaV_TUbp2/view?usp=sharing).\n\nFor getting the GtkWave results, I fired up GtkWave, clicked on \n``File``-\u003e``Open New Window``, and selected the VCD file linked to above.\nI started my stopwatch as soon as I pressed enter to beging loading the VCD\nfile, and stopped my stopwatch once the GtkWave titlebar reached 100%.\n   \nTo get the memory consumption, I opened Activity Monitor on Mac, and recorded\nthe GtkWave memory usage before and after loading the large VCD file, and \ntook the difference.\n\nI noticed that when running FastWave in the VsCode terminal as opposed\nto the MacOS system terminal or the Lapce terminal, FastWave is notably\nslower.\n\n## Results\n\nLZ4 should really improve memory usage once I add it. Note that GTKWave uses LZ4 on the fly.\n\n| Software | Time(s) | Memory(MB) |\n|----------|---------|------------|\n| FastWave | ~27.30  | 1100+      |\n| GtkWave  | ~30     | 89.8       |\n\n\n# Current Limitations\nUnable to handle VCD files that have signals with more than \n2^32 - 1 = 4,294,967,295 deltas/changes.\n\n# Running\n\nThis repository comes with several smaller VCD files emitted from\nvarious EDA tools. If you want a larger VCD file, grab one from\n[here](https://drive.google.com/file/d/1pfm2qo2l8fGTHHJ8TLrg1vSGaV_TUbp2/view?usp=sharing).\n\nHere are some examples you can run:\nThe first build of the program may take some time.\n\n1. ``cargo run --release --example parse_vcd tests/vcd-files/aldec/SPI_Write.vcd``\n2. ``cargo run --release --example vcd``\n\nYou can run all the tests with ``cargo test``\n\n# Testing on Bad Files\nYou may wish to test the parser on a malformed VCD just to make\nsure that the parser gives useful/sane errors.\n\nHere's a command to test on a malformed VCD:\n``cargo run --release --example parse_vcd tests/vcd-files/VCD_file_with_errors.vcd``\n\n\n# TODO\n\n## Features and Other\n - [ ] add documenting comments\n - [ ] make signal query private until later?\n - [ ] add signal query code to example once interface is finalized\n - [ ] change crate name to vcd_fast_parse\n - [ ] perhaps we should be looking up signal values on the VCD class\n - [ ] perhaps we should be returning signal trees from the VCD class\n - [ ] add lz4 compression support and compare memory perf before and after\n       - [ ] may need to refactor with allow for get_mut for dynamic\n             compression-decompression for multiple signal structs \n             at once to allow for multi-threading\n - [ ] test against large waveforms from the\n       [verilog-vcd-parser](https://github.com/ben-marshall/verilog-vcd-parser)\n       tool\n - [ ] (a bit of work) consolidate error messages in validation phase\n - [ ] once the access patterns of the GUI frontend are well understood,\n       create specific functions and restrict as many types to private\n       as possible\n - [ ] Print out git commit or release number.\n - [ ] do a read through all the code - look for uneeded code\n - [ ] Move part of the performance section to another markdown file.\n\n## Repairs\n - [ ] replace str bracket indices with get(slice)\n - [ ] make a custom date parser for possibly up to 18 different versions(that is, for each possible tool).\n - [ ] Consolidate error messages and add cursors throughout.\n - [ ] Add file and line to the enum errors.\n - [ ] Fix warnings especially usage and restriction warnings once I'm\n       able to successfully parse all sample VCDs.\n\n## Code Consistency\n - [ ] Change error messages to line and filenames. Go through all calls to unwrap.\n   - [ ] search for any unwraps or any direct vectors indexing\n - [ ] Handle TODOs\n - [ ] Remove debug code/comments.\n\n## Documentation\n - [ ] Document indexing structure with diagram and possibly include the rational\n\n## Marketing\n - [ ] Send survey to community \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThePerfectComputer%2FFastWaveBackend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FThePerfectComputer%2FFastWaveBackend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThePerfectComputer%2FFastWaveBackend/lists"}