Commit graph

320 commits

Author SHA1 Message Date
Sebastian Jansson
8d33c0c104 Adds field trial to do safer reset on route change.
Bug: webrtc:9718
Change-Id: I71143a9616981a24bca7bd5c663a9dae9fc9692e
Reviewed-on: https://webrtc-review.googlesource.com/c/106903
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25286}
2018-10-22 10:46:49 +00:00
Sebastian Jansson
78416b6e18 Adds time to initial config in analyzer code.
Bug: webrtc:9586
Change-Id: Ib5cbcdcf2cce3bea24d8c03a25f6cd415feb97ad
Reviewed-on: https://webrtc-review.googlesource.com/c/106880
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25254}
2018-10-18 12:43:31 +00:00
Sebastian Jansson
f5e767dbbc Don't send max allocation probe unless allocation changed.
This changes the behavior to a probe only gets trigged if
the total max allocated bitrate  actually changed.

Also adding helpful log dump flag to ramp up tests that
was used to investigate the issue.

Bug: chromium:894434
Change-Id: I907675b8fd5a339f838b07d433ecf837e312def1
Reviewed-on: https://webrtc-review.googlesource.com/c/105981
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25212}
2018-10-16 15:13:57 +00:00
Sebastian Jansson
cd0ca2d5d7 Adds unit test for RTT based backoff.
Bug: webrtc:9718
Change-Id: I372f7874a6a001e6cb5e7f6886b28763ae84c464
Reviewed-on: https://webrtc-review.googlesource.com/c/105665
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25179}
2018-10-15 17:01:01 +00:00
Sebastian Jansson
8285841e8f Adds handling of untracked data to congestion controller.
Bug: webrtc:9796
Change-Id: I097e8f72a6c8d323c3ea73dbb4ade60873dd4e8d
Reviewed-on: https://webrtc-review.googlesource.com/c/104883
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25129}
2018-10-11 18:47:44 +00:00
Ying Wang
fb226af64d Remove some old logging in goog_cc for congestion window.
Bug: None
Change-Id: I05550e5099cd7b4bc9512d2ce4159222779c02a7
Reviewed-on: https://webrtc-review.googlesource.com/c/105326
Commit-Queue: Ying Wang <yinwa@webrtc.org>
Reviewed-by: Ying Wang <yinwa@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25118}
2018-10-11 16:08:57 +00:00
Sebastian Jansson
3bdbc84888 Moves pushback controller to GoogCC
Since the pushback controller doesn't strictly adhere to the congestion
window, it better belongs together with the congestion controller logic.

Also ensuring that it does not override the configured min bitrate.

Bug: webrtc:9586
Change-Id: I57dcfc946d470247e66c67adabddaafa3d9d83ad
Reviewed-on: https://webrtc-review.googlesource.com/c/105102
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Ying Wang <yinwa@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25115}
2018-10-11 13:49:07 +00:00
Sebastian Jansson
c87b8c194a Moves GoogCC factory to API.
Bug: None
Change-Id: Ib5be0e984eff3a652504106552b0779be2c316ca
Reviewed-on: https://webrtc-review.googlesource.com/c/104941
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25076}
2018-10-10 06:11:36 +00:00
Sebastian Jansson
2e068e8b6f Adds RTT based backoff trial to SendSideBandwidthEstimation.
Bug: webrtc:9718
Change-Id: Ic94dcd7612524d350f54d1907f843577b890badf
Reviewed-on: https://webrtc-review.googlesource.com/c/104122
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25048}
2018-10-08 12:36:06 +00:00
Sebastian Jansson
7c1744d3dc Reland "Reland "Using units in SendSideBandwidthEstimation.""
This reverts commit a4de9c8b04.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Revert "Reland "Using units in SendSideBandwidthEstimation.""
> 
> This reverts commit e2cb26cb4f.
> 
> Reason for revert: <INSERT REASONING HERE>
> 
> Original change's description:
> > Reland "Using units in SendSideBandwidthEstimation."
> > 
> > This reverts commit 917e5967a5.
> > 
> > Reason for revert: Handling downstream use case.
> > 
> > Original change's description:
> > > Revert "Using units in SendSideBandwidthEstimation."
> > > 
> > > This reverts commit 35b5e5f3b0.
> > > 
> > > Reason for revert: Breaks downstream project
> > > 
> > > Original change's description:
> > > > Using units in SendSideBandwidthEstimation.
> > > >
> > > > This CL moves SendSideBandwidthEstimation to use the unit types
> > > > DataRate, TimeDelta and Timestamp. This prepares for upcoming changes.
> > > >
> > > > Bug: webrtc:9718
> > > > Change-Id: If10e329920dda037b53055ff3352ae7f8d7e32b8
> > > > Reviewed-on: https://webrtc-review.googlesource.com/c/104021
> > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org>
> > > > Cr-Commit-Position: refs/heads/master@{#25029}
> > > 
> > > TBR=terelius@webrtc.org,srte@webrtc.org
> > > 
> > > No-Try: True
> > > Bug: webrtc:9718
> > > Change-Id: Iaf470f1eec9911ee6fc7c1b4f5db9675d89d3780
> > > Reviewed-on: https://webrtc-review.googlesource.com/c/104480
> > > Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
> > > Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
> > > Cr-Commit-Position: refs/heads/master@{#25035}
> > 
> > TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org
> > 
> > Change-Id: I0940791fcd1e196598b0f0a2ec779c49931ee5df
> > No-Presubmit: true
> > No-Tree-Checks: true
> > No-Try: true
> > Bug: webrtc:9718
> > Reviewed-on: https://webrtc-review.googlesource.com/c/104520
> > Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> > Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#25036}
> 
> TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org
> 
> Change-Id: I6628771c79fc78dfd856649ae92232e95df63495
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:9718
> Reviewed-on: https://webrtc-review.googlesource.com/c/104540
> Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25037}

TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org

Change-Id: If5473859cea725420afce11b6683fa0c70a29b0a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9718
Reviewed-on: https://webrtc-review.googlesource.com/c/104501
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25039}
2018-10-08 09:02:03 +00:00
Sebastian Jansson
a4de9c8b04 Revert "Reland "Using units in SendSideBandwidthEstimation.""
This reverts commit e2cb26cb4f.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Reland "Using units in SendSideBandwidthEstimation."
> 
> This reverts commit 917e5967a5.
> 
> Reason for revert: Handling downstream use case.
> 
> Original change's description:
> > Revert "Using units in SendSideBandwidthEstimation."
> > 
> > This reverts commit 35b5e5f3b0.
> > 
> > Reason for revert: Breaks downstream project
> > 
> > Original change's description:
> > > Using units in SendSideBandwidthEstimation.
> > >
> > > This CL moves SendSideBandwidthEstimation to use the unit types
> > > DataRate, TimeDelta and Timestamp. This prepares for upcoming changes.
> > >
> > > Bug: webrtc:9718
> > > Change-Id: If10e329920dda037b53055ff3352ae7f8d7e32b8
> > > Reviewed-on: https://webrtc-review.googlesource.com/c/104021
> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> > > Reviewed-by: Björn Terelius <terelius@webrtc.org>
> > > Cr-Commit-Position: refs/heads/master@{#25029}
> > 
> > TBR=terelius@webrtc.org,srte@webrtc.org
> > 
> > No-Try: True
> > Bug: webrtc:9718
> > Change-Id: Iaf470f1eec9911ee6fc7c1b4f5db9675d89d3780
> > Reviewed-on: https://webrtc-review.googlesource.com/c/104480
> > Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
> > Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#25035}
> 
> TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org
> 
> Change-Id: I0940791fcd1e196598b0f0a2ec779c49931ee5df
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:9718
> Reviewed-on: https://webrtc-review.googlesource.com/c/104520
> Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25036}

TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org

Change-Id: I6628771c79fc78dfd856649ae92232e95df63495
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9718
Reviewed-on: https://webrtc-review.googlesource.com/c/104540
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25037}
2018-10-08 08:27:29 +00:00
Sebastian Jansson
e2cb26cb4f Reland "Using units in SendSideBandwidthEstimation."
This reverts commit 917e5967a5.

Reason for revert: Handling downstream use case.

Original change's description:
> Revert "Using units in SendSideBandwidthEstimation."
> 
> This reverts commit 35b5e5f3b0.
> 
> Reason for revert: Breaks downstream project
> 
> Original change's description:
> > Using units in SendSideBandwidthEstimation.
> >
> > This CL moves SendSideBandwidthEstimation to use the unit types
> > DataRate, TimeDelta and Timestamp. This prepares for upcoming changes.
> >
> > Bug: webrtc:9718
> > Change-Id: If10e329920dda037b53055ff3352ae7f8d7e32b8
> > Reviewed-on: https://webrtc-review.googlesource.com/c/104021
> > Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> > Reviewed-by: Björn Terelius <terelius@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#25029}
> 
> TBR=terelius@webrtc.org,srte@webrtc.org
> 
> No-Try: True
> Bug: webrtc:9718
> Change-Id: Iaf470f1eec9911ee6fc7c1b4f5db9675d89d3780
> Reviewed-on: https://webrtc-review.googlesource.com/c/104480
> Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
> Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25035}

TBR=oprypin@webrtc.org,terelius@webrtc.org,srte@webrtc.org

Change-Id: I0940791fcd1e196598b0f0a2ec779c49931ee5df
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9718
Reviewed-on: https://webrtc-review.googlesource.com/c/104520
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25036}
2018-10-08 08:26:09 +00:00
Oleh Prypin
917e5967a5 Revert "Using units in SendSideBandwidthEstimation."
This reverts commit 35b5e5f3b0.

Reason for revert: Breaks downstream project

Original change's description:
> Using units in SendSideBandwidthEstimation.
>
> This CL moves SendSideBandwidthEstimation to use the unit types
> DataRate, TimeDelta and Timestamp. This prepares for upcoming changes.
>
> Bug: webrtc:9718
> Change-Id: If10e329920dda037b53055ff3352ae7f8d7e32b8
> Reviewed-on: https://webrtc-review.googlesource.com/c/104021
> Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> Reviewed-by: Björn Terelius <terelius@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25029}

TBR=terelius@webrtc.org,srte@webrtc.org

No-Try: True
Bug: webrtc:9718
Change-Id: Iaf470f1eec9911ee6fc7c1b4f5db9675d89d3780
Reviewed-on: https://webrtc-review.googlesource.com/c/104480
Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25035}
2018-10-08 08:21:18 +00:00
Sebastian Jansson
35b5e5f3b0 Using units in SendSideBandwidthEstimation.
This CL moves SendSideBandwidthEstimation to use the unit types
DataRate, TimeDelta and Timestamp. This prepares for upcoming changes.

Bug: webrtc:9718
Change-Id: If10e329920dda037b53055ff3352ae7f8d7e32b8
Reviewed-on: https://webrtc-review.googlesource.com/c/104021
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25029}
2018-10-05 18:37:13 +00:00
Sebastian Jansson
a23dc78c7d Removes initial window field trial.
Bug: webrtc:9718
Change-Id: Ia1cc352bde1d8994cce7eb7e3bdcbc04e03fd718
Reviewed-on: https://webrtc-review.googlesource.com/c/104041
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25025}
2018-10-05 15:41:50 +00:00
Sebastian Jansson
35fa280229 Adds allocated rate without feedback to new congestion controller.
When bitrate is allocated to streams that does not have packet feedback,
the allocated bitrate should be included in the estimate. This was
previously only implemented for the old congestion controller and not
for the new task queue based version.

To make the behavior more robust, the responsibility for tracking this
is moved to BitrateAllocator where it's handled consistently for
multiple streams without feedback.

Bug: webrtc:9586, webrtc:8243
Change-Id: I8af7fec23e1bdc08cc61cf1b4ff10461c3711fb0
Reviewed-on: https://webrtc-review.googlesource.com/102681
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24905}
2018-10-01 07:48:02 +00:00
Sebastian Jansson
71a091e24e Adds simulated time scenario client.
Adds SimulatedTimeClient, a class that simulates time so congestion
controllers can be tested using the Scenario test framework without
running in real time.

This allows using simplified scenario tests as unit tests, narrowing
the gap between end to end tests and unit tests.

Bug: webrtc:9510
Change-Id: I61ab388bd610f636b926675b1f14b8d85e3c1114
Reviewed-on: https://webrtc-review.googlesource.com/99801
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24890}
2018-09-28 12:30:44 +00:00
Mirko Bonadei
17f4878419 Remove deprecated field_trial_default and metrics_default.
This CL removes some deprecated build targets (and their headers)
from system_wrappers:
- field_trial_api
- field_trial_default
- metrics_api
- metrics_default

It also refreshes all the dependencies on field_trial.h and metrics.h.

A nice side effect is that it is finally possible to remove 'nogncheck'
from the following files (when it was used with field_trial_default
and metrics_default):
- sdk/objc/api/peerconnection/RTCMetricsSampleInfo+Private.h
- sdk/android/src/jni/pc/peerconnectionfactory.cc
- sdk/objc/api/peerconnection/RTCFieldTrials.mm

Bug: webrtc:9631
Change-Id: Ib621f41ef8ad0aba4fe1c1d7e749c044afc956c3
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/100524
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24878}
2018-09-28 07:21:07 +00:00
Sebastian Jansson
98b07e9180 Adds scenario test framework.
Bug: webrtc:9510
Change-Id: I387aab4211f520a1c54832f82032ee724479e89e
Reviewed-on: https://webrtc-review.googlesource.com/89342
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24864}
2018-09-27 12:31:33 +00:00
Sebastian Jansson
c0af56b9fb Cleanup in congestion controller.
This CL removes some indirection and moves some constants. This
is done to simplify understanding and debugging of the code.

Bug: webrtc:9718
Change-Id: Ibe2b1da0163b4c97ffd1a5bc157f6aa59582d697
Reviewed-on: https://webrtc-review.googlesource.com/98240
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24732}
2018-09-13 15:46:37 +00:00
Sebastian Jansson
57606328f6 Adds initial data window field trial to GoogCC.
Bug: webrtc:9718
Change-Id: Ia5a77a09d7ba82b545e9ab12036f717765fdf3b4
Reviewed-on: https://webrtc-review.googlesource.com/97740
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24659}
2018-09-10 16:55:37 +00:00
Mirko Bonadei
50cfab7d84 Fix no_global_constructors in congestion_controller/goog_cc.
Bug: webrtc:9693
Change-Id: Ic341f3bed2c7c8c4f62363a7344f8524ff561155
Reviewed-on: https://webrtc-review.googlesource.com/98580
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24607}
2018-09-06 16:01:49 +00:00
Mirko Bonadei
96ede16a4e Enable -Wexit-time-destructors and -Wglobal-constructors.
This CL enables -Wexit-time-destructors and -Wglobal-constructors on
rtc_static_library and rtc_source_set build targets.

It also adds the possibility to suppress these warnings because
they trigger in a few places.

The long term goal is to avoid regressions on this and remove all the
suppressions.

Bug: webrtc:9693
Change-Id: I4c1ecc137ef9e87ec5e66981ce95d96fb082727c
Reviewed-on: https://webrtc-review.googlesource.com/98380
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24604}
2018-09-06 12:43:20 +00:00
Sebastian Jansson
8f03216bbd Minor refactor in GoogCcNetworkController.
In-lining GetNetworkParameters and MaybeUpdateCongestionWindow which
was left over from previous refactoring. This prepares for upcoming CLs
changing the behavior.

Bug: webrtc:9586
Change-Id: I6f038acdf97c3db2c85254a36592c617a5754a96
Reviewed-on: https://webrtc-review.googlesource.com/97605
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24570}
2018-09-05 09:20:15 +00:00
Sebastian Jansson
d0e0ec959f Printing internal state of GoogCC.
This is useful for debugging and has minimal effect on production code.

Bug: webrtc:9510
Change-Id: I3a71f484a0d4e54999e376b7924b73230d86cd96
Reviewed-on: https://webrtc-review.googlesource.com/97607
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24557}
2018-09-04 17:26:02 +00:00
Sebastian Jansson
9de4ef4b24 Adds signed infinity to timestamps.
Negative infinity is useful in comparisons as it represents a value
guaranteed to be less than any other timestamp. This avoid using
Timestamp::ms(0) to represent such a value or having to use optional
for the special case of first time execution.

To avoid ambiguity, Timestamp::Infinity is renamed to PlusInfinity.

Bug: webrtc:9709
Change-Id: Ib2debff91036e94d1dc903ec0c6faae30febde4e
Reviewed-on: https://webrtc-review.googlesource.com/79440
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24556}
2018-09-04 17:14:05 +00:00
Sebastian Jansson
ed1f75ab6d Removes redundant starting rate.
Sine a starting rate field was added to the constraints struct. Having
it in the initial config separately is reduntant. To simplify the code,
the extra field is removed. This is a follow up on:
https://webrtc-review.googlesource.com/c/src/+/92624

Bug: webrtc:9586
Change-Id: I9b01b16b2fc4b8479e83b7e998308be2295e0325
Reviewed-on: https://webrtc-review.googlesource.com/96801
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24514}
2018-08-31 17:36:21 +00:00
Will Harris
fc173d00ec Add no_size_t_to_int_warning suppression to webrtc.
Current set of warnings that need fixing before this warning can
be enabled is here -> https://pastebin.com/raw/jTddgPzP

BUG=chromium:588506, webrtc:9451

Change-Id: Id7896cf48c7231b2ee28dde378ff3ce17da73c2b
Reviewed-on: https://webrtc-review.googlesource.com/96623
Commit-Queue: Will Harris <wfh@chromium.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24503}
2018-08-30 17:45:54 +00:00
Sebastian Jansson
34ee419a23 Fixes breaking bug in feedback based GoogCC.
This CL fixes a bug in the feedback based GoogCC where packets lost
was swapped with expected packets received. Since this version of
GoogCC isn't yet used this wasn't discovered. There was also a lack
of unit test coverage. To ensure reasonable behavior, unit tests was
added.

Unit tests was also converted from relevant unit tests on send side
congestion controller for the regular GoogCC controller.

Bug: webrtc:9586
Change-Id: I83c40ff4766104820cb72ec1e8b95c5782def19a
Reviewed-on: https://webrtc-review.googlesource.com/59401
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24498}
2018-08-30 13:22:51 +00:00
Sebastian Jansson
206b77f7ad Adds start bitrate handling to task queue congestion controller.
This adds a start bitrate field to TargetRateConstraints since this is
required in VideoSendStreamTests. This also reduces the differences
between the old SendSideCongestionController and the new TaskQueue
based version.

Bug: webrtc:9586
Change-Id: I5d3d1414e9d30b51723c911a0bf2e96b876c04e5
Reviewed-on: https://webrtc-review.googlesource.com/92624
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24384}
2018-08-22 10:09:26 +00:00
Sebastian Jansson
eb73a7bd16 Removes unnecessary webrtc_cc namespaces.
Bug: webrtc:9586
Change-Id: I6407ee465d725d7469c409e5bea1c55354ab7f95
Reviewed-on: https://webrtc-review.googlesource.com/92385
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24199}
2018-08-06 17:18:45 +00:00
Sebastian Jansson
13ef7d25f6 Adds feedback only mode to GoogCC.
This CL adds a factory for creating a GoogCC network controller that
can be used without RTCP specific messages. This prepares for enabling
use of other underlying protocols as long as they can provide per
packet feedback.

Bug: None
Change-Id: I6671181949d97abd18843d0f4edf75040cc3f007
Reviewed-on: https://webrtc-review.googlesource.com/84583
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24198}
2018-08-06 15:43:37 +00:00
Sebastian Jansson
da2ec40590 Always sends probes when they are generated.
This changes makes the usage of the new probe controller reflect how the
old probe controller was used. That is probes are now sent as soon as
they are generated. This is to avoid regressions in performance doe to
the timing of the sent probes.

Bug: chromium:868776
Change-Id: I722585689258c9b01e8f1dc47249b284a05a2793
Reviewed-on: https://webrtc-review.googlesource.com/91441
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24175}
2018-08-02 15:36:12 +00:00
Mirko Bonadei
3e5281f2b3 Enable clang::find_bad_constructs for congestion_controller/goog_cc.
This CL removes //build/config/clang:find_bad_constructs from the
suppressed_configs list, which means that clang:find_bad_constructs
is now enabled on these translation units.

Bug: webrtc:9251, webrtc:163
Change-Id: I289795c92958fd43fed6165894510ad63ca9d24d
Reviewed-on: https://webrtc-review.googlesource.com/90415
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24114}
2018-07-26 13:32:29 +00:00
Niels Möller
a12c42a6b2 Delete root header file typedef.h.
Usage replaced with stdint.h, rtc_base/system/arch.h and
rtc_base/system/unused.h, as appropriate.

Bug: webrtc:6854
Change-Id: I97225465d14b969903d92979e2df3c3c05d35f18
Reviewed-on: https://webrtc-review.googlesource.com/90249
Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24100}
2018-07-25 14:59:26 +00:00
Bjorn Terelius
0c7ec80927 Limit BWE reductions before first measured throughput.
After detecting overuse of the network capacity, the target
bitrate is reduced. Normally, this should happen at most once
per RTT to prevent repeated reductions from the same overuse
signal. This CL fixes a bug that allowed repeated reductions
if an overuse was detected before it had the first reliable
throughput measurement.

The fix is guarded by a field trial. To enable the fix, use
WebRTC-BweInitialBackOffInterval/Enabled-200/

Bug: webrtc:9493
Change-Id: Iae566227fd94ebb8a4449406572158a8b79d9c53
Reviewed-on: https://webrtc-review.googlesource.com/88765
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24021}
2018-07-18 13:51:05 +00:00
Sebastian Jansson
b2ecc3dc49 Removes old probe controller.
This removes the old version of Probe Controller. The new controller is
slightly different, therefore the legacy SendSideCongestionController is
changed to accommodate the new function.

Most notably, the functionality is changed so that probes are now sent
only from the OnProcess call and not immediately on changing a
parameter.

The lock previously owned and used by ProbeController is moved to SendSideCongestionController. This should not change any
behavior.

Bug: webrtc:8415
Change-Id: I3c69ddeb04aeeae1234a2a5e116fb677f36b4ae4
Reviewed-on: https://webrtc-review.googlesource.com/86541
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23973}
2018-07-13 16:13:26 +00:00
Bjorn Terelius
d97b862593 Field trial to initialize throughput estimate faster.
The current acknowledged bitrate (i.e. throughput) estimator takes 500ms
to initialize. This CL creates a field trial to experiment with this
arbitrary initialization time.

Bug: webrtc:9492, webrtc:7746
Change-Id: I8a803f7bc0ee78856e808e289f37bab57d763efa
Reviewed-on: https://webrtc-review.googlesource.com/87145
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23852}
2018-07-05 12:14:04 +00:00
Karl Wiberg
918f50c5d1 Use absl::make_unique and absl::WrapUnique directly
Instead of going through our wrappers in ptr_util.h.

This CL was generated by the following script:

  git grep -l ptr_util | xargs perl -pi -e 's,#include "rtc_base/ptr_util.h",#include "absl/memory/memory.h",'
  git grep -l MakeUnique | xargs perl -pi -e 's,\b(rtc::)?MakeUnique\b,absl::make_unique,g'
  git grep -l WrapUnique | xargs perl -pi -e 's,\b(rtc::)?WrapUnique\b,absl::WrapUnique,g'
  git checkout -- rtc_base/ptr_util{.h,_unittest.cc}
  git cl format

Followed by manually adding dependencies on
//third_party/abseil-cpp/absl/memory until `gn check` stopped
complaining.

Bug: webrtc:9473
Change-Id: I89ccd363f070479b8c431eb2c3d404a46eaacc1c
Reviewed-on: https://webrtc-review.googlesource.com/86600
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23850}
2018-07-05 10:59:49 +00:00
Sebastian Jansson
13171bdba8 Adds debug printing for congestion controllers.
These are useful for plotting creating data files that can be used to
visualize and debug congestion controller behavior.

Bug: webrtc:9467
Change-Id: I75b03a309b4b7d562fefe82a828ae1e6a9f069c8
Reviewed-on: https://webrtc-review.googlesource.com/86126
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23822}
2018-07-03 17:00:24 +00:00
Sebastian Jansson
04b18cb365 Removes redundant delay based bwe.
This removes the legacy DelayBasedBwe to reduce code redundancy and
avoid the risk of applying changes on only one version.

Bug: webrtc:8415
Change-Id: I88aba03adbb77ee0ff0a97a8b3be6ddf028af48a
Reviewed-on: https://webrtc-review.googlesource.com/85364
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23798}
2018-07-02 09:11:33 +00:00
Sebastian Jansson
f9f49a323c Removes redundant AlrDetector.
This replaces the old AlrDetector used by the pacer with the one in
GoogCC. This reduces the risk of accidentally changing only one version.

Note that the pacer instance will be removed when moving over to the
task queue based send side congestion controller.

Bug: webrtc:8415
Change-Id: Id4b2000ee5a04b94565092c29a84572a7750d2f5
Reviewed-on: https://webrtc-review.googlesource.com/85363
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23791}
2018-06-29 16:28:04 +00:00
Bjorn Terelius
43d0b98fe5 Clean up RateControlInput struct, used by bandwidth estimation.
Remove unused member noise_var from RateControlInput struct.

Rename incoming_bitrate to estimated_throughput_bps to reflect
that the AimdRateControl may be running on either the send side
or the receive side.

Bug: webrtc:9411
Change-Id: Ie1ae0c29dc9559ef389993144e69fcd41684f1a4
Reviewed-on: https://webrtc-review.googlesource.com/83728
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Anastasia Koloskova <koloskova@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23783}
2018-06-29 10:47:37 +00:00
Alex Narest
bcf91808a2 Allows audio bitrate allocation in video calls without enabling TWCC (Transport Wide Congestion Control as defined at https://tools.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01.html) for audio stream.
This will allow experimenting with audio bitrate allocation in video calls without increasing transport overhead.

Bug: webrtc:8243
Change-Id: If961780921d53bdce95b68c26641df6875509c1f
Reviewed-on: https://webrtc-review.googlesource.com/84501
Commit-Queue: Alex Narest <alexnarest@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23755}
2018-06-27 10:33:40 +00:00
Mirko Bonadei
beb2d9813c Removing usage of //build/config/compiler:no_size_t_to_int_warning.
Bug: webrtc:9251, webrtc:1348
Change-Id: I76e52abbfab5666cad73044b49172a9799539108
Reviewed-on: https://webrtc-review.googlesource.com/84144
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23686}
2018-06-20 13:44:26 +00:00
Danil Chapovalov
0040b66ad3 Replace rtc::Optional with absl::optional
This is a no-op change because rtc::Optional is an alias to absl::optional

This CL generated by running script from modules with parameters
'pacing video_coding congestion_controller remote_bitrate_estimator':

find $@ -type f \( -name \*.h -o -name \*.cc \) \
-exec sed -i 's|rtc::Optional|absl::optional|g' {} \+ \
-exec sed -i 's|rtc::nullopt|absl::nullopt|g' {} \+ \
-exec sed -i 's|#include "api/optional.h"|#include "absl/types/optional.h"|' {} \+

find $@ -type f -name BUILD.gn \
-exec sed -r -i 's|"(../)*api:optional"|"//third_party/abseil-cpp/absl/types:optional"|' {} \+;

git cl format

Bug: webrtc:9078
Change-Id: I8ea501d7f1ee36e8d8cd3ed37e6b763c7fe29118
Reviewed-on: https://webrtc-review.googlesource.com/83900
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23640}
2018-06-18 10:24:48 +00:00
Ying Wang
66eaed0393 Adding direct congestion window pushback to encoders.
When CongestionWindowPushback experiment is enabled, the pacer is oblivious to the congestion window. The relation between outstanding data and the congestion window affects encoder allocations directly.

Bug: None
Change-Id: Iaacc1d460d44a4ff2d586934c4f9ceb067109337
Reviewed-on: https://webrtc-review.googlesource.com/74922
Commit-Queue: Ying Wang <yinwa@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23411}
2018-05-28 12:15:59 +00:00
Sebastian Jansson
172fd8536e Replaces redundant congestion controller components
This CL replaces components in the congestion controller module
that are identical to equivalent components in the rtp and goog_cc
subfolder. Some redundant components are left as they were not
trivial to replace.

Bug: webrtc:8415
Change-Id: I86a1f164d7b100b8ec8ba7dbc1c9bda2128a4f37
Reviewed-on: https://webrtc-review.googlesource.com/78521
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23384}
2018-05-24 13:35:31 +00:00
Per Kjellander
dd3eae5f94 Revert "Configure and use max bitrate to limit the AIMD controller estimates."
This reverts commit 18d7c7ea7e.

Reason for revert: 
This seems to cause the auto roller to Chrome to fail on Linux and Mac on the browsertest
WebRtcSimulcastBrowserTest.TestVgaReturnsTwoSimulcastStreams

https://chromium-review.googlesource.com/c/chromium/src/+/1064736


Original change's description:
> Configure and use max bitrate to limit the AIMD controller estimates.
> 
> Bug: webrtc:9275
> Change-Id: I9625cd473e1cb198abe08020f5462f1bd64bf2a5
> Reviewed-on: https://webrtc-review.googlesource.com/77081
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> Commit-Queue: Björn Terelius <terelius@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23287}

TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org

Change-Id: I8ed827ab6b2f7d2b70b9889e5a88701bfb974d35
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9275
Reviewed-on: https://webrtc-review.googlesource.com/77660
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23291}
2018-05-18 07:12:26 +00:00
Bjorn Terelius
18d7c7ea7e Configure and use max bitrate to limit the AIMD controller estimates.
Bug: webrtc:9275
Change-Id: I9625cd473e1cb198abe08020f5462f1bd64bf2a5
Reviewed-on: https://webrtc-review.googlesource.com/77081
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23287}
2018-05-17 16:07:42 +00:00
Sebastian Jansson
c6c44268bc Moves network control interface to API.
This prepares for allowing injection of a network controller.

Bug: webrtc:9155
Change-Id: I5624f47738db9c5cd4750eac76cb6289e06a7aa3
Reviewed-on: https://webrtc-review.googlesource.com/73100
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23188}
2018-05-09 11:01:36 +00:00
Sebastian Jansson
ea562b40f8 Removes dependency on Optional for unit classes.
This makes the dependency graph simpler and prepares for moving the
unit classes to api/.

Bug: webrtc:9155
Change-Id: I1b36d5e05f75d70ba8951e880d76359f896f7741
Reviewed-on: https://webrtc-review.googlesource.com/74920
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23161}
2018-05-08 08:00:45 +00:00
Sebastian Jansson
ec6e550a8f Removes usage of uninitialized units in network control code.
This removes places where the units types are implicitly left
uninitialized in network_types.h and adds rtc::Optional where needed.

Also removing the change indicator in the NetworkEstimate struct as it
is not used in practice.

Bug: webrtc:9155
Change-Id: I7e30e338effba96bd466ae91e380e6a8e90f66e1
Reviewed-on: https://webrtc-review.googlesource.com/73369
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23126}
2018-05-04 16:19:14 +00:00
Sebastian Jansson
341bfca58c Removes uptr alias in network control code.
Bug: webrtc:9155
Change-Id: Ia3b79642a9477d9357a289f8f14bd2f53bc52e2e
Reviewed-on: https://webrtc-review.googlesource.com/73371
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23098}
2018-05-03 11:57:41 +00:00
philipel
9fd6b98f44 Don't interrupt exponential probing when VideoStream bitrates are reconfigured.
Bug: chromium:834255, webrtc:8955
Change-Id: Iba316e940ddc2d0d5891e57c24b808c68e0bbcfe
Reviewed-on: https://webrtc-review.googlesource.com/70760
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22943}
2018-04-19 15:44:59 +00:00
philipel
0676f224f8 Probe on video encoder reconfiguration test.
This CL includes the changes from this CL:
https://webrtc-review.googlesource.com/c/src/+/63642

Bug: webrtc:8955
Change-Id: If95cdec59f25e97c6ff5ea45a52d6113128a0921
Reviewed-on: https://webrtc-review.googlesource.com/64822
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22910}
2018-04-17 16:54:14 +00:00
Sebastian Jansson
f7ffd94ad2 Removes abbreviated seconds functions on network time classes.
Having only one name for seconds makes the interface more consistent.
The non-abbreviated was chosen since it's used less frequently than
ms() and us().

Bug: None
Change-Id: Ia29ff2f9f18f3dddcde9bac4f041695cef2c8f0f
Reviewed-on: https://webrtc-review.googlesource.com/69817
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Benjamin Wright <benwright@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22877}
2018-04-16 12:47:38 +00:00
Sebastian Jansson
a73538828f Fixes potential crash in GoogCcNetworkController
UpdatePacingRates required that a bandwidth estimate was available and
would otherwise crash. This CL ensures that there is an initial bandwidth
estimate available from the beginning.

Bug: webrtc:8415
Change-Id: I20c3b444eac42326a78cfebee70b4c1aa370c867
Reviewed-on: https://webrtc-review.googlesource.com/69802
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22857}
2018-04-13 12:24:18 +00:00
Sebastian Jansson
342695d068 Removes network ostream operators.
The ostream operators does not work consistently with gtest since the
definitions would have to be included before the first include of gtest.
This is tricky to ensure and the end result is that the operators will
sometimes work and sometimes not without obvious explanations.
To avoid causing confusing behavior, this CL removes the operators
pending a better solution.

Bug: None
Change-Id: I66bead0efb7246d368359ddf9e9bfad9d67c05da
Reviewed-on: https://webrtc-review.googlesource.com/68640
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22808}
2018-04-10 14:59:15 +00:00
Sebastian Jansson
ae9057831f Removed observer from network controller interface.
Moving the responsibility for calling callbacks from implementations
of NetworkControllerInterface to SendSideCongestionController. This
decreases the coupling and makes the callbacks more explicit.

Bug: webrtc:8415
Change-Id: Ie75effbde01533106080bb6c40308b0c20064c45
Reviewed-on: https://webrtc-review.googlesource.com/66882
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22793}
2018-04-09 11:54:38 +00:00
Sebastian Jansson
f2e3e7a25a Removed observer from probe controller.
Replacing observer interface with polling for pending probe clusters.
The purpose is to make it easier to reason about and control side
effects and to prepare for a similar change in the network controller
interface.

Bug: webrtc:8415
Change-Id: I8101cfda22e640a8e0fa75f3f6e63876db826a89
Reviewed-on: https://webrtc-review.googlesource.com/66881
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22775}
2018-04-06 16:13:37 +00:00
Sebastian Jansson
63b48df334 Removed static const network units.
Static const objects can cause what's called a "static initialization
order fiasco". This CL removes the statically initialized network units
in favor of constexpr defined versions available via static functions.

Bug: webrtc:8415
Change-Id: Ib1b316ae007481c52a53b2d1bb0352a630a220e2
Reviewed-on: https://webrtc-review.googlesource.com/65164
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22670}
2018-03-29 09:45:27 +00:00
Sebastian Jansson
aca5a7df73 Improvements to network control types.
This CL prepares for adding the BBR network controller and
unit tests for GoogCC network controller.

The changes include:
* Adding pad_rate helper method on PacerConfig.
* Adding ostream operators for controller feedback structs.
* Adding increment operator to Timestamp class.
* Adding kEpoch to Timestamp class to represent 0.
* Rounding when multiplying with double.

Bug: webrtc:8415
Change-Id: I58289f37a6f9f2eee0a88bb06fb24dc295942862
Reviewed-on: https://webrtc-review.googlesource.com/61503
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22458}
2018-03-15 15:40:08 +00:00
Sebastian Jansson
efbcfb13a7 Configuration in constructor of Goog CC.
Adding configuration of new GoogCcNetworkController to initializer, this
makes sure that it is properly initialized from the start. To achieve
this SendSideCongestionController waits until it has received the
necessary information to construct the object. This information should
be provided in the constructor for SendSideCongestionController in the
future.

Bug: webrtc:8415
Change-Id: Icc09b8b246bae9f9704b80855fc4caa3450b34fc
Reviewed-on: https://webrtc-review.googlesource.com/58099
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22404}
2018-03-13 16:05:21 +00:00
Karl Wiberg
12edf4ce34 Separate build target for rtc_base/numerics/safe_minmax.h
So that we can avoid dependency cycles.

Bug: none
Change-Id: I821d9f1319dff01403d6e4e310cbb2d4b2b125e8
Reviewed-on: https://webrtc-review.googlesource.com/60500
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22328}
2018-03-07 14:12:00 +00:00
philipel
db4fa4b944 Propagating total_bitrate_bps from BitrateAllocator to ProbeController, part 3.
Trigger on total bitrate change.

Bug: webrtc:8955
Change-Id: I2373a1b7f139c7ea748a9641593e714d6895c8f6
Reviewed-on: https://webrtc-review.googlesource.com/59323
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22323}
2018-03-07 10:31:35 +00:00
Sebastian Jansson
8d9dcb1c89 Adding bps_or method to DataRate class.
Bug: webrtc:8415
Change-Id: I64e46b63d82cb843f0710839c1fc22e2440ae7e1
Reviewed-on: https://webrtc-review.googlesource.com/59222
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22285}
2018-03-05 11:47:52 +00:00
Sebastian Jansson
fc7ec8e9f8 Reland "Moved congestion controller to goog_cc folder."
This is a reland of e6cefdf9c5.

Original change's description:
> Moved congestion controller to goog_cc folder.
> 
> Bug: webrtc:8415
> Change-Id: I2070da0cacf1dbfc4b6a89285af3e68fd03497ab
> Reviewed-on: https://webrtc-review.googlesource.com/43841
> Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> Reviewed-by: Björn Terelius <terelius@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21928}

Bug: webrtc:8415
Change-Id: Ib5cf8641466655d64ac80f720561817f4cab49a9
Reviewed-on: https://webrtc-review.googlesource.com/53062
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22244}
2018-03-01 10:16:12 +00:00
Danil Chapovalov
bda5068fae Revert "Moved congestion controller to goog_cc folder."
This reverts commit e6cefdf9c5.

Reason for revert: conflicts with reverting https://webrtc-review.googlesource.com/c/src/+/52980

Original change's description:
> Moved congestion controller to goog_cc folder.
> 
> Bug: webrtc:8415
> Change-Id: I2070da0cacf1dbfc4b6a89285af3e68fd03497ab
> Reviewed-on: https://webrtc-review.googlesource.com/43841
> Commit-Queue: Sebastian Jansson <srte@webrtc.org>
> Reviewed-by: Björn Terelius <terelius@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21928}

TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: webrtc:8415
Change-Id: If8965e1e745e57694192b9ca2a69503c722658d9
Reviewed-on: https://webrtc-review.googlesource.com/53020
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22012}
2018-02-14 10:09:44 +00:00
Sebastian Jansson
e6cefdf9c5 Moved congestion controller to goog_cc folder.
Bug: webrtc:8415
Change-Id: I2070da0cacf1dbfc4b6a89285af3e68fd03497ab
Reviewed-on: https://webrtc-review.googlesource.com/43841
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21928}
2018-02-07 09:50:48 +00:00