Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Benjamin Mahler


> On July 15, 2016, 12:15 a.m., Guangya Liu wrote:
> >

Thanks!


> On July 15, 2016, 12:15 a.m., Guangya Liu wrote:
> > src/master/allocator/sorter/sorter.hpp, line 132
> > 
> >
> > s/list/vector

I'll adjust to:

```
  // Returns all of the clients in the order that they should
  // be allocated to, according to this Sorter's policy.
```


- Benjamin


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142312
---


On July 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Benjamin Mahler


> On July 14, 2016, 11:49 p.m., Klaus Ma wrote:
> > src/master/allocator/sorter/drf/sorter.hpp, line 22
> > 
> >
> > This's not necessary, `sorter/sorter.hpp` had included it.
> 
> Guangya Liu wrote:
> I think the reason here is we generally don't rely on transitive includes 
> as it's harder to maintain.
> 
> Klaus Ma wrote:
> We should keep small list of header; if anyone missed removing, it'll 
> impact compile performance.
> 
> Jiang Yan Xu wrote:
> We follow the rules here: 
> https://google.github.io/styleguide/cppguide.html#Names_and_Order_of_Includes 
> so in this case I think it's fine for drf/sorter.hpp to include vector again 
> even if sorter/sorter.hpp already includes it. However if we follow the guide 
> strictly, then drf/sorter.cpp doesn't need to include again because it's own 
> header includes it. :)

We generally don't rely on transitive includes, even in the case that the 
header clearly demonstrates intent (e.g. the interface function returns 
vector), because it's easier to maintain (quickly scan a file and add includes 
for all symbols present).

Klaus, note that this is a redundant include, so either way the compilation 
units with sorter.hpp are going to have one or many vector includes, but not 
zero. Zero -> one definitely adds a significant compile-time performance 
impact, but here we're talking about N -> M where N >= 1, M > N. I don't think 
we found that redundant includes had a significant impact on compile time 
performance, but if you have found that to be the case, please show us!


- Benjamin


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142308
---


On July 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Benjamin Mahler


> On July 15, 2016, 3:35 p.m., Jiang Yan Xu wrote:
> > Modulo Gaungya's comments.
> 
> Jiang Yan Xu wrote:
> In the testing done section: 72 us reduction from how much time 
> originally? :)

The timing was from a no-op sort. Took 155us for 1000 clients with a list, 83us 
or so with a vector. I didn't really want to go into much detail since I just 
wanted to show that this doesn't make things worse, because this code dates 
from before we switched to prefer vector over list.


- Benjamin


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142383
---


On July 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Jiang Yan Xu


> On July 15, 2016, 8:35 a.m., Jiang Yan Xu wrote:
> > Modulo Gaungya's comments.

In the testing done section: 72 us reduction from how much time originally? :)


- Jiang Yan


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142383
---


On July 14, 2016, 12:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 12:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Jiang Yan Xu


> On July 14, 2016, 4:49 p.m., Klaus Ma wrote:
> > src/master/allocator/sorter/drf/sorter.hpp, line 22
> > 
> >
> > This's not necessary, `sorter/sorter.hpp` had included it.
> 
> Guangya Liu wrote:
> I think the reason here is we generally don't rely on transitive includes 
> as it's harder to maintain.
> 
> Klaus Ma wrote:
> We should keep small list of header; if anyone missed removing, it'll 
> impact compile performance.

We follow the rules here: 
https://google.github.io/styleguide/cppguide.html#Names_and_Order_of_Includes 
so in this case I think it's fine for drf/sorter.hpp to include vector again 
even if sorter/sorter.hpp already includes it. However if we follow the guide 
strictly, then drf/sorter.cpp doesn't need to include again because it's own 
header includes it. :)


- Jiang Yan


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142308
---


On July 14, 2016, 12:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 12:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-15 Thread Jiang Yan Xu

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142383
---


Ship it!




Modulo Gaungya's comments.

- Jiang Yan Xu


On July 14, 2016, 12:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 12:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Klaus Ma


> On July 15, 2016, 7:49 a.m., Klaus Ma wrote:
> > src/master/allocator/sorter/drf/sorter.hpp, line 22
> > 
> >
> > This's not necessary, `sorter/sorter.hpp` had included it.
> 
> Guangya Liu wrote:
> I think the reason here is we generally don't rely on transitive includes 
> as it's harder to maintain.

We should keep small list of header; if anyone missed removing, it'll impact 
compile performance.


- Klaus


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142308
---


On July 15, 2016, 3:35 a.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 15, 2016, 3:35 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Guangya Liu


> On 七月 14, 2016, 11:49 p.m., Klaus Ma wrote:
> > src/master/allocator/sorter/drf/sorter.hpp, line 22
> > 
> >
> > This's not necessary, `sorter/sorter.hpp` had included it.

I think the reason here is we generally don't rely on transitive includes as 
it's harder to maintain.


- Guangya


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142308
---


On 七月 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated 七月 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Guangya Liu

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142312
---




src/master/allocator/sorter/sorter.hpp (line 131)


s/list/vector



src/tests/sorter_tests.cpp (line 21)


remove this



src/tests/sorter_tests.cpp (line 23)


```
#include 
```



src/tests/sorter_tests.cpp (line 40)


remove this


- Guangya Liu


On 七月 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated 七月 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Klaus Ma

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142309
---


Ship it!




Ship It!

- Klaus Ma


On July 15, 2016, 3:35 a.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 15, 2016, 3:35 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Klaus Ma

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142308
---




src/master/allocator/sorter/drf/sorter.hpp (line 22)


This's not necessary, `sorter/sorter.hpp` had included it.


- Klaus Ma


On July 15, 2016, 3:35 a.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 15, 2016, 3:35 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Re: Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Mesos ReviewBot

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/#review142300
---



Patch looks great!

Reviews applied: [50044]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' 
CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; 
./support/docker_build.sh

- Mesos ReviewBot


On July 14, 2016, 7:35 p.m., Benjamin Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50044/
> ---
> 
> (Updated July 14, 2016, 7:35 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> We now prefer to use vector rather than list in general for
> efficiency reasons, unless we need to take advantage of the
> operations that are efficient on a linked-list.
> 
> 
> Diffs
> -
> 
>   src/master/allocator/sorter/drf/sorter.hpp 
> e29feebd70277c79f7c3f6fb233e7a36501cf220 
>   src/master/allocator/sorter/drf/sorter.cpp 
> 7df4dd641b21ea0705368861bf4679fed1ef078d 
>   src/master/allocator/sorter/sorter.hpp 
> f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
>   src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 
> 
> Diff: https://reviews.apache.org/r/50044/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> benchmarks: with 1000 clients, sort time is reduced by 72 us
> 
> 
> Thanks,
> 
> Benjamin Mahler
> 
>



Review Request 50044: Updated Sorter::sort to return a vector rather than list.

2016-07-14 Thread Benjamin Mahler

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50044/
---

Review request for mesos, Guangya Liu, Klaus Ma, and Jiang Yan Xu.


Repository: mesos


Description
---

We now prefer to use vector rather than list in general for
efficiency reasons, unless we need to take advantage of the
operations that are efficient on a linked-list.


Diffs
-

  src/master/allocator/sorter/drf/sorter.hpp 
e29feebd70277c79f7c3f6fb233e7a36501cf220 
  src/master/allocator/sorter/drf/sorter.cpp 
7df4dd641b21ea0705368861bf4679fed1ef078d 
  src/master/allocator/sorter/sorter.hpp 
f5f0b086cb95eb2ab70b3f67e5b20814925bf702 
  src/tests/sorter_tests.cpp bdd4355bfcd7b1fa1c22983f8e0ee6f20906917a 

Diff: https://reviews.apache.org/r/50044/diff/


Testing
---

make check

benchmarks: with 1000 clients, sort time is reduced by 72 us


Thanks,

Benjamin Mahler