Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[osh/cmd_exec] Optimize the number of processes started.
command.Simple now has a do_fork attribute which can be turned off. Add more test cases. Addresses issue #254. Score: - Our "score" is 60, compared with 78 for bash (the max) and 57 for yash (the min). - We beat zsh which has a score of 62. - We no longer start more processes than bash in any case. We start FEWER in 17 out of 30 cases! - Oil isn't the minimum in 4 out of 30 cases. There's still at least one of these I think we should handle. Other trivia: - We lost the 'command date | wc -l' optimization, but no other shell does this! - bash starts TWO more processes than other shells, for case 28. - We also behave like yash in optimizing the same way whether we get -c, stdin, or file input. Other shells only optimize -c. TODO: publish these tests.
- Loading branch information
Andy Chu
committed
Mar 29, 2020
1 parent
664c898
commit bcb0da5
Showing
10 changed files
with
283 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.