Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ycai
simbricks
Commits
ef26d5e4
Commit
ef26d5e4
authored
Sep 28, 2022
by
GAO Bin
Browse files
basicmem: copy data from request by memcpy
parent
86fda6bd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
4 deletions
+1
-4
sims/mem/basicmem/basicmem.cc
sims/mem/basicmem/basicmem.cc
+1
-4
No files found.
sims/mem/basicmem/basicmem.cc
View file @
ef26d5e4
...
@@ -157,10 +157,7 @@ void PollH2M(struct SimbricksMemIf *memif, uint64_t cur_ts) {
...
@@ -157,10 +157,7 @@ void PollH2M(struct SimbricksMemIf *memif, uint64_t cur_ts) {
addr
=
msg
->
write
.
addr
;
addr
=
msg
->
write
.
addr
;
len
=
msg
->
write
.
len
;
len
=
msg
->
write
.
len
;
data
=
msg
->
write
.
data
;
data
=
msg
->
write
.
data
;
memcpy
(
&
mem_array
[
addr
],
(
void
*
)
data
,
len
);
for
(
i
=
0
;
i
<
(
int
)
len
;
i
++
){
mem_array
[
addr
+
i
]
=
data
[
i
];
}
msg_to
=
M2HAlloc
(
memif
,
cur_ts
);
msg_to
=
M2HAlloc
(
memif
,
cur_ts
);
msg_to
->
writecomp
.
req_id
=
msg
->
write
.
req_id
;
msg_to
->
writecomp
.
req_id
=
msg
->
write
.
req_id
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment