polyphony 0.83 → 0.84
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitmodules +3 -0
- data/CHANGELOG.md +6 -0
- data/Gemfile.lock +1 -1
- data/Rakefile +14 -0
- data/ext/polyphony/backend_io_uring.c +42 -6
- data/ext/polyphony/backend_libev.c +45 -0
- data/ext/polyphony/extconf.rb +17 -0
- data/ext/polyphony/polyphony.c +5 -0
- data/ext/polyphony/polyphony.h +1 -0
- data/lib/polyphony/extensions/io.rb +10 -0
- data/lib/polyphony/extensions/pipe.rb +4 -0
- data/lib/polyphony/version.rb +1 -1
- data/test/test_io.rb +60 -1
- metadata +2 -13
- data/ext/liburing/liburing/README.md +0 -4
- data/ext/liburing/liburing/barrier.h +0 -73
- data/ext/liburing/liburing/compat.h +0 -15
- data/ext/liburing/liburing/io_uring.h +0 -343
- data/ext/liburing/liburing.h +0 -585
- data/ext/liburing/queue.c +0 -333
- data/ext/liburing/register.c +0 -187
- data/ext/liburing/setup.c +0 -210
- data/ext/liburing/syscall.c +0 -54
- data/ext/liburing/syscall.h +0 -18
- data/ext/polyphony/liburing.c +0 -8
data/ext/liburing/syscall.c
DELETED
@@ -1,54 +0,0 @@
|
|
1
|
-
/* SPDX-License-Identifier: MIT */
|
2
|
-
/*
|
3
|
-
* Will go away once libc support is there
|
4
|
-
*/
|
5
|
-
#include <unistd.h>
|
6
|
-
#include <sys/syscall.h>
|
7
|
-
#include <sys/uio.h>
|
8
|
-
#include "liburing/compat.h"
|
9
|
-
#include "liburing/io_uring.h"
|
10
|
-
#include "syscall.h"
|
11
|
-
|
12
|
-
#ifdef __alpha__
|
13
|
-
/*
|
14
|
-
* alpha is the only exception, all other architectures
|
15
|
-
* have common numbers for new system calls.
|
16
|
-
*/
|
17
|
-
# ifndef __NR_io_uring_setup
|
18
|
-
# define __NR_io_uring_setup 535
|
19
|
-
# endif
|
20
|
-
# ifndef __NR_io_uring_enter
|
21
|
-
# define __NR_io_uring_enter 536
|
22
|
-
# endif
|
23
|
-
# ifndef __NR_io_uring_register
|
24
|
-
# define __NR_io_uring_register 537
|
25
|
-
# endif
|
26
|
-
#else /* !__alpha__ */
|
27
|
-
# ifndef __NR_io_uring_setup
|
28
|
-
# define __NR_io_uring_setup 425
|
29
|
-
# endif
|
30
|
-
# ifndef __NR_io_uring_enter
|
31
|
-
# define __NR_io_uring_enter 426
|
32
|
-
# endif
|
33
|
-
# ifndef __NR_io_uring_register
|
34
|
-
# define __NR_io_uring_register 427
|
35
|
-
# endif
|
36
|
-
#endif
|
37
|
-
|
38
|
-
int __sys_io_uring_register(int fd, unsigned opcode, const void *arg,
|
39
|
-
unsigned nr_args)
|
40
|
-
{
|
41
|
-
return syscall(__NR_io_uring_register, fd, opcode, arg, nr_args);
|
42
|
-
}
|
43
|
-
|
44
|
-
int __sys_io_uring_setup(unsigned entries, struct io_uring_params *p)
|
45
|
-
{
|
46
|
-
return syscall(__NR_io_uring_setup, entries, p);
|
47
|
-
}
|
48
|
-
|
49
|
-
int __sys_io_uring_enter(int fd, unsigned to_submit, unsigned min_complete,
|
50
|
-
unsigned flags, sigset_t *sig)
|
51
|
-
{
|
52
|
-
return syscall(__NR_io_uring_enter, fd, to_submit, min_complete,
|
53
|
-
flags, sig, _NSIG / 8);
|
54
|
-
}
|
data/ext/liburing/syscall.h
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
/* SPDX-License-Identifier: MIT */
|
2
|
-
#ifndef LIBURING_SYSCALL_H
|
3
|
-
#define LIBURING_SYSCALL_H
|
4
|
-
|
5
|
-
#include <signal.h>
|
6
|
-
|
7
|
-
struct io_uring_params;
|
8
|
-
|
9
|
-
/*
|
10
|
-
* System calls
|
11
|
-
*/
|
12
|
-
extern int __sys_io_uring_setup(unsigned entries, struct io_uring_params *p);
|
13
|
-
extern int __sys_io_uring_enter(int fd, unsigned to_submit,
|
14
|
-
unsigned min_complete, unsigned flags, sigset_t *sig);
|
15
|
-
extern int __sys_io_uring_register(int fd, unsigned int opcode, const void *arg,
|
16
|
-
unsigned int nr_args);
|
17
|
-
|
18
|
-
#endif
|