{"id":15736229,"url":"https://github.com/jacksongl/semanticdiff","last_synced_at":"2025-07-17T16:03:28.915Z","repository":{"id":27422186,"uuid":"30899582","full_name":"JacksonGL/SemanticDiff","owner":"JacksonGL","description":"A project aimed at detecting inconsistency among semantic-preserving code transformations for JavaScript.","archived":false,"fork":false,"pushed_at":"2015-04-06T05:19:05.000Z","size":8836,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-31T04:18:07.534Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JacksonGL.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-17T02:40:49.000Z","updated_at":"2016-02-03T07:47:34.000Z","dependencies_parsed_at":"2022-08-07T12:16:41.189Z","dependency_job_id":null,"html_url":"https://github.com/JacksonGL/SemanticDiff","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/JacksonGL/SemanticDiff","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JacksonGL%2FSemanticDiff","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JacksonGL%2FSemanticDiff/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JacksonGL%2FSemanticDiff/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JacksonGL%2FSemanticDiff/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JacksonGL","download_url":"https://codeload.github.com/JacksonGL/SemanticDiff/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JacksonGL%2FSemanticDiff/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265625568,"owners_count":23800624,"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-10-04T01:21:35.294Z","updated_at":"2025-07-17T16:03:28.894Z","avatar_url":"https://github.com/JacksonGL.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SemanticDiff\nA research project aimed at detecting inconsistency among semantic-preserving code transformations for JavaScript.\n\n\nThis repository currently has been tested on Mac OS.\n\nInstall\n-------------------------\n\nTo run SemanticDiff you need to install jalangi2 first.\n\nInstall jalangi2\n-------------------------\n\nSee the Jalangi2 Repository here:\nhttps://github.com/Samsung/jalangi2\n\nInstall some node.js packages:\n-------------------------\n\n```\nnpm install acorn\nnpm install escodegen\nnpm install promise\nnpm install argparse\nnpm install esotope\nnpm install jsdom@3.1.2\nnpm install qunit\nnpm install phantom\nnpm install phantomjs -g\n```\n\nRun SemanticDiff on node.js\n-------------------------\n\nThe last argument specifies the target JavaScript program to be analysed.\n```\n    node ../jalangi2/src/js/commands/jalangi.js --inlineIID --inlineSource --analysis ../jalangi2/src/js/sample_analyses/ChainedAnalysesNoCheck.js --analysis src/js/analyses/lib/Utils.js --analysis src/js/analyses/traceRecorder.js tests/tiny_tests/test1.js\n```\n\nUse SemanticDiff to detect inconsistency on simple JS minimization:\n-------------------------\n\nThe last argument specifies the target JavaScript program to be analysed.\n```\n./script/genTrace.sh\n```\n\nUse of the Google Closure Compiler\n-------------------------\n\n```\njava -jar thirdParty/closure/compiler.jar --compilation_level WHITESPACE_ONLY --js_output_file tests/tiny_tests/regexp_min.js tests/tiny_tests/regexp.js\n```\n\nUseful Resources\n-------------------------\n\nDebugging JavaScript with SourceMap\n\n  https://developer.chrome.com/devtools/docs/javascript-debugging\n\n\nEvents to be observed by SemanticDiff\n-------------------------\n\n * write to global variable\n * putField on objects accessable from global name space\n * console\n * ajax\n * alert\n * modify dom\n\n\nThings that could make minimization to go wrong\n-------------------------\n\n * use of ```eval```\n * statement without semicolon at the end\n\nAlso need to handle the ```math.random``` function\n\n\nResouces concerning the Google Closure Compiler\n-------------------------\n\n[Compiler Assumptions](https://github.com/google/closure-compiler/wiki/Compiler-Assumptions)\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacksongl%2Fsemanticdiff","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjacksongl%2Fsemanticdiff","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacksongl%2Fsemanticdiff/lists"}