-
Notifications
You must be signed in to change notification settings - Fork 45
Adding command line parameter to specify the number of HHVM Server Th… #80
Adding command line parameter to specify the number of HHVM Server Th… #80
Conversation
…reads as well as the benchmark concurrency. In order to use these options they must be paired with '--i-am-not-benchmarking' For HHVM Server Threads use: --hhvm-server-threads=<desiredNumber> The default is 100 For Benchmark Concurrency use: --benchmark-concurrency=<desiredNumber> The default is 200
…reads as well as Benchmark Concurrency. These options are to be paired with '--i-am-not-benchmarking' For HHVM Server threads: --hhvm-server-threads=<number> Default is 100 For Benchmark Concurrency --benchmark-concurrency=<number> Default is 200
base/PerfOptions.php
Outdated
} else { | ||
$this->benchmarkConcurrency = '200'; | ||
} | ||
$bmConcurrency = __DIR__.'/PerfSettings.php'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope, don't modify this file.
- nothing that modifies 'git status' is OK
- moving it to
PerfOptions
is the correct thing to do.
IMHO, these should not require --i-am-not-benchmarking. These need to be tuned in order to benchmark the full capability of a machine. We've already run into a machine where 100 server threads constrains us to fewer software threads than available hardware threads. |
… (--server-threads=<NUM>) and the BenchmarkConcurrency (--benchmark-concurrency=<NUM>). Revising the method that these are set, using a setter method in PerfSettings.php for the BenchmarkConcurrency, set from PerfOptions.php. For ServerThreads we append the dhhvm.server.thread_count to the hhvmExtraArguments array. This is just a wrapper for the optional method of specifying via --hhvm-extra-arguments=-dhhvm.server.thread_count=<NUM>.
…-threads and --client-threads.
base/PerfOptions.php
Outdated
|
||
if(array_key_exists('server-threads', $o)){ | ||
$this->serverThreads = $this->args['server-threads']; | ||
$this->hhvmExtraArguments[count($this->hhvmExtraArguments)] = '-dhhvm.server.thread_count='.$this->serverThreads; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
serverThreads
should be set by default to 100, and it should be removed from the config files https://github.com/hhvm/oss-performance/blob/master/conf/php.ini#L20. Probably don't use the hhvm extra args for this, and just add another argument in https://github.com/hhvm/oss-performance/blob/master/base/HHVMDaemon.php#L70
base/PerfOptions.php
Outdated
|
||
if(array_key_exists('client-threads', $o)){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also needs a default.
@fredemmott Can you take another look and approve? |
base/PerfOptions.php
Outdated
@@ -107,6 +107,8 @@ | |||
public ?string $scriptBeforeWarmup; | |||
public ?string $scriptAfterWarmup; | |||
public ?string $scriptAfterBenchmark; | |||
public ?string $serverThreads = '100'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this not be optionally null? You set a default here, so it should never be null.
base/PerfSettings.php
Outdated
public static function BenchmarkConcurrency(): int { | ||
return 200; | ||
return PerfSettings::$benchmarkConcurrency; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we actually remove benchmark concurrency settings here, and use the options instead in base/Siege.php
? (So basically just make it similar to the way the serverThreads
option works)
I think it will end up cleaner.
@gdbentley Everything looks good now, except I added support for fpm. If you could make the number of children variable here https://github.com/hhvm/oss-performance/blob/master/conf/php-fpm.conf.in#L27. This is how other settings like that are written into place https://github.com/hhvm/oss-performance/blob/master/base/PHP5Daemon.php#L87 |
…mote machine to host the mysql database. This option is to be used with "--i-am-not-benchmarking". Changes were made in PerfOptions.php for the command line parsing, and DatabaseInstaller.php for installing the database. Drupal7, Mediawiki, and Wordpress are the targets which support this feature presently. For more info on how to run please see "Enabling_MySWL_Remote_Connection.txt". Resolving requested changes. Resolved requested changes. Added remote db support for all targets. Making $host local for cleanliness. updating oss-performance to work with recent changes to invariant sig… (facebookarchive#78) * updating oss-performance to work with recent changes to invariant signature * updating change to reflect comments * changing %s to %f for a numeric value Update siege blacklist to 3.0 Updated mediawiki to 1.28. Added setup script, php fpm support, modified batch run to be able to configure databases, fixed tc-print, and perf. Update fbcode option for use with buck. Add processor affinity setting "--cpu-fraction". Add no-jit option, and stat-cache option. Adding command line parameter to specify the number of HHVM Server Th… (facebookarchive#80) * Adding command line parameters to change the number of hhvm server threads as well as the benchmark concurrency. In order to use these options they must be paired with '--i-am-not-benchmarking' For HHVM Server Threads use: --hhvm-server-threads=<desiredNumber> The default is 100 For Benchmark Concurrency use: --benchmark-concurrency=<desiredNumber> The default is 200 * Adding command line parameter to specify the number of HHVM Server Threads as well as Benchmark Concurrency. These options are to be paired with '--i-am-not-benchmarking' For HHVM Server threads: --hhvm-server-threads=<number> Default is 100 For Benchmark Concurrency --benchmark-concurrency=<number> Default is 200 * Adding command line parameters to specify the number of ServerThreads (--server-threads=<NUM>) and the BenchmarkConcurrency (--benchmark-concurrency=<NUM>). Revising the method that these are set, using a setter method in PerfSettings.php for the BenchmarkConcurrency, set from PerfOptions.php. For ServerThreads we append the dhhvm.server.thread_count to the hhvmExtraArguments array. This is just a wrapper for the optional method of specifying via --hhvm-extra-arguments=-dhhvm.server.thread_count=<NUM>. * Made it so we do not have to use --i-am-not-benchmarking for --server-threads and --client-threads. * Resolved review comments. * Resolving requested changes. * Resolving requested changes, made pm.max_children variable.
…reads as well as Benchmark Concurrency.
These options are to be paired with '--i-am-not-benchmarking'
For HHVM Server threads:
--hhvm-server-threads=
Default is 100
For Benchmark Concurrency
--benchmark-concurrency=
Default is 200