Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
criu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhul
criu
Commits
f6ae59cd
Commit
f6ae59cd
authored
Nov 29, 2011
by
Cyrill Gorcunov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test: Add trivial vDSO test
Signed-off-by:
Cyrill Gorcunov
<
gorcunov@gmail.com
>
parent
3d55b9d1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
0 deletions
+26
-0
Makefile
test/Makefile
+1
-0
test-vdso.c
test/test-vdso.c
+25
-0
No files found.
test/Makefile
View file @
f6ae59cd
...
@@ -3,6 +3,7 @@ SRCS += test-rnd-from-file.c
...
@@ -3,6 +3,7 @@ SRCS += test-rnd-from-file.c
SRCS
+=
test-shmem-async.c
SRCS
+=
test-shmem-async.c
SRCS
+=
test-shmem-three-async.c
SRCS
+=
test-shmem-three-async.c
SRCS
+=
test-pipe-async.c
SRCS
+=
test-pipe-async.c
SRCS
+=
test-vdso.c
SRCS-TH
+=
test-pthreads.c
SRCS-TH
+=
test-pthreads.c
OBJS-TH
+=
$
(
patsubst %.c,%.o,
$
(
SRCS-TH
))
OBJS-TH
+=
$
(
patsubst %.c,%.o,
$
(
SRCS-TH
))
...
...
test/test-vdso.c
0 → 100644
View file @
f6ae59cd
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/time.h>
#include <sys/types.h>
int
main
(
int
argc
,
char
*
argv
[])
{
int
counter
=
0
;
struct
timeval
tv
;
struct
timezone
tz
;
printf
(
"%s pid %d
\n
"
,
argv
[
0
],
getpid
());
while
(
1
)
{
gettimeofday
(
&
tv
,
&
tz
);
printf
(
"Pid: %10d time: %10li
\n
"
,
getpid
(),
tv
.
tv_sec
);
sleep
(
3
);
}
return
0
;
}
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