Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle C and C++ libraries and build IR for them #105

Open
5 tasks
margnus1 opened this issue Dec 3, 2020 · 0 comments
Open
5 tasks

Bundle C and C++ libraries and build IR for them #105

margnus1 opened this issue Dec 3, 2020 · 0 comments

Comments

@margnus1
Copy link
Contributor

margnus1 commented Dec 3, 2020

Currently, in order to test C and C++ programs that use functions from the C and C++ libraries that are not inlined by the compiler, these libraries must be compiled to LLVM IR and linked to the program to be tested. In order to simplify usage of Nidhugg, we should take care of this by

  • Bundling our own versions of the C and C++ libraries
    • Headers should be installed together with Nidhugg
    • nidhuggc should ensure these libraries are on the include path
  • Building these libraries to LLVM-IR (and install the bitcode files/archives with Nidhugg)
    • These should be either loaded by default by nidhugg, or linked by default by nidhuggc

If we try to solve everything in nidhuggc, we have to consider the users that want to test larger pieces of software, and use, f.ex. wllvm to generate IR of their SUT, since nidhuggc only accepts single stand-alone source files right now.

Since Klee does the same thing, we can probably save significant effort by borrowing code from there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant