https://github.com/uw-pluverse/perses Skip to content Toggle navigation Sign in * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions For + Enterprise + Teams + Startups + Education By Solution + CI/CD & Automation + DevOps + DevSecOps Resources + Learning Pathways + White papers, Ebooks, Webinars + Customer Stories + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} uw-pluverse / perses Public * Notifications * Fork 17 * Star 93 language-agnostic program reducer. License GPL-3.0 license 93 stars 17 forks Activity Star Notifications * Code * Issues 8 * Pull requests 0 * Actions * Projects 0 * Security * Insights Additional navigation options * Code * Issues * Pull requests * Actions * Projects * Security * Insights uw-pluverse/perses This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. master Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags Name already in use A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch? Cancel Create 1 branch 8 tags Code * Local * Codespaces * Clone HTTPS GitHub CLI [https://github.com/u] Use Git or checkout with SVN using the web URL. [gh repo clone uw-plu] Work fast with our official CLI. Learn more about the CLI. * Open with GitHub Desktop * Download ZIP Sign In Required Please sign in to use Codespaces. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching Xcode If nothing happens, download Xcode and try again. Launching Visual Studio Code Your codespace will open once ready. There was a problem preparing your codespace, please try again. Latest commit @chengniansun chengniansun prepare for the next release ... 99e8a49 Nov 7, 2023 prepare for the next release 99e8a49 Git stats * 968 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time .github/workflows antlropt antlrrdc benchmark copyright doc ppr scripts src test/org/perses test_data third_party version .bazelrc .bazelversion .editorconfig .gitignore BUILD CONTRIBUTORS LICENSE README.md WORKSPACE perses.bzl to_be_deleted.sh View code Perses: Syntax-Directed Program Reduction Supported Languages Obtain and Run Important Flags License Reference README.md CI Perses: Syntax-Directed Program Reduction Perses is a language-agnostic program reducer to minimize a program with respect to a set of constraints. It takes as input a program to reduce, and a test script which specifies the constraints. It outputs a minimized program which still satisfies the constraints specified in the test script. Compared to Delta Debugging and Hierarchical Delta Debugging, Perses leverages the syntax information in the Antlr grammar, and prunes the search space by avoiding generating syntactically invalid programs. Supported Languages Currently, Perses supports reduction for the following programming languages: * C: [c] * Cpp: [cc, cpp, cxx] * Rust: [rs] * Scala: [scala, sc] * Java: [java] * JavaScript: [javascript, js] * Python3: [py, py3] * GLSL: [glsl, comp, frag, vert] * Go: [go] * PHP: [php] * Ruby: [rb] * SQLite: [sqlite] * MySQL: [mysql] * Solidity: [sol] * System_Verilog: [v, sv] * SMTLIBv2: [smt2] Support for other languages is coming soon. Obtain and Run There are three ways to obtain Perses. * Download a prebuilt release JAR file from our release page, for example, wget https://github.com/perses-project/perses/releases/download/v1.4/perses_deploy.jar java -jar perses_deploy.jar [options]? --test-script --input-file * Clone the repo and build Perses from the source. git clone https://github.com/perses-project/perses.git cd perses bazel build //src/org/perses:perses_deploy.jar java -jar bazel-bin/src/org/perses/perses_deploy.jar [options]? --test-script --input-file * If you want to always use the trunk version of Perses, perses-trunk automatically downloads and builds the latest version. NOTE: Bazel is the prerequisite to run perses-trunk successfully. wget https://raw.githubusercontent.com/perses-project/perses/master/scripts/perses-trunk chmod +x perses-trunk ./perses-trunk [options]? --test-script --input-file Important Flags * --test-script : The script encodes the constraints that both of the original program file and the reduced version should satisfy. It should return 0 if the constraints are satisfied. * --input-file : the program needs to be reduced. Currently, Perses supports C, Rust, Java and Go. Note that we can easily support any other languages, if the specific language can be parsed by an Antlr parser. Check all available command line arguments java -jar perses_deploy.jar --help License GNU General Public License 3. Reference Perse was first published at International Conference on Software Engineering 2018 as a full research paper. @inproceedings{perses, author = {Sun, Chengnian and Li, Yuanbo and Zhang, Qirun and Gu, Tianxiao and Su, Zhendong}, title = {Perses: Syntax-Guided Program Reduction}, year = {2018}, publisher = {Association for Computing Machinery}, doi = {10.1145/3180155.3180236}, booktitle = {Proceedings of the 40th International Conference on Software Engineering}, pages = {361-371}, } About language-agnostic program reducer. Topics gcc clang crash developer-tools compiler-bugs miscompilation program-reduction Resources Readme License GPL-3.0 license Activity Stars 93 stars Watchers 5 watching Forks 17 forks Report repository Releases 8 Perses v1.7 Latest Nov 7, 2023 + 7 releases Packages 0 No packages published Contributors 4 * * * * Languages * Rust 45.5% * C 27.0% * C++ 8.2% * Go 5.2% * Java 4.3% * Solidity 2.5% * Other 7.3% Footer (c) 2023 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact * Manage cookies * Do not share my personal information You can't perform that action at this time.