Skip to content
Snippets Groups Projects
Commit 222e0169 authored by Per Lindgren's avatar Per Lindgren
Browse files

klee-examples

parent 543a2707
No related branches found
No related tags found
No related merge requests found
[package]
name = "klee-examples"
version = "0.1.0"
authors = ["Per Lindgren <per.lindgren@ltu.se>, Jorge Aparicio <jorge@japaric.io>"]
[dependencies]
klee = {path=".."}
[profile.release]
debug = true
panic = "abort"
lto = true
\ No newline at end of file
#![no_std]
#![no_main]
#[macro_use]
extern crate klee;
use core::ptr;
#[no_mangle]
fn main() {
let u = ksymbol!("u");
unsafe {
ptr::read_volatile(&f2(f1(u)));
}
}
// add 1 wrapping
fn f1(u: u8) -> u8 {
u.wrapping_add(1)
}
fn f2(u: u8) -> u8 {
100 / u
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment