summaryrefslogtreecommitdiff
path: root/ext/web/benches/encoding.rs
AgeCommit message (Collapse)Author
2024-02-04chore: bump deno core (#22243)Matt Mastracci
Migrations: - Error registration no longer required for Interrupted or BadResource (these are core exception) - `include_js_files!`/`ExtensionFileSource` changes
2024-01-01chore: update copyright to 2024 (#21753)David Sherret
2023-10-09refactor: remove TimersPermissions::check_unstable (#20831)Bartek Iwańczuk
This is dead code that was not used in any way. Ref https://github.com/denoland/deno/pull/20797
2023-07-31refactor: update core extension api usage (#19952)Nayeem Rahman
2023-07-02Reland "fix(cli): don't store blob and data urls in the module cache" (#18581)Nayeem Rahman
Relands #18261 now that https://github.com/lucacasonato/esbuild_deno_loader/pull/54 is landed and used by fresh. Fixes #18260.
2023-06-26Revert "Reland "refactor(core): cleanup feature flags for js source i… ↵Bartek Iwańczuk
(#19611) …nclusion" (#19519)" This reverts commit 28a4f3d0f5383695b1d49ccdc8b0f799a715b2c2. This change causes failures when used outside Deno repo: ``` ============================================================ Deno has panicked. This is a bug in Deno. Please report this at https://github.com/denoland/deno/issues/new. If you can reliably reproduce this panic, include the reproduction steps and re-run with the RUST_BACKTRACE=1 env var set and include the backtrace in your report. Platform: linux x86_64 Version: 1.34.3+b37b286 Args: ["/opt/hostedtoolcache/deno/0.0.0-b37b286f7fa68d5656f7c180f6127bdc38cf2cf5/x64/deno", "test", "--doc", "--unstable", "--allow-all", "--coverage=./cov"] thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Failed to read "/home/runner/work/deno/deno/core/00_primordials.js" Caused by: No such file or directory (os error 2)', core/runtime/jsruntime.rs:699:8 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace ```
2023-06-25Reland "refactor(core): cleanup feature flags for js source inclusion" (#19519)Nayeem Rahman
Relands #19463. This time the `ExtensionFileSourceCode` enum is preserved, so this effectively just splits feature `include_js_for_snapshotting` into `exclude_js_sources` and `runtime_js_sources`, adds a `force_include_js_sources` option on `extension!()`, and unifies `ext::Init_ops_and_esm()` and `ext::init_ops()` into `ext::init()`.
2023-06-13Revert "refactor(core): cleanup feature flags for js source inclusion… ↵Bartek Iwańczuk
(#19490) … (#19463)" This reverts commit ceb03cfb037cf7024a5048b17b508ddda59cfa05. This is being reverted because it causes 3.5Mb increase in the binary size, due to runtime JS code being included in the binary, even though it's already snapshotted. CC @nayeemrmn
2023-06-13refactor(core): cleanup feature flags for js source inclusion (#19463)Nayeem Rahman
Remove `ExtensionFileSourceCode::LoadedFromFsDuringSnapshot` and feature `include_js_for_snapshotting` since they leak paths that are only applicable in this repo to embedders. Replace with feature `exclude_js_sources`. Additionally the feature `force_include_js_sources` allows negating it, if both features are set. We need both of these because features are additive and there must be a way of force including sources for snapshot creation while still having the `exclude_js_sources` feature. `force_include_js_sources` is only set for build deps, so sources are still excluded from the final binary. You can also specify `force_include_js_sources` on any extension to override the above features for that extension. Towards #19398. But there was still the snapshot-from-snapshot situation where code could be executed twice, I addressed that by making `mod_evaluate()` and scripts like `core/01_core.js` behave idempotently. This allowed unifying `ext::init_ops()` and `ext::init_ops_and_esm()` into `ext::init()`.
2023-05-09bench: fix benchmarks with extensions (#19059)Bartek Iwańczuk
They broke in f34fcd16ea4d504c8a87c0873c65598d70bb1d07
2023-03-18perf(core): use static specifier in ExtensionFileSource (#18271)Bartek Iwańczuk
Relanding #18264 ------- Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>
2023-03-18Revert "perf(core): use static specifier in ExtensionFileSource (#182… ↵Bartek Iwańczuk
(#18270) …64)" This reverts commit 8af0c8351935ea7c6c0441055d5164908322c9d6. Causes bench stage to fail on CI.
2023-03-18perf(core): use static specifier in ExtensionFileSource (#18264)Divy Srivastava
Closes #18085 --------- Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-03-17feat(core) deno_core::extension! macro to simplify extension registration ↵Matt Mastracci
(#18210) This implements two macros to simplify extension registration and centralize a lot of the boilerplate as a base for future improvements: * `deno_core::ops!` registers a block of `#[op]`s, optionally with type parameters, useful for places where we share lists of ops * `deno_core::extension!` is used to register an extension, and creates two methods that can be used at runtime/snapshot generation time: `init_ops` and `init_ops_and_esm`. --------- Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-03-09refactor: Split extension registration for runtime and snapshotting (#18095)Bartek Iwańczuk
This commit splits "<ext_name>::init" functions into "init_ops" and "init_ops_and_esm". That way we don't have to construct list of ESM sources on each startup if we're running with a snapshot. In a follow up commit "deno_core" will be changed to not have a split between "extensions" and "extensions_with_js" - it will be embedders' responsibility to pass appropriately configured extensions. Prerequisite for https://github.com/denoland/deno/pull/18080
2023-03-08refactor: rename InternalModuleLoader to ExtModuleLoader, use ext: scheme ↵Bartek Iwańczuk
for snapshotted modules (#18041) This commit renames "deno_core::InternalModuleLoader" to "ExtModuleLoader" and changes the specifiers used by the modules loaded from this loader to "ext:". "internal:" scheme was really ambiguous and it's more characters than "ext:", which should result in slightly smaller snapshot size. Closes https://github.com/denoland/deno/issues/18020
2023-03-07refactor(core): don't use Result in ExtensionBuilder::state (#18066)Bartek Iwańczuk
There's no point for this API to expect result. If something fails it should result in a panic during build time to signal to embedder that setup is wrong.
2023-02-28fix(ext/ffi): Remove deno_core::OpState qualifiers, fix ops returning ↵Aapo Alasuutari
pointer defaults (#17959)
2023-02-20refactor(core): definition of "ExtensionFileSource" (#17823)Bartek Iwańczuk
This commit changes definition of "ExtensionFileSource", by changing "code" field to being "ExtensionFileSourceCode" enum. Currently the enum has only a single variant "IncludedInBinary". It is done in preparation to allow embedders to decide if they want to include the source code in the binary when snapshotting (in most cases they shouldn't do that). In the follow up commit we'll add more variants to "ExtensionFileSourceCode". "include_js_files_dir!" macro was removed in favor "include_js_files!" macro which can now accept "dir" option.
2023-02-08refactor(core): change SourcePair to ExtensionFileSource (#17686)Bartek Iwańczuk
2023-02-07 refactor: remove prefix from include_js_files & use extension name (#17683)Leo Kettmeir
2023-02-07refactor: Use ES modules for internal runtime code (#17648)Leo Kettmeir
This PR refactors all internal js files (except core) to be written as ES modules. `__bootstrap`has been mostly replaced with static imports in form in `internal:[path to file from repo root]`. To specify if files are ESM, an `esm` method has been added to `Extension`, similar to the `js` method. A new ModuleLoader called `InternalModuleLoader` has been added to enable the loading of internal specifiers, which is used in all situations except when a snapshot is only loaded, and not a new one is created from it. --------- Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-01-14chore: use rustfmt imports_granularity option (#17421)Divy Srivastava
Closes https://github.com/denoland/deno/issues/2699 Closes https://github.com/denoland/deno/issues/2347 Uses unstable rustfmt features. Since dprint invokes `rustfmt` we do not need to switch the cargo toolchain to nightly. Do we care about formatting stability of our codebase across Rust versions? (I don't)
2023-01-13chore: add `copyright_checker` tool and add the missing copyright (#17285)Yiyu Lin
2023-01-08feat(core): allow specifying name and dependencies of an Extension (#17301)Leo Kettmeir
2022-05-17chore: fix failing bench (#14644)Bartek Iwańczuk
2022-05-17perf(ext/web): Add fast path for non-streaming TextDecoder (#14217)randomicon00
Co-authored-by: Divy Srivastava <dj.srivastava23@gmail.com>