Commit Graph

80 Commits

Author SHA1 Message Date
Tobias Koppers e16bdfda6c refactor used exports analysis, hashing, code generation, optimizations
to keep track of runtimes, used exports depending on runtime

modules can have different hashes and generated code depending on runtime
chunks are only considered as equal for MergeDuplicateChunks and SplitChunks when exports used in contained modules are equal
added `optimization.usedExports: "global"` to opt-out from used exports analysis per runtime
added `splitChunks.usedExports` and `splitChunks.cacheGroups[x].usedExports` to enable/disable used exports comparing for modules
`splitChunks.usedExports` defaults to `true` in production
2020-07-27 22:40:44 +02:00
evilebottnawi dafa4cd69a chore: setup cspell 2020-03-12 19:51:26 +03:00
Tobias Koppers 4da880e658 remove Array.prototype.reduce calls to simplify code 2020-01-21 09:45:25 +01:00
Emanuele Stoppa e607681277 fix: replaced some TODO with correct types and fixed some runtime issue 2019-11-28 22:48:01 +01:00
Sergey Melyukov bdc61abf82 refactor: merge generators in asset modules 2019-11-26 15:42:37 +01:00
Sergey Melyukov a214be41a0 add deprecation codes 2019-11-14 17:03:15 +03:00
Tobias Koppers 92e362544f Merge tag 'v4.39.3' into next
4.39.3
2019-08-27 19:17:06 +02:00
jamesgeorge007 dfcf3dd5c2 Minor grammatical correction 2019-08-19 20:12:03 +05:30
Tobias Koppers 3675f64e51
Merge pull request #9588 from jamesgeorge007/feat/add-types
chore(WebAssemblyGenerator): Added type metadata
2019-08-19 15:21:28 +02:00
jamesgeorge007 8d3c3c5640 remove extraneous check 2019-08-17 17:54:24 +05:30
jamesgeorge007 aba6ea6928 remove extraneous check 2019-08-17 17:53:09 +05:30
jamesgeorge007 2186d75d74 remove extraneous check 2019-08-17 17:52:51 +05:30
jamesgeorge007 7d45ca1002 Add types
getCountImportedFunc
2019-08-17 17:50:29 +05:30
jamesgeorge007 fbf1d47984 reword 2019-08-17 17:29:49 +05:30
jamesgeorge007 7331de580c minor tweak 2019-08-17 17:28:17 +05:30
jamesgeorge007 60e33163bd fix grammar 2019-08-17 17:26:11 +05:30
jamesgeorge007 b13bdc282a fix typo 2019-08-17 17:24:27 +05:30
Tobias Koppers 1d72a05fed Merge tag 'v4.36.0' into next
4.36.0
2019-07-17 16:02:33 +02:00
ikopeykin 30e747a55d enforce eslint require-hyphen-before-param-description 2019-07-09 23:15:14 +03:00
Tobias Koppers 0505e177f1 add more types and fix/remove TODOs
change Chunk.files to Set
remove checkContext from IgnorePlugin
remove external flag from ExternalModule
2019-06-14 10:45:56 +02:00
Tobias Koppers 924daa105b Use simpler/faster hash function to get a hash number
Use deterministic mangled names for exports
refactor assignDeterministicIds
rename __webpack_init__ function in wasm to ""
fix bug with incorrectly cached StaticExportsDependency
fix bug in hash logic of Module
2019-02-20 22:41:07 +01:00
Tobias Koppers d34d69e62b Merge tag 'v4.29.5' into next
4.29.5
2019-02-19 08:58:46 +01:00
Sven Sauleau 0bb563f073
fix(webassembly): add end instructions 2019-02-10 13:44:29 +01:00
Tobias Koppers cc34ea42b0 add type argument to Module.size
add getSize to Generator
2018-12-05 20:18:59 +01:00
Tobias Koppers dff9278d6b add Module.getSourceTypes
getSourceTypes declares all source types which can be generated
Remove shouldRender in favor of source type testing
2018-12-05 20:18:57 +01:00
Tobias Koppers b146c7ac41 revert incorrect change
The Buffer can be a slice of the underlying buffer
2018-10-23 08:43:21 +02:00
Tobias Koppers d5ad14813f create Source with Buffers for WASM 2018-10-18 12:44:31 +02:00
Tobias Koppers fd0b6aa196 Merge tag 'v4.18.0' into next
4.18.0
2018-09-10 17:44:07 +02:00
Tobias Koppers e0e0061f32 Merge branch 'master' into chore-bump-webassemblyjs11 2018-09-10 15:18:38 +02:00
Tobias Koppers 3bb5263bfd move methods from Module into ModuleGraph 2018-08-21 11:04:40 +02:00
Tobias Koppers c21d59f783 Merge tag 'v4.17.0' into next
4.17.0
2018-08-21 11:02:16 +02:00
Mihail Bodrov 1f954b4f12 Get rid typeof undef in all lib 2018-08-21 03:26:50 +03:00
Tobias Koppers a6e1c0693c add TODOs 2018-08-16 14:10:39 +02:00
Tobias Koppers d6cf42e4c2 merge used with usedExports
usedExports = false now means module is not used
2018-08-06 21:05:11 +02:00
Tobias Koppers c4e0a9f72e Move Module.used and Module.usedExports into ModuleGraph 2018-08-06 21:04:01 +02:00
Tobias Koppers 11e127d162 pass moduleGraph along with multiple methods 2018-08-02 17:54:42 +02:00
Tobias Koppers 4ce109f8c1 change arguments of Generator.generate and Module.source into a object to be easier extensible
add JavascriptModulesPlugin.getHooks().shouldRender to decide if a module should be rendered
2018-08-02 16:07:29 +02:00
Tobias Koppers c9eb4c8e01 Merge tag 'v4.16.4' into next
4.16.4
2018-08-02 16:00:39 +02:00
Florent Cailhol 64e301c33b Update Prettier 2018-07-31 11:44:32 +02:00
Tobias Koppers cf5f1d723c format existing code 2018-07-30 21:29:21 +02:00
Tobias Koppers 0052861178 remove unconsistency with Module._source and originalSource 2018-07-25 12:20:35 +02:00
Sven SAULEAU 38c34030a0
Merge remote-tracking branch 'upstream/master' into chore-bump-webassemblyjs11 2018-07-25 10:06:37 +02:00
Tobias Koppers 66d3f319a6 Merge tag 'v4.16.2' into next
4.16.2
2018-07-23 12:19:16 +02:00
Tobias Koppers 8614c75f11 run inherit types tool on existing code 2018-07-21 13:50:18 +02:00
Sven SAULEAU b310b9b45c
feat: remove LEB128 opt 2018-07-16 13:57:32 +02:00
Tobias Koppers ad8f496745 arrow functions, remove or improve eslint-disable comments 2018-06-27 13:48:13 +02:00
Sven SAULEAU 0288128cb9
feat: get start func from context 2018-06-06 11:06:40 +02:00
Sven SAULEAU 6e85ac5468
feat: use function matcher 2018-06-06 10:39:06 +02:00
Tobias Koppers 8e3be48da4 allow to disable wasm import mangle
disable it by default (temporary)
2018-06-05 23:49:02 +02:00
Tobias Koppers 822c252a09 Merge branch 'master' into fix-wasm-check-for-invalid-signatures
# Conflicts:
#	declarations.d.ts
#	lib/wasm/WebAssemblyParser.js
#	package.json
#	yarn.lock
2018-06-04 13:33:26 +02:00