Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
cortex-m-rtfm-klee
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Samuel Karlsson
cortex-m-rtfm-klee
Commits
0c0ea25a
Commit
0c0ea25a
authored
7 years ago
by
Samuel Karlsson
Browse files
Options
Downloads
Patches
Plain Diff
backup
parent
b65b2126
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
examples/resource.rs
+15
-2
15 additions, 2 deletions
examples/resource.rs
with
15 additions
and
2 deletions
examples/resource.rs
+
15
−
2
View file @
0c0ea25a
...
@@ -51,7 +51,7 @@ fn exti1(t: &mut Threshold, EXTI1::Resources { X, mut Y }: EXTI1::Resources) {
...
@@ -51,7 +51,7 @@ fn exti1(t: &mut Threshold, EXTI1::Resources { X, mut Y }: EXTI1::Resources) {
Y
.claim_mut
(
t1
,
|
y
,
_
|
{
Y
.claim_mut
(
t1
,
|
y
,
_
|
{
if
*
x
<
10
{
if
*
x
<
10
{
for
_
in
0
..*
x
{
for
_
in
0
..*
x
{
*
y
+
=
1
;
*
y
=
y
.wrapping_add
(
1
)
;
}
}
}
}
});
});
...
@@ -72,7 +72,7 @@ fn exti2(t: &mut Threshold, mut r: EXTI2::Resources) {
...
@@ -72,7 +72,7 @@ fn exti2(t: &mut Threshold, mut r: EXTI2::Resources) {
#[allow(non_snake_case)]
#[allow(non_snake_case)]
fn
exti3
(
t
:
&
mut
Threshold
,
mut
r
:
EXTI3
::
Resources
)
{
fn
exti3
(
t
:
&
mut
Threshold
,
mut
r
:
EXTI3
::
Resources
)
{
r
.X
.claim_mut
(
t
,
|
x
,
_
|
{
r
.X
.claim_mut
(
t
,
|
x
,
_
|
{
*
x
+
=
1
;
*
x
=
x
.wrapping_add
(
1
)
;
})
})
}
}
...
@@ -126,18 +126,27 @@ fn idle() -> ! {
...
@@ -126,18 +126,27 @@ fn idle() -> ! {
//
//
// How many tests were generated for task EXIT1?
// How many tests were generated for task EXIT1?
// ** your answer here **
// ** your answer here **
// 11
//
// Why that many, (look at the code and the generted tests).
// Why that many, (look at the code and the generted tests).
// ** your answer here **
// ** your answer here **
// one test for every lop iteration and the exstrem out sider
//
//
// How many tests were generated for task EXIT2?
// How many tests were generated for task EXIT2?
// ** your answer here **
// ** your answer here **
// 2
//
// Why that many, (look at the code and the generted tests).
// Why that many, (look at the code and the generted tests).
// ** your answer here **
// ** your answer here **
// the extreams
//
//
// How many tests were generated for task EXIT3?
// How many tests were generated for task EXIT3?
// ** your answer here **
// ** your answer here **
// 2
//
// Why that many, (look at the code and the generted tests).
// Why that many, (look at the code and the generted tests).
// ** your answer here **
// ** your answer here **
// the extreams
//
//
// (There will be one additional "dymmy" test for testing "no task".)
// (There will be one additional "dymmy" test for testing "no task".)
//
//
...
@@ -152,15 +161,19 @@ fn idle() -> ! {
...
@@ -152,15 +161,19 @@ fn idle() -> ! {
//
//
// How many errors were identified?
// How many errors were identified?
// ** your answer here **
// ** your answer here **
// 2
//
//
// For one of the arithmetic operations, no error was found.
// For one of the arithmetic operations, no error was found.
// Explain why this is no error.
// Explain why this is no error.
// ** your answer here **
// ** your answer here **
// In the exterams is the add/sub working in the right diraktion so it never wraps
//
//
// Why didn't KLEE report all the errors initially?
// Why didn't KLEE report all the errors initially?
// Scroll back and compare the stack traces of the generated errors.
// Scroll back and compare the stack traces of the generated errors.
// Hint, for each line in the code KLEE will spot ONE error.
// Hint, for each line in the code KLEE will spot ONE error.
// ** your answer here **
// ** your answer here **
// It is the some type of error and klee only finds one of a spesefick type at the time.
//
//
//
// Assignment 2.
// Assignment 2.
// KLEE has now generated tests covering EACH feasible path for EACH task.
// KLEE has now generated tests covering EACH feasible path for EACH task.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment