Skip to content

Commit

Permalink
This commit is fix the issue in previous commit:
Browse files Browse the repository at this point in the history
https://review.opencontrail.org/#/c/5763

As part of previous commit we were increasing max # of threads available
as part of the task library.
In previous fix we did not take care of the scenario after TaskScheduler class
initialization.

This checkin takes care of scenario after TaskScheduler instantiation.

Change-Id: I6f5568847ea6af2bdc045c29056b1271e64a1a68
Closes-Bug: 1400208
  • Loading branch information
chandanjuniper committed Apr 28, 2015
1 parent 0eca5f7 commit 92023f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/base/task.cc
Expand Up @@ -270,7 +270,7 @@ int TaskScheduler::GetThreadCount() {
static int num_cores_;

if (init_) {
return num_cores_;
return num_cores_ * ThreadAmpFactor_;
}

char *num_cores_str = getenv("TBB_THREAD_COUNT");
Expand Down

0 comments on commit 92023f3

Please sign in to comment.