Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
LARN
PRRT
Commits
a6ba8861
Commit
a6ba8861
authored
Jun 19, 2019
by
Andreas Schmidt
Browse files
+= expose additional paces via Cython
parent
4e8f2461
Pipeline
#3756
failed with stages
in 2 minutes and 11 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
prrt/proto/bbr.c
View file @
a6ba8861
...
...
@@ -476,4 +476,4 @@ prrtByteCount_t BBR_getSendQuantum(BBR* bbr) {
error:
PERROR
(
"BBR_getSendQuantum failed."
)
return
0
;
}
\ No newline at end of file
}
prrt/proto/bbr.h
View file @
a6ba8861
...
...
@@ -12,7 +12,7 @@
#define PROBE_GAIN 1.1
#define DRAIN_GAIN 0.9
#define RTpropFilterLen
10
000000 //10s
#define RTpropFilterLen
2
000000 //10s
#define BBRHighGain ((((float)2885) / 1000) + 1)
#define BBRGainCycleLen 8
#define ProbeRTTDuration 200000 //200ms
...
...
prrt/proto/socket.c
View file @
a6ba8861
...
...
@@ -571,8 +571,8 @@ uint32_t PrrtSocket_get_sock_opt(PrrtSocket *s, const char *name) {
}
else
if
(
strcmp
(
name
,
"appSend_pace_effective"
)
==
0
)
{
return
PrrtPace_get_effective
(
s
->
appSendPace
);
}
else
if
(
strcmp
(
name
,
"appSend_pace_total"
)
==
0
)
{
return
PrrtPace_get_total
(
s
->
appSendPace
);
return
PrrtPace_get_total
(
s
->
appSendPace
);
}
else
if
(
strcmp
(
name
,
"prrtTransmit_pace_internal"
)
==
0
)
{
return
PrrtPace_get_internal
(
s
->
prrtTransmitPace
);
}
else
if
(
strcmp
(
name
,
"prrtTransmit_pace_dependent"
)
==
0
)
{
...
...
@@ -582,8 +582,8 @@ uint32_t PrrtSocket_get_sock_opt(PrrtSocket *s, const char *name) {
}
else
if
(
strcmp
(
name
,
"prrtTransmit_pace_effective"
)
==
0
)
{
return
PrrtPace_get_effective
(
s
->
prrtTransmitPace
);
}
else
if
(
strcmp
(
name
,
"prrtTransmit_pace_total"
)
==
0
)
{
return
PrrtPace_get_total
(
s
->
prrtTransmitPace
);
return
PrrtPace_get_total
(
s
->
prrtTransmitPace
);
}
else
if
(
strcmp
(
name
,
"prrtReceive_pace_internal"
)
==
0
)
{
return
PrrtPace_get_internal
(
s
->
prrtReceivePace
);
}
else
if
(
strcmp
(
name
,
"prrtReceive_pace_dependent"
)
==
0
)
{
...
...
@@ -593,8 +593,8 @@ uint32_t PrrtSocket_get_sock_opt(PrrtSocket *s, const char *name) {
}
else
if
(
strcmp
(
name
,
"prrtReceive_pace_effective"
)
==
0
)
{
return
PrrtPace_get_effective
(
s
->
prrtReceivePace
);
}
else
if
(
strcmp
(
name
,
"prrtReceive_pace_total"
)
==
0
)
{
return
PrrtPace_get_total
(
s
->
prrtReceivePace
);
return
PrrtPace_get_total
(
s
->
prrtReceivePace
);
}
else
if
(
strcmp
(
name
,
"appDeliver_pace_internal"
)
==
0
)
{
return
PrrtPace_get_internal
(
s
->
appDeliverPace
);
}
else
if
(
strcmp
(
name
,
"appDeliver_pace_dependent"
)
==
0
)
{
...
...
@@ -604,8 +604,8 @@ uint32_t PrrtSocket_get_sock_opt(PrrtSocket *s, const char *name) {
}
else
if
(
strcmp
(
name
,
"appDeliver_pace_effective"
)
==
0
)
{
return
PrrtPace_get_effective
(
s
->
appDeliverPace
);
}
else
if
(
strcmp
(
name
,
"appDeliver_pace_total"
)
==
0
)
{
return
PrrtPace_get_total
(
s
->
appDeliverPace
);
return
PrrtPace_get_total
(
s
->
appDeliverPace
);
}
else
if
(
strcmp
(
name
,
"send_peer_btl_pace"
)
==
0
)
{
return
s
->
send_peer_btl_pace
;
}
else
if
(
strcmp
(
name
,
"recv_peer_btl_pace"
)
==
0
)
{
...
...
prrt/prrt.pyx
View file @
a6ba8861
...
...
@@ -161,11 +161,13 @@ class PrrtPace:
return
self
.
internal
+
self
.
external
-
self
.
dependent
class
PrrtPaces
:
def
__init__
(
self
,
appSend
,
prrtTransmit
,
prrtReceive
,
appDeliver
):
def
__init__
(
self
,
appSend
,
prrtTransmit
,
prrtReceive
,
appDeliver
,
peerPace
,
networkPace
):
self
.
appSend
=
appSend
self
.
prrtTransmit
=
prrtTransmit
self
.
prrtReceive
=
prrtReceive
self
.
appDeliver
=
appDeliver
self
.
peerPace
=
peerPace
self
.
networkPace
=
networkPace
cdef
class
PrrtSocket
:
cdef
cprrt
.
PrrtSocket
*
_c_socket
...
...
@@ -238,7 +240,10 @@ cdef class PrrtSocket:
cprrt
.
PrrtSocket_get_sock_opt
(
self
.
_c_socket
,
"appDeliver_pace_dependent"
)
*
0.000001
,
cprrt
.
PrrtSocket_get_sock_opt
(
self
.
_c_socket
,
"appDeliver_pace_external"
)
*
0.000001
)
return
PrrtPaces
(
appSend
,
prrtTransmit
,
prrtReceive
,
appDeliver
)
peerPace
=
cprrt
.
PrrtSocket_get_sock_opt
(
self
.
_c_socket
,
"recv_peer_btl_pace"
)
*
0.000001
networkPace
=
cprrt
.
PrrtSocket_get_sock_opt
(
self
.
_c_socket
,
"nw_pace"
)
*
0.000001
return
PrrtPaces
(
appSend
,
prrtTransmit
,
prrtReceive
,
appDeliver
,
peerPace
,
networkPace
)
property
nw_pace
:
def
__get__
(
self
):
...
...
Write
Preview
Supports
Markdown
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