{"id":23421994,"url":"https://github.com/sdasgup3/symbolic-analysis","last_synced_at":"2025-04-12T14:14:18.005Z","repository":{"id":20181070,"uuid":"23452040","full_name":"sdasgup3/symbolic-analysis","owner":"sdasgup3","description":"Customized symbolic analysis to find pointer analysis bugs","archived":false,"fork":false,"pushed_at":"2015-11-02T23:33:28.000Z","size":80536,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":4,"default_branch":"f_pachecks","last_synced_at":"2025-03-26T08:51:33.445Z","etag":null,"topics":["c-plus-plus","checker","debugger","klee","llvm","pointer-analysis","symbolic-analysis"],"latest_commit_sha":null,"homepage":null,"language":"C++","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/sdasgup3.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":"2014-08-29T04:01:46.000Z","updated_at":"2023-01-08T14:45:04.000Z","dependencies_parsed_at":"2022-09-02T20:11:03.352Z","dependency_job_id":null,"html_url":"https://github.com/sdasgup3/symbolic-analysis","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/sdasgup3%2Fsymbolic-analysis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdasgup3%2Fsymbolic-analysis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdasgup3%2Fsymbolic-analysis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdasgup3%2Fsymbolic-analysis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sdasgup3","download_url":"https://codeload.github.com/sdasgup3/symbolic-analysis/tar.gz/refs/heads/f_pachecks","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248578824,"owners_count":21127713,"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":["c-plus-plus","checker","debugger","klee","llvm","pointer-analysis","symbolic-analysis"],"created_at":"2024-12-23T02:25:38.649Z","updated_at":"2025-04-12T14:14:17.977Z","avatar_url":"https://github.com/sdasgup3.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"Build zesti/klee http://klee.github.io/getting-started/\n=================================================================\n\n```\nsudo yum install g++ curl dejagnu subversion bison flex bc libcap-devel\nexport PATH=$PATH:/home/sdasgup3/llvm/llvm-gcc4.2-2.9-x86_64-linux/bin/\n/*To Find the tarball @\nhttp://llvm.org/releases/2.9/llvm-gcc4.2-2.9-x86_64-linux.tar.bz2\n*/\n```\n\nBuild llvm 2.9\n-----------------\n```\ntar zxvf llvm-2.9.tgz\ncd llvm-2.9\n./configure --enable-optimized --enable-assertions\nmake\n```\n\nBuild stp\n----------------\n```\ntar xzfv stp-r940.tgz /*Find the tarball http://www.doc.ic.ac.uk/~cristic/klee/stp.html */\ncd stp-r940\n./scripts/configure --with-prefix=`pwd`/install --with-cryptominisat2\nmake OPTIMIZE=-O2 CFLAGS_M32= install\nulimit -s unlimited\n```\n\nBuild uclibc\n----------------\n```\ngit clone --depth 1 --branch klee_0_9_29 https://github.com/ccadar/klee-uclibc.git\n/*\nIn case u want to do some dev oin uclibc then use the following:\ngit clone --branch klee_0_9_29 https://github.com/ccadar/klee-uclibc.git\n*/\ncd klee-uclibc/\nexport PATH=$PATH:/home/sdasgup3/llvm/llvm-2.9/Release+Asserts/bin/\n/* or\nexport PATH=$PATH:/home/sdasgup3/llvm/llvm-3.4.2/llvm-build/Release+Asserts/bin/\nmodule load gcc\n*/\n./configure -l  \n/*  \n./configure --make-llvm-lib\nhttps://github.com/klee/klee-uclibc/wiki/Getting-started\n*/\nmake -j2\n```\nBuild llvmpa\n---------------\n```\nsetenv LD_LIBRARY_PATH /software/gcc-4.8.2/lib64:/software/gcc-4.8.2/lib:/usr/lib64\nmodule load gcc\n../llvmpa/configure --with-llvmsrc=/home/sdasgup3/llvm/llvm-3.4.2/llvm-src/ --with-llvmobj=/home/sdasgup3/llvm/llvm-3.4.2/llvm-build --with-gcc-toolchain=/software/gcc-4.8.2 --with-extra-options=-std=c++11 --with-extra-ld-options=\"-Wl,-rpath,/software/gcc-4.8.2/lib64\" --enable-optimized --enable-assertions\nmake\n```\n\nBuild poolalloc\n---------------\n```\n../SymbolicAnalysis/poolalloc/configure --with-llvmsrc=/home/kasampa2/Documents/llvm/llvm.src --with-llvmobj=/home/kasampa2/Documents/llvm/llvm.obj --with-gcc-toolchain=/home/kasampa2/Documents/gcc/gcc-4.8.2.inst --with-extra-options=-std=c++11 --with-extra-ld-options=-Wl,-rpath,/home/kasampa2/Documents/gcc/gcc-4.8.2.inst/lib64 --disable-optimized --enable-assertions\n\nmake CXXFLAGS+=-std=c++11 ENABLE_OPTIMIZED=1\n```\n\nBuild klee/zesti\n--------------\n```\ngit clone https://github.com/ccadar/klee.git //for klee\ntar -xvf zesti.tar.gz\ncd klee/zesti\n./configure --with-llvm=/home/sdasgup3/llvm/llvm-2.9/ --with-stp=/home/sdasgup3/klee/stp-r940/install/ --with-uclibc=/home/sdasgup3/klee/klee-uclibc/ --enable-posix-runtime\n\n/*\nor\n./configure --with-llvmsrc=/home/sdasgup3/llvm/llvm-3.4.2/llvm-src/ --with-llvmobj=/home/sdasgup3/llvm/llvm-3.4.2/llvm-build/ --with-stp=/home/sdasgup3/SymbolicAnalysis/stp-r940/install/ --with-uclibc=/home/sdasgup3/SymbolicAnalysis/klee-uclibc/ --enable-posix-runtime\n*/\n\nWhen building zesti add these options to configure to help it find llvmpa:\n--with-llvmpasrc=/path/to/llvmpa/src/tree\n--with-llvmpaobj=/path/to/llvmpa/obj/tree\nEx:\n./configure --with-llvmsrc=/home/sdasgup3/llvm/llvm-3.4.2/llvm-src/ --with-llvmobj=/home/sdasgup3/llvm/llvm-3.4.2/llvm-build/ --with-stp=/home/sdasgup3/zesti_utils//stp-r940/install/ --with-uclibc=/home/sdasgup3/zesti_utils/klee-uclibc/ --with-llvmpasrc=/home/sdasgup3/llvmpa/ --with-llvmpaobj=/home/sdasgup3/llvmpa-build/ --enable-posix-runtime\n\nAlso, add these options to configure to help it find poolalloc:\n--with-poolallocsrc=/path/to/poolalloc/src/tree\n--with-poolallocobj=/path/to/poolalloc/obj/tree\n\n/* In case stuck in problems\nsudo ln -s /usr/include/x86_64-linux-gnu/asm/ /usr/include/asm\nIn case of prblms like C compiler not working\nsudo apt-get remove gcc\nsudo apt-get install gcc\nsudo apt-get install g++\n*/\nmake ENABLE_OPTIMIZED=1 \nmake check  //optional\nmake unittests  //optional\n```\n\nRunning Testcase with checker\n-----------------------------\n\n```\n// The detailed commands can be viewed from Scripts/build.pl. Also find the Makefiles required from Scripts folder.\n\nmake clean\nmake $test LLVM_BIN=$llvm_bin_3_4 LLVMPALIB=$llvmpalib KLEEINCLUDE=$kleeincl\nmake $test-kleecheck LLVM_BIN=$llvm_bin_3_4 LLVMPALIB=$llvmpalib\ncat $test-kleecheck.ll | sed 's/target datalayout.*//' | sed 's/\\!llvm.ident =.*//' | sed 's/\\!0 = metadata.*//' | sed 's/^attributes \\#[0-9]*.*//' | sed 's/\\#[0-9][0-9]*//' \u003e  temp\nmv temp $test-kleecheck.ll\n$clang2_9 -emit-llvm -c $SCRIPTDIR/jf_checker_map.cpp -I $SCRIPTDIR -o jf_checker_map.bc\n$llvmas2_9 \u003c $test-kleecheck.ll  \u003e a.bc\n$llvmld2_9 -disable-opt a.bc  jf_checker_map.bc\n$llvmdis2_9 \u003c a.out.bc  \u003e a.out.ll\ncp a.out.bc $test.a.out.bc\nzesti --zest --zest-depth-offset=$offset  --use-symbex=2 --symbex-for=10 --search=zest --zest-search-heuristic=br --zest-discard-far-states=false  ./$test.a.out.bc\n```\n\nRunning withOUT checker (the llvm used must be compatible with klee build)\n--------------------\n```\n/home/sdasgup3/llvm/llvm-3.4.2/llvm-build//Release+Asserts/bin/clang -O0 -emit-llvm -I /home/sdasgup3/SymbolicAnalysis/zesti//include/klee -I ./ -c zesti_test_6.c -o zesti_test_6.a.out.bc \n/home/sdasgup3/llvm/llvm-3.4.2/llvm-build//Release+Asserts/bin/llvm-dis zesti_test_6.a.out.bc -o a.out.ll \n/home/sdasgup3/SymbolicAnalysis/zesti//Release+Asserts/bin/klee  --zest      -debug-print-instructions         --use-symbex=2 --symbex-for=10 --search=zest --zest-search-heuristic=br --zest-discard-far-states=false ./zesti_test_6.a.out.bc\n```\n\nBuild libffi used for running lli\n-----------------------------------\n```\nFollow the steps in http://www.linuxfromscratch.org/blfs/view/svn/general/libffi.html\nto install libffi and then\n1. export CPPFLAGS='-I/pathto/libffiinckude/'\n2. export LDFLAGS='-L/pathto/libffilibs/'\n3. export LD_LIBRARY_PATH to  point to the libffi libs\nrun confugure and make llvm\n\n\n\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdasgup3%2Fsymbolic-analysis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsdasgup3%2Fsymbolic-analysis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdasgup3%2Fsymbolic-analysis/lists"}