Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
cs24-21fa
project05b
Commits
d5516792
Commit
d5516792
authored
4 years ago
by
Caleb C. Sander
Browse files
Options
Download
Email Patches
Plain Diff
Remove unused includes
parent
35ec9484
master
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/index_guesser.c
+4
-8
src/index_guesser.c
with
4 additions
and
8 deletions
+4
-8
src/index_guesser.c
View file @
d5516792
#include <inttypes.h>
#include <stdbool.h>
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "util.h"
...
...
@@ -13,7 +9,7 @@
const
uint64_t
MIN_CHOICE
=
1
;
const
uint64_t
MAX_CHOICE
=
256
;
static
inline
page_t
*
init_pages
()
{
static
inline
page_t
*
init_pages
(
void
)
{
return
calloc
(
MAX_CHOICE
,
sizeof
(
page_t
));
}
...
...
@@ -22,7 +18,7 @@ static inline void flush_all_pages(page_t *pages) {
}
static
inline
size_t
guess_accessed_page
(
page_t
*
pages
)
{
// TODO: Implement me!
// TODO: Implement me!
return
0
;
}
...
...
@@ -33,9 +29,9 @@ int main() {
flush_all_pages
(
pages
);
do_access
(
pages
);
size_t
guess
=
guess_accessed_page
(
pages
);
if
(
guess
)
{
if
(
guess
>
0
)
{
printf
(
"%zu
\n
"
,
guess
);
}
}
This diff is collapsed.
Click to expand it.
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
Menu
Projects
Groups
Snippets
Help