Comments (6)
Do you have any preferred benchmarking tools, or would repeated runs of a shell script calling time del packages/*/node_modules
in a bootstrapped repo suffice?
from del.
I usually use https://github.com/logicalparadox/matcha
Example: https://github.com/sindresorhus/strip-json-comments/blob/254d84a3826b3a7acba8dc484660a97c43dca821/package.json#L17 https://github.com/sindresorhus/strip-json-comments/blob/254d84a3826b3a7acba8dc484660a97c43dca821/benchmark.js
from del.
Would a default of require('os').cpus().length
(or some derivative thereof) be too naive?
from del.
from del.
I took an initial stab at creating a matcha benchmark test. You can find it in the benchmark
branch of my fork.
I'm probably doing something wrong, but I don't think these tests show an appreciable difference between different concurrency settings. Here's an example run on my machine:
Note that in the initial version of these tests, the first actual deletion has to find and delete half of the 1000 created files, and the last actual deletion deletes the other half.
Let me know if this looks helpful at all. Comments welcomed.
from del.
the benchmarks are fals and you should not optimize that with a concurrency limit as a engine author i can tell you that this is part of v8 already you simply fire your stack of actions in and it takes care of the rest everything else will not be the same as your tests include filesystem operations that take time too
and they depend on the write and delete methods that the filesystem uses and so on
to test the raw performance it would be enough to test how many actions you can fire so how many fsCalls you can put on the stack and again that is also optimized by v8 it self and nodejs abstracts that and maybe makes that even more buggy via its libuv integration the loop is bound to both v8 and libuv which does the I/O processing between the OS and the c code that calls v8
from del.
Related Issues (20)
- Plugin is not working with Electron App HOT 1
- Add `progress` event
- Filenames with parentheses not deleted
- why 'del' restores the files I have deleted using 'rimraf'
- 5. X and 6 X performs wildcard recursive directory deletion, which is invalid
- Weird problem in the npm page HOT 1
- Upgrade: v7 convert to ESM lets Disscuse the API HOT 6
- Error: Cannot delete files/directories outside the current working directory HOT 1
- Release Notes for version 7 are incorrect HOT 1
- Build fail when using Babel HOT 3
- Couldn't delete dot files in del7.0.0 HOT 1
- [v8] Make the `dot` option true by default?
- Cannot find module 'del' HOT 1
- TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" HOT 2
- Protocol 'node:' not supported HOT 1
- Add path to ProgressData
- Build is failing in CI HOT 2
- Update supported engines to >=16 HOT 1
- Why not use rollup to provide a commonjs module? HOT 1
- Unable to require/import this module into gulp HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from del.