Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mockup-generator
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
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dosek-verification
mockup-generator
Commits
d7c61684
Commit
d7c61684
authored
May 9, 2017
by
Hans-Peter Deifel
Browse files
Options
Downloads
Patches
Plain Diff
Clear interrupts immediately after triggering them
parent
d79b1a83
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
files/mockup_prelude.cc
+10
-0
10 additions, 0 deletions
files/mockup_prelude.cc
src/CFG/C.hs
+1
-1
1 addition, 1 deletion
src/CFG/C.hs
with
11 additions
and
1 deletion
files/mockup_prelude.cc
+
10
−
0
View file @
d7c61684
#include
"os.h"
#include
"test/test.h"
#include
"machine.h"
#include
"arch/posix/irq.h"
#include
<stdio.h>
extern
"C"
{
...
...
@@ -8,6 +9,11 @@ extern const uint32_t _sdata_os_canonical, _edata_os_canonical;
extern
const
uint32_t
_sdata_arch_canonical
,
_edata_arch_canonical
;
}
void
do_trigger_interrupt
(
uint8_t
i
)
{
Machine
::
trigger_interrupt_from_user
(
i
);
arch
::
irq
.
clear_interrupts
();
}
// **********************************************************************
// Murmur3 implementation
//
...
...
@@ -99,6 +105,10 @@ uint32_t hash_os_state() {
return
first_hash
^
second_hash
;
}
namespace
arch
{
extern
void
*
OS_H5_ip
;
}
void
hex_os_state
()
{
const
uint8_t
*
start
=
(
const
uint8_t
*
)
&
_sdata_os_canonical
;
const
uint8_t
*
end
=
(
const
uint8_t
*
)
&
_edata_os_canonical
;
...
...
This diff is collapsed.
Click to expand it.
src/CFG/C.hs
+
1
−
1
View file @
d7c61684
...
...
@@ -101,7 +101,7 @@ triggerInterrupts (Just ints) ident = do
decision
<-
decisionNumber
return
$
" if ("
<>
decisionMaker
decision
<>
") {
\n
"
<>
"
Machine::
trigger_interrupt
_from_user
("
<>
T
.
pack
(
show
int
)
<>
");
\n
"
<>
"
do_
trigger_interrupt("
<>
T
.
pack
(
show
int
)
<>
");
\n
"
<>
" _triggeredSomeInterrupt = 1;
\n
"
<>
" "
<>
printOSState
AtBasicBlockType
ident
"__func__"
<>
";
\n
"
<>
" }
\n
"
...
...
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