Repository: denoland/deno_core
Pull request #690 (2024-04-09 20:43:09)

chore: enable valgrind test

codecov-commenter: ## [Codecov](https://app.codecov.io/gh/denoland/deno_core/pull/690?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=denoland) Report
All modified and coverable lines are covered by tests :white_check_mark:
> Project coverage is 81.13%. Comparing base [(`5245f5d`)](https://app.codecov.io/gh/denoland/deno_core/commit/5245f5defd9c4f4f05323c38ad5a097c87d48346?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=denoland) to head [(`891d3f9`)](https://app.codecov.io/gh/denoland/deno_core/pull/690?dropdown=coverage&src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=denoland).
> Report is 2 commits behind head on main.


<details><summary>Additional details and impacted files</summary>


```diff
@@            Coverage Diff             @@
##             main     #690      +/-   ##
==========================================
- Coverage   81.26%   81.13%   -0.14%     
==========================================
  Files          95       95              
  Lines       24295    24407     +112     
==========================================
+ Hits        19744    19803      +59     
- Misses       4551     4604      +53     
```



</details>

[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/denoland/deno_core/pull/690?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=denoland).   
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=denoland).


Patch:
diff --git a/.github/workflows/ci-job.yml b/.github/workflows/ci-job.yml
index 358df2f..c272478 100644
--- a/.github/workflows/ci-job.yml
+++ b/.github/workflows/ci-job.yml
@@ -42,7 +42,10 @@ jobs:
       - name: Install ARM runner tools
         if: ${{ inputs.os == 'ubuntu-22.04-arm64' }}
         run: |
-          sudo apt update && sudo apt-get install -y unzip clang
+          # Installing packages
+          sudo rm /var/lib/man-db/auto-update || true
+          sudo apt update
+          sudo apt-get install -y --no-install-recommends unzip clang
 
       - name: Install Rust
         uses: dsherret/rust-toolchain-file@v1
@@ -100,6 +103,11 @@ jobs:
         if: inputs.job == 'test-miri'
         uses: ./.github/workflows/ci-test-miri
 
+      - name: Test (valgrind)
+        id: test-valgrind
+        if: inputs.job == 'test-valgrind'
+        uses: ./.github/workflows/ci-test-valgrind
+
       - name: Publish (dry-run)
         id: test-publish
         if: inputs.job == 'test-publish'
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index d140180..f7806f5 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -57,6 +57,9 @@ jobs:
             linux:
               os: ubuntu-latest
               jobs: [coverage, lint, lint-deps, test, test-miri, test-ops, test-publish]
+            linux-xl:
+              os: ubuntu-22.04-xl
+              jobs: [test-valgrind]
             linux-arm:
               os: ubuntu-22.04-arm64
               jobs: [lint, test, test-miri]
diff --git a/Cargo.lock b/Cargo.lock
index 891239e..09bdcae 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -27,6 +27,19 @@ version = "1.0.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe"
 
+[[package]]
+name = "ahash"
+version = "0.8.11"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011"
+dependencies = [
+ "cfg-if",
+ "getrandom",
+ "once_cell",
+ "version_check",
+ "zerocopy",
+]
+
 [[package]]
 name = "aho-corasick"
 version = "1.1.2"
@@ -92,9 +105,9 @@ dependencies = [
 
 [[package]]
 name = "anyhow"
-version = "1.0.79"
+version = "1.0.82"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca"
+checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519"
 
 [[package]]
 name = "ast_node"
@@ -200,9 +213,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"
 
 [[package]]
 name = "bitflags"
-version = "2.4.2"
+version = "2.5.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf"
+checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1"
 
 [[package]]
 name = "bitvec"
@@ -474,14 +487,17 @@ dependencies = [
 
 [[package]]
 name = "deno_ast"
-version = "0.32.0"
+version = "0.35.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d83d58de6f05f4eb41ec518c19067e3e40cd0edd3d366ad95c601bc6e71bdf49"
+checksum = "ebb7284111ad08453aab0d07caf32564de730c9a77f2b94a4b69207b15cf1f2d"
 dependencies = [
  "anyhow",
  "base64",
  "deno_media_type",
+ "deno_terminal",
  "dprint-swc-ext",
+ "once_cell",
+ "percent-encoding",
  "serde",
  "swc_atoms",
  "swc_common",
@@ -505,12 +521,13 @@ dependencies = [
  "swc_visit",
  "swc_visit_macros",
  "text_lines",
+ "unicode-width",
  "url",
 ]
 
 [[package]]
 name = "deno_core"
-version = "0.272.0"
+version = "0.273.0"
 dependencies = [
  "anyhow",
  "bencher",
@@ -536,7 +553,7 @@ dependencies = [
  "serde_json",
  "serde_v8",
  "smallvec",
- "sourcemap 8.0.1",
+ "sourcemap",
  "static_assertions",
  "tokio",
  "unicycle",
@@ -577,7 +594,7 @@ dependencies = [
 
 [[package]]
 name = "deno_ops"
-version = "0.148.0"
+version = "0.149.0"
 dependencies = [
  "pretty_assertions",
  "prettyplease",
@@ -607,6 +624,16 @@ dependencies = [
  "trybuild",
 ]
 
+[[package]]
+name = "deno_terminal"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7e6337d4e7f375f8b986409a76fbeecfa4bd8a1343e63355729ae4befa058eaf"
+dependencies = [
+ "once_cell",
+ "termcolor",
+]
+
 [[package]]
 name = "deno_unsync"
 version = "0.3.2"
@@ -634,11 +661,10 @@ dependencies = [
 
 [[package]]
 name = "dprint-swc-ext"
-version = "0.13.0"
+version = "0.15.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7b2f24ce6b89a06ae3eb08d5d4f88c05d0aef1fa58e2eba8dd92c97b84210c25"
+checksum = "5bad772f9e49af3a613fcddf1671d1e2e877e0a6d94f2b7162bfea4ac8140bee"
 dependencies = [
- "bumpalo",
  "num-bigint",
  "rustc-hash",
  "swc_atoms",
@@ -650,9 +676,9 @@ dependencies = [
 
 [[package]]
 name = "either"
-version = "1.9.0"
+version = "1.10.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07"
+checksum = "11157ac094ffbdde99aa67b23417ebdd801842852b500e395a45a9c0aac03e4a"
 
 [[package]]
 name = "equivalent"
@@ -932,15 +958,16 @@ dependencies = [
 
 [[package]]
 name = "hstr"
-version = "0.2.7"
+version = "0.2.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "17fafeca18cf0927e23ea44d7a5189c10536279dfe9094e0dfa953053fbb5377"
+checksum = "b0f5356d62012374578cd3a5c013d6586de3efbca3b53379fc1edfbb95c9db14"
 dependencies = [
+ "hashbrown",
  "new_debug_unreachable",
  "once_cell",
  "phf",
  "rustc-hash",
- "smallvec",
+ "triomphe",
 ]
 
 [[package]]
@@ -1381,17 +1408,6 @@ dependencies = [
  "plotters-backend",
 ]
 
-[[package]]
-name = "pmutil"
-version = "0.6.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "52a40bc70c2c58040d2d8b167ba9a5ff59fc9dab7ad44771cfde3dcfde7a09c6"
-dependencies = [
- "proc-macro2",
- "quote",
- "syn",
-]
-
 [[package]]
 name = "ppv-lite86"
 version = "0.2.17"
@@ -1633,7 +1649,7 @@ version = "0.38.30"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca"
 dependencies = [
- "bitflags 2.4.2",
+ "bitflags 2.5.0",
  "errno",
  "libc",
  "linux-raw-sys",
@@ -1702,9 +1718,9 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3"
 
 [[package]]
 name = "serde"
-version = "1.0.195"
+version = "1.0.197"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "63261df402c67811e9ac6def069e4786148c4563f4b50fd4bf30aa370d626b02"
+checksum = "3fb1c873e1b9b056a4dc4c0c198b24c3ffa059243875552b2bd0933b1aee4ce2"
 dependencies = [
  "serde_derive",
 ]
@@ -1720,9 +1736,9 @@ dependencies = [
 
 [[package]]
 name = "serde_derive"
-version = "1.0.195"
+version = "1.0.197"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "46fe8f8603d81ba86327b23a2e9cdf49e1255fb94a4c5f297f6ee0547178ea2c"
+checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -1743,7 +1759,7 @@ dependencies = [
 
 [[package]]
 name = "serde_v8"
-version = "0.181.0"
+version = "0.182.0"
 dependencies = [
  "bencher",
  "bytes",
@@ -1852,22 +1868,6 @@ dependencies = [
  "windows-sys 0.48.0",
 ]
 
-[[package]]
-name = "sourcemap"
-version = "6.4.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e4cbf65ca7dc576cf50e21f8d0712d96d4fcfd797389744b7b222a85cdf5bd90"
-dependencies = [
- "data-encoding",
- "debugid",
- "if_chain",
- "rustc_version 0.2.3",
- "serde",
- "serde_json",
- "unicode-id",
- "url",
-]
-
 [[package]]
 name = "sourcemap"
 version = "8.0.1"
@@ -1887,6 +1887,12 @@ dependencies = [
  "url",
 ]
 
+[[package]]
+name = "stable_deref_trait"
+version = "1.2.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3"
+
 [[package]]
 name = "stacker"
 version = "0.1.15"
@@ -1948,9 +1954,9 @@ dependencies = [
 
 [[package]]
 name = "swc_atoms"
-version = "0.6.5"
+version = "0.6.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7d538eaaa6f085161d088a04cf0a3a5a52c5a7f2b3bd9b83f73f058b0ed357c0"
+checksum = "04d9d1941a7d24fc503efa29c53f88dd61e6a15cc371947a75cca3b48d564b5b"
 dependencies = [
  "hstr",
  "once_cell",
@@ -1958,11 +1964,25 @@ dependencies = [
  "serde",
 ]
 
+[[package]]
+name = "swc_cached"
+version = "0.3.20"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "83406221c501860fce9c27444f44125eafe9e598b8b81be7563d7036784cd05c"
+dependencies = [
+ "ahash",
+ "anyhow",
+ "dashmap",
+ "once_cell",
+ "regex",
+ "serde",
+]
+
 [[package]]
 name = "swc_common"
-version = "0.33.12"
+version = "0.33.22"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9b3ae36feceded27f0178dc9dabb49399830847ffb7f866af01798844de8f973"
+checksum = "a8f91d53367db183e55ecaa090c9a2b6e62ddbd1258aa2ac6c6925772eec9e2b"
 dependencies = [
  "ast_node",
  "better_scoped_tls",
@@ -1975,7 +1995,7 @@ dependencies = [
  "rustc-hash",
  "serde",
  "siphasher",
- "sourcemap 6.4.1",
+ "sourcemap",
  "swc_atoms",
  "swc_eq_ignore_macros",
  "swc_visit",
@@ -1986,13 +2006,15 @@ dependencies = [
 
 [[package]]
 name = "swc_config"
-version = "0.1.9"
+version = "0.1.12"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "112884e66b60e614c0f416138b91b8b82b7fea6ed0ecc5e26bad4726c57a6c99"
+checksum = "ada712ac5e28a301683c8af957e8a56deca675cbc376473dd207a527b989efb5"
 dependencies = [
+ "anyhow",
  "indexmap",
  "serde",
  "serde_json",
+ "swc_cached",
  "swc_config_macro",
 ]
 
@@ -2010,11 +2032,11 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_ast"
-version = "0.110.17"
+version = "0.112.7"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "79401a45da704f4fb2552c5bf86ee2198e8636b121cb81f8036848a300edd53b"
+checksum = "6bcd97ee367b48444f90416ea56e71d761600f816bcae9df4f99293d1fa36bd5"
 dependencies = [
- "bitflags 2.4.2",
+ "bitflags 2.5.0",
  "is-macro",
  "num-bigint",
  "phf",
@@ -2023,21 +2045,21 @@ dependencies = [
  "string_enum",
  "swc_atoms",
  "swc_common",
- "unicode-id",
+ "unicode-id-start",
 ]
 
 [[package]]
 name = "swc_ecma_codegen"
-version = "0.146.54"
+version = "0.148.14"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "99b61ca275e3663238b71c4b5da8e6fb745bde9989ef37d94984dfc81fc6d009"
+checksum = "a1e318142ff1297c1d3d8f230b4f3eda8454d1420341fb098a9d9edbc373ef3c"
 dependencies = [
  "memchr",
  "num-bigint",
  "once_cell",
  "rustc-hash",
  "serde",
- "sourcemap 6.4.1",
+ "sourcemap",
  "swc_atoms",
  "swc_common",
  "swc_ecma_ast",
@@ -2059,22 +2081,23 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_loader"
-version = "0.45.13"
+version = "0.45.25"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c5713ab3429530c10bdf167170ebbde75b046c8003558459e4de5aaec62ce0f1"
+checksum = "ea397a556585ffd78cda6ef420f6fd0ad54320778930eeb876f02041f58bb017"
 dependencies = [
  "anyhow",
  "pathdiff",
  "serde",
+ "swc_atoms",
  "swc_common",
  "tracing",
 ]
 
 [[package]]
 name = "swc_ecma_parser"
-version = "0.141.37"
+version = "0.143.12"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c4d17401dd95048a6a62b777d533c0999dabdd531ef9d667e22f8ae2a2a0d294"
+checksum = "b6fc7ab256f83a9491b37a510dd1cba9d81bb306faf3cff1dacdbc897fa4869f"
 dependencies = [
  "either",
  "new_debug_unreachable",
@@ -2094,12 +2117,12 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_transforms_base"
-version = "0.135.11"
+version = "0.137.17"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6d4ab26ec124b03e47f54d4daade8e9a9dcd66d3a4ca3cd47045f138d267a60e"
+checksum = "66b5818db80d8d9fcbc1d3453f1d246a7f56ea708ba136717a84a8caf0977afd"
 dependencies = [
  "better_scoped_tls",
- "bitflags 2.4.2",
+ "bitflags 2.5.0",
  "indexmap",
  "once_cell",
  "phf",
@@ -2117,9 +2140,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_transforms_classes"
-version = "0.124.11"
+version = "0.126.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9fe4376c024fa04394cafb8faecafb4623722b92dbbe46532258cc0a6b569d9c"
+checksum = "47af84e64f0216f110839f5552a615d07ed74b45757927f29482700966ab4e97"
 dependencies = [
  "swc_atoms",
  "swc_common",
@@ -2143,9 +2166,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_transforms_proposal"
-version = "0.169.16"
+version = "0.171.20"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ed89d6ff74f60de490fb56e1cc505b057905e36c13d405d7d61dd5c9f6ee8fc9"
+checksum = "ac54efb40cb374c53323823da2b5f74406b8531b59a2cb689801cbf22d0057db"
 dependencies = [
  "either",
  "rustc-hash",
@@ -2163,9 +2186,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_transforms_react"
-version = "0.181.18"
+version = "0.183.18"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e31a2f879fd21d18080b6c42e633e0ae8c6f3d54b83c1de876767d82b458c999"
+checksum = "1b7b7de90ff41560bf021acda3fb16fb0f4f5885aeb44b6b7e638b563124d087"
 dependencies = [
  "base64",
  "dashmap",
@@ -2187,9 +2210,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_transforms_typescript"
-version = "0.186.17"
+version = "0.188.18"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3e4263372cc7cd1a3b4570ccf7438f3c1e1575f134fd05cdf074edb322480a5b"
+checksum = "845c3ad4949c2317076e929e42c78dd43868f6c6f820911353731a5bb859e78c"
 dependencies = [
  "ryu-js",
  "serde",
@@ -2204,9 +2227,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_utils"
-version = "0.125.4"
+version = "0.127.17"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7cead1083e46b0f072a82938f16d366014468f7510350957765bb4d013496890"
+checksum = "624c19fdbe1807275b16560892cf7a12a9ac3f631fb10ad45aaa3eeac903e6e5"
 dependencies = [
  "indexmap",
  "num_cpus",
@@ -2222,9 +2245,9 @@ dependencies = [
 
 [[package]]
 name = "swc_ecma_visit"
-version = "0.96.17"
+version = "0.98.7"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a1d0100c383fb08b6f34911ab6f925950416a5d14404c1cd520d59fb8dfbb3bf"
+checksum = "93692bdcdbb63db8f5e10fea5d202b5487cb27eb443aec424f4335c88f9864af"
 dependencies = [
  "num-bigint",
  "swc_atoms",
@@ -2258,9 +2281,9 @@ dependencies = [
 
 [[package]]
 name = "swc_visit"
-version = "0.5.8"
+version = "0.5.12"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b27078d8571abe23aa52ef608dd1df89096a37d867cf691cbb4f4c392322b7c9"
+checksum = "7dcfe07ffcd4360d6bf69d75819ccf6c6db852dfbf0f35dd65e9296a2b25c070"
 dependencies = [
  "either",
  "swc_visit_macros",
@@ -2268,12 +2291,11 @@ dependencies = [
 
 [[package]]
 name = "swc_visit_macros"
-version = "0.5.9"
+version = "0.5.11"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fa8bb05975506741555ea4d10c3a3bdb0e2357cd58e1a4a4332b8ebb4b44c34d"
+checksum = "33fc817055fe127b4285dc85058596768bfde7537ae37da82c67815557f03e33"
 dependencies = [
  "Inflector",
- "pmutil",
  "proc-macro2",
  "quote",
  "swc_macros_common",
@@ -2451,6 +2473,16 @@ dependencies = [
  "once_cell",
 ]
 
+[[package]]
+name = "triomphe"
+version = "0.1.11"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "859eb650cfee7434994602c3a68b25d77ad9e68c8a6cd491616ef86661382eb3"
+dependencies = [
+ "serde",
+ "stable_deref_trait",
+]
+
 [[package]]
 name = "try-lock"
 version = "0.2.5"
@@ -2581,7 +2613,7 @@ version = "0.89.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "fe2197fbef82c98f7953d13568a961d4e1c663793b5caf3c74455a13918cdf33"
 dependencies = [
- "bitflags 2.4.2",
+ "bitflags 2.5.0",
  "fslock",
  "gzip-header",
  "home",
@@ -2875,3 +2907,23 @@ name = "yansi"
 version = "0.5.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec"
+
+[[package]]
+name = "zerocopy"
+version = "0.7.32"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be"
+dependencies = [
+ "zerocopy-derive",
+]
+
+[[package]]
+name = "zerocopy-derive"
+version = "0.7.32"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn",
+]
diff --git a/Cargo.toml b/Cargo.toml
index 6c9c453..f5b9107 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -19,12 +19,12 @@ repository = "https://github.com/denoland/deno_core"
 
 [workspace.dependencies]
 # Local dependencies
-deno_core = { version = "0.272.0", path = "./core" }
-deno_ops = { version = "0.148.0", path = "./ops" }
-serde_v8 = { version = "0.181.0", path = "./serde_v8" }
+deno_core = { version = "0.273.0", path = "./core" }
+deno_ops = { version = "0.149.0", path = "./ops" }
+serde_v8 = { version = "0.182.0", path = "./serde_v8" }
 
 v8 = { version = "0.89.0", default-features = false }
-deno_ast = { version = "=0.32.0", features = ["transpiling"] }
+deno_ast = { version = "=0.35.2", features = ["transpiling"] }
 deno_unsync = "0.3.2"
 deno_core_icudata = "0.0.73"
 
@@ -66,6 +66,10 @@ quote = "1"
 syn = { version = "2", features = ["full", "extra-traits"] }
 proc-macro-rules = "0.4.0"
 
+[profile.dev.package.v8]
+# v8 miscompiles at opt-level=0
+opt-level = 1
+
 # NB: the `bench` and `release` profiles must remain EXACTLY the same.
 [profile.release]
 codegen-units = 1
diff --git a/core/Cargo.toml b/core/Cargo.toml
index 8b6f985..eb8372a 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -2,7 +2,7 @@
 
 [package]
 name = "deno_core"
-version = "0.272.0"
+version = "0.273.0"
 authors.workspace = true
 edition.workspace = true
 license.workspace = true
diff --git a/core/benches/snapshot/snapshot.rs b/core/benches/snapshot/snapshot.rs
index 7c01711..64ee014 100644
--- a/core/benches/snapshot/snapshot.rs
+++ b/core/benches/snapshot/snapshot.rs
@@ -2,6 +2,7 @@
 use criterion::*;
 use deno_ast::MediaType;
 use deno_ast::ParseParams;
+use deno_ast::SourceMapOption;
 use deno_ast::SourceTextInfo;
 use deno_core::error::AnyError;
 use deno_core::Extension;
@@ -14,6 +15,7 @@ use deno_core::SourceMapData;
 use std::rc::Rc;
 use std::time::Duration;
 use std::time::Instant;
+use url::Url;
 
 macro_rules! fake_extensions {
   ($which:ident, $($name:ident),+) => (
@@ -55,7 +57,7 @@ pub fn maybe_transpile_source(
   let media_type = MediaType::TypeScript;
 
   let parsed = deno_ast::parse_module(ParseParams {
-    specifier: specifier.to_string(),
+    specifier: Url::parse(&specifier).unwrap(),
     text_info: SourceTextInfo::from_string(source.as_str().to_owned()),
     media_type,
     capture_tokens: false,
@@ -64,8 +66,7 @@ pub fn maybe_transpile_source(
   })?;
   let transpiled_source = parsed.transpile(&deno_ast::EmitOptions {
     imports_not_used_as_values: deno_ast::ImportsNotUsedAsValues::Remove,
-    inline_source_map: false,
-    source_map: true,
+    source_map: SourceMapOption::Separate,
     inline_sources: true,
     ..Default::default()
   })?;
diff --git a/core/examples/ts_module_loader.rs b/core/examples/ts_module_loader.rs
index 436ec52..816b06b 100644
--- a/core/examples/ts_module_loader.rs
+++ b/core/examples/ts_module_loader.rs
@@ -14,6 +14,7 @@ use anyhow::Context;
 use anyhow::Error;
 use deno_ast::MediaType;
 use deno_ast::ParseParams;
+use deno_ast::SourceMapOption;
 use deno_ast::SourceTextInfo;
 use deno_core::error::AnyError;
 use deno_core::resolve_import;
@@ -97,7 +98,7 @@ impl ModuleLoader for TypescriptModuleLoader {
       let code = std::fs::read_to_string(&path)?;
       let code = if should_transpile {
         let parsed = deno_ast::parse_module(ParseParams {
-          specifier: module_specifier.to_string(),
+          specifier: module_specifier.clone(),
           text_info: SourceTextInfo::from_string(code),
           media_type,
           capture_tokens: false,
@@ -105,8 +106,7 @@ impl ModuleLoader for TypescriptModuleLoader {
           maybe_syntax: None,
         })?;
         let res = parsed.transpile(&deno_ast::EmitOptions {
-          inline_source_map: false,
-          source_map: true,
+          source_map: SourceMapOption::Separate,
           inline_sources: true,
           ..Default::default()
         })?;
diff --git a/core/extension_set.rs b/core/extension_set.rs
index 4be2485..c56c7f4 100644
--- a/core/extension_set.rs
+++ b/core/extension_set.rs
@@ -129,6 +129,7 @@ pub fn create_op_ctxs(
   let op_count = op_decls.len();
   let mut op_ctxs = Vec::with_capacity(op_count);
 
+  let runtime_state_ptr = runtime_state.as_ref() as *const _;
   for (index, decl) in op_decls.into_iter().enumerate() {
     let metrics_fn = op_metrics_factory_fn
       .as_ref()
@@ -140,7 +141,7 @@ pub fn create_op_ctxs(
       op_driver.clone(),
       decl,
       op_state.clone(),
-      runtime_state.clone(),
+      runtime_state_ptr,
       get_error_class_fn,
       metrics_fn,
     );
diff --git a/core/io/resource_table.rs b/core/io/resource_table.rs
index d9e5191..49157d2 100644
--- a/core/io/resource_table.rs
+++ b/core/io/resource_table.rs
@@ -85,16 +85,12 @@ impl ResourceTable {
       .index
       .get(&rid)
       .and_then(|rc| rc.downcast_rc::<T>())
-      .map(Clone::clone)
+      .cloned()
       .ok_or_else(bad_resource_id)
   }
 
   pub fn get_any(&self, rid: ResourceId) -> Result<Rc<dyn Resource>, Error> {
-    self
-      .index
-      .get(&rid)
-      .map(Clone::clone)
-      .ok_or_else(bad_resource_id)
+    self.index.get(&rid).cloned().ok_or_else(bad_resource_id)
   }
 
   /// Replaces a resource with a new resource.
diff --git a/core/lib.rs b/core/lib.rs
index 20001d6..a292a5f 100644
--- a/core/lib.rs
+++ b/core/lib.rs
@@ -136,6 +136,7 @@ pub use crate::ops_metrics::OpMetricsSummaryTracker;
 pub use crate::path::strip_unc_prefix;
 pub use crate::runtime::stats;
 pub use crate::runtime::CompiledWasmModuleStore;
+pub use crate::runtime::ContextState;
 pub use crate::runtime::CreateRealmOptions;
 pub use crate::runtime::CrossIsolateStore;
 pub use crate::runtime::JsRuntime;
diff --git a/core/ops.rs b/core/ops.rs
index 12c3730..4709782 100644
--- a/core/ops.rs
+++ b/core/ops.rs
@@ -96,7 +96,7 @@ pub struct OpCtx {
   pub(crate) last_fast_error: UnsafeCell<Option<AnyError>>,
 
   op_driver: Rc<OpDriverImpl>,
-  runtime_state: Rc<JsRuntimeState>,
+  runtime_state: *const JsRuntimeState,
 }
 
 impl OpCtx {
@@ -107,7 +107,7 @@ impl OpCtx {
     op_driver: Rc<OpDriverImpl>,
     decl: OpDecl,
     state: Rc<RefCell<OpState>>,
-    runtime_state: Rc<JsRuntimeState>,
+    runtime_state: *const JsRuntimeState,
     get_error_class_fn: GetErrorClassFn,
     metrics_fn: Option<OpMetricsFn>,
   ) -> Self {
@@ -245,7 +245,8 @@ impl OpCtx {
 
   /// Get the [`JsRuntimeState`] for this op.
   pub(crate) fn runtime_state(&self) -> &JsRuntimeState {
-    &self.runtime_state
+    // SAFETY: JsRuntimeState outlives OpCtx
+    unsafe { &*self.runtime_state }
   }
 }
 
diff --git a/core/runtime/jsrealm.rs b/core/runtime/jsrealm.rs
index c2a85be..ab8e15c 100644
--- a/core/runtime/jsrealm.rs
+++ b/core/runtime/jsrealm.rs
@@ -49,7 +49,7 @@ impl Hasher for IdentityHasher {
 /// We may wish to experiment with alternative drivers in the future.
 pub(crate) type OpDriverImpl = super::op_driver::FuturesUnorderedDriver;
 
-pub(crate) struct ContextState {
+pub struct ContextState {
   pub(crate) task_spawner_factory: Arc<V8TaskSpawnerFactory>,
   pub(crate) timers: WebTimers<(v8::Global<v8::Function>, u32)>,
   pub(crate) js_event_loop_tick_cb:
diff --git a/core/runtime/mod.rs b/core/runtime/mod.rs
index 4ef8412..5312591 100644
--- a/core/runtime/mod.rs
+++ b/core/runtime/mod.rs
@@ -18,7 +18,7 @@ mod tests;
 pub const V8_WRAPPER_TYPE_INDEX: i32 = 0;
 pub const V8_WRAPPER_OBJECT_INDEX: i32 = 1;
 
-pub(crate) use jsrealm::ContextState;
+pub use jsrealm::ContextState;
 pub(crate) use jsrealm::JsRealm;
 pub(crate) use jsrealm::OpDriverImpl;
 pub use jsruntime::CompiledWasmModuleStore;
diff --git a/core/runtime/ops.rs b/core/runtime/ops.rs
index f616a26..6532b09 100644
--- a/core/runtime/ops.rs
+++ b/core/runtime/ops.rs
@@ -537,6 +537,11 @@ mod tests {
   use std::rc::Rc;
   use std::time::Duration;
 
+  /// Enough to get functions to JIT.
+  pub const JIT_ITERATIONS: usize = 6000;
+  /// For slower tests. Doesn't guarantee a JIT.
+  pub const JIT_SLOW_ITERATIONS: usize = 500;
+
   deno_core::extension!(
     testing,
     ops = [
@@ -762,17 +767,33 @@ mod tests {
   /// Test various numeric coercions in fast and slow mode.
   #[tokio::test(flavor = "current_thread")]
   pub async fn test_op_add() -> Result<(), Box<dyn std::error::Error>> {
-    run_test2(10000, "op_test_add", "assert(op_test_add(1, 11) == 12)")?;
-    run_test2(10000, "op_test_add", "assert(op_test_add(11, -1) == 10)")?;
-    run_test2(10000, "op_test_add", "assert(op_test_add(1.5, 11.5) == 12)")?;
-    run_test2(10000, "op_test_add", "assert(op_test_add(11.5, -1) == 10)")?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
+      "op_test_add",
+      "assert(op_test_add(1, 11) == 12)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
+      "op_test_add",
+      "assert(op_test_add(11, -1) == 10)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
+      "op_test_add",
+      "assert(op_test_add(1.5, 11.5) == 12)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
+      "op_test_add",
+      "assert(op_test_add(11.5, -1) == 10)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
       "op_test_add",
       "assert(op_test_add(4096n, 4096n) == 4096 + 4096)",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_add",
       "assert(op_test_add(8192n, -4096n) == 4096)",
     )?;
@@ -791,12 +812,12 @@ mod tests {
   #[tokio::test(flavor = "current_thread")]
   pub async fn test_op_add_smi() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_add_smi_unsigned",
       "assert(op_test_add_smi_unsigned(1000, 2000) == 3000)",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_add_smi_unsigned",
       "assert(op_test_add_smi_unsigned(-1000, 10) == -990)",
     )?;
@@ -856,11 +877,15 @@ mod tests {
   pub async fn test_op_result_void() -> Result<(), Box<dyn std::error::Error>> {
     // Test the non-switching kinds
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_result_void_err",
       "try { op_test_result_void_err(); assert(false) } catch (e) {}",
     )?;
-    run_test2(10000, "op_test_result_void_ok", "op_test_result_void_ok()")?;
+    run_test2(
+      JIT_ITERATIONS,
+      "op_test_result_void_ok",
+      "op_test_result_void_ok()",
+    )?;
     Ok(())
   }
 
@@ -869,7 +894,7 @@ mod tests {
   ) -> Result<(), Box<dyn std::error::Error>> {
     RETURN_COUNT.with(|count| count.set(0));
     let err = run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_result_void_switch",
       "op_test_result_void_switch();",
     )
@@ -894,12 +919,12 @@ mod tests {
   pub async fn test_op_result_primitive(
   ) -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_result_primitive_err",
       "try { op_test_result_primitive_err(); assert(false) } catch (e) {}",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_result_primitive_ok",
       "op_test_result_primitive_ok()",
     )?;
@@ -923,12 +948,12 @@ mod tests {
   #[tokio::test]
   pub async fn test_op_bool() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_bool",
       "assert(op_test_bool(true) === true && op_test_bool(false) === false)",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_test_bool_result",
       "assert(op_test_bool_result(true) === true)",
     )?;
@@ -957,9 +982,13 @@ mod tests {
 
   #[tokio::test]
   pub async fn test_op_float() -> Result<(), Box<dyn std::error::Error>> {
-    run_test2(10000, "op_test_float", "assert(op_test_float(1, 10) == 11)")?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
+      "op_test_float",
+      "assert(op_test_float(1, 10) == 11)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
       "op_test_float_result",
       "assert(op_test_float_result(1, 10) == 11)",
     )?;
@@ -997,12 +1026,12 @@ mod tests {
       &format!("assert(op_test_bigint_i64({}n) == {}n)", i64::MAX, i64::MAX),
     )?;
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_test_bigint_i64_as_number",
       "assert(op_test_bigint_i64_as_number(Number.MAX_SAFE_INTEGER) == Number.MAX_SAFE_INTEGER)",
     )?;
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_test_bigint_i64_as_number",
       "assert(op_test_bigint_i64_as_number(Number.MIN_SAFE_INTEGER) == Number.MIN_SAFE_INTEGER)",
     )?;
@@ -1072,39 +1101,39 @@ mod tests {
         (40000, "'\\u{1F995}'.repeat(10000)"),
       ] {
         let test = format!("assert({op}({str}) == {len})");
-        run_test2(10000, op, &test)?;
+        run_test2(JIT_SLOW_ITERATIONS, op, &test)?;
       }
     }
 
     // Ensure that we're correctly encoding UTF-8
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char",
       "assert(op_test_string_roundtrip_char('\\u00a0') == 0xa0)",
     )?;
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char",
       "assert(op_test_string_roundtrip_char('\\u00ff') == 0xff)",
     )?;
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char",
       "assert(op_test_string_roundtrip_char('\\u0080') == 0x80)",
     )?;
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char",
       "assert(op_test_string_roundtrip_char('\\u0100') == 0x100)",
     )?;
 
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char_onebyte",
       "assert(op_test_string_roundtrip_char_onebyte('\\u00ff') == 0xff)",
     )?;
     run_test2(
-      10000,
+      JIT_SLOW_ITERATIONS,
       "op_test_string_roundtrip_char_onebyte",
       "assert(op_test_string_roundtrip_char_onebyte('\\u007f') == 0x7f)",
     )?;
@@ -1266,7 +1295,7 @@ mod tests {
   pub async fn test_op_v8_types() -> Result<(), Box<dyn std::error::Error>> {
     for (a, b) in [("a", 1), ("b", 2), ("c", 3)] {
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         "op_test_v8_types",
         &format!("assert(op_test_v8_types('{a}', 'a', 'b') == {b})"),
       )?;
@@ -1276,7 +1305,7 @@ mod tests {
       ("op_test_v8_option_string", "'xyz'", "3"),
       ("op_test_v8_option_string", "null", "-1"),
     ] {
-      run_test2(10000, a, &format!("assert({a}({b}) == {c})"))?;
+      run_test2(JIT_SLOW_ITERATIONS, a, &format!("assert({a}({b}) == {c})"))?;
     }
     // Non-fast ops
     for (a, b, c) in [
@@ -1360,7 +1389,7 @@ mod tests {
 
   #[tokio::test]
   pub async fn test_jsruntimestate() -> Result<(), Box<dyn std::error::Error>> {
-    run_test2(10000, "op_jsruntimestate", "op_jsruntimestate()")?;
+    run_test2(JIT_ITERATIONS, "op_jsruntimestate", "op_jsruntimestate()")?;
     Ok(())
   }
 
@@ -1402,19 +1431,23 @@ mod tests {
   #[tokio::test]
   pub async fn test_op_state() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_state_rc",
       "if (__index__ == 0) { op_state_rc(__index__) } else { assert(op_state_rc(__index__) == __index__ - 1) }",
     )?;
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_state_mut_attr",
       "if (__index__ == 0) { op_state_mut_attr(__index__) } else { assert(op_state_mut_attr(__index__) == __index__ - 1) }",
     )?;
-    run_test2(10000, "op_state_mut", "op_state_mut(__index__)")?;
-    run_test2(10000, "op_state_ref", "assert(op_state_ref() == 1234)")?;
+    run_test2(JIT_ITERATIONS, "op_state_mut", "op_state_mut(__index__)")?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
+      "op_state_ref",
+      "assert(op_state_ref() == 1234)",
+    )?;
+    run_test2(
+      JIT_ITERATIONS,
       "op_state_multi_attr",
       "assert(op_state_multi_attr() == 11234)",
     )?;
@@ -1517,19 +1550,19 @@ mod tests {
     ] {
       // Zero-length buffers
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op,
         &format!("{op}(new {arr}(0), 0, new {arr}(0), 0);"),
       )?;
       // Zero-length ptrs
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op_ptr,
         &format!("{op_ptr}(new {arr}(0), 0, new {arr}(0), 0);"),
       )?;
       // UintXArray -> UintXArray
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op,
         &format!(
           r"
@@ -1540,7 +1573,7 @@ mod tests {
       )?;
       // UintXArray -> UintXArray
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op_ptr,
         &format!(
           r"
@@ -1551,7 +1584,7 @@ mod tests {
       )?;
       // UintXArray(ArrayBuffer) -> UintXArray(ArrayBuffer)
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op,
         &format!(
           r"
@@ -1565,7 +1598,7 @@ mod tests {
       )?;
       // UintXArray(ArrayBuffer, 5, 5) -> UintXArray(ArrayBuffer)
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op,
         &format!(
           r"
@@ -1579,7 +1612,7 @@ mod tests {
       )?;
       // Resizable
       run_test2(
-        10000,
+        JIT_SLOW_ITERATIONS,
         op,
         &format!(
           r"
@@ -1613,7 +1646,7 @@ mod tests {
   pub async fn test_op_buffer_jsbuffer(
   ) -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_jsbuffer",
       r"
         let inbuf = new ArrayBuffer(10);
@@ -1638,7 +1671,7 @@ mod tests {
   #[tokio::test]
   pub async fn test_op_buffer_any() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any",
       "const data = new ArrayBuffer(8);
       const view = new Uint8Array(data, 2);
@@ -1648,7 +1681,7 @@ mod tests {
       assert(op_buffer_any(view) == 15);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any",
       "const data = new ArrayBuffer(8);
       const view = new Uint8Array(data, 2, 4);
@@ -1658,22 +1691,22 @@ mod tests {
       assert(op_buffer_any(view) == 6);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any",
       "assert(op_buffer_any(new Uint8Array([1,2,3,4])) == 10);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any",
       "assert(op_buffer_any(new Uint8Array([1,2,3,4]).buffer) == 10);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any",
       "assert(op_buffer_any(new Uint32Array([1,2,3,4,0x01010101])) == 14);",
     )?;
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_buffer_any",
       "assert(op_buffer_any(new DataView(new Uint8Array([1,2,3,4]).buffer)) == 10);",
     )?;
@@ -1689,7 +1722,7 @@ mod tests {
   pub async fn test_op_buffer_any_length(
   ) -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "const data = new ArrayBuffer(8);
       const view = new Uint8Array(data, 2);
@@ -1699,7 +1732,7 @@ mod tests {
       assert(op_buffer_any_length(view) == 6);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "const data = new ArrayBuffer(8);
       const view = new Uint8Array(data, 2, 4);
@@ -1709,22 +1742,22 @@ mod tests {
       assert(op_buffer_any_length(view) == 4);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "assert(op_buffer_any_length(new Uint8Array(10)) == 10);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "assert(op_buffer_any_length(new ArrayBuffer(10)) == 10);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "assert(op_buffer_any_length(new Uint32Array(10)) == 40);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_any_length",
       "assert(op_buffer_any_length(new DataView(new ArrayBuffer(10))) == 10);",
     )?;
@@ -1750,12 +1783,12 @@ mod tests {
   ) -> Result<(), Box<dyn std::error::Error>> {
     // Zero-length buffers
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_arraybuffer_slice",
       "op_arraybuffer_slice(new ArrayBuffer(0), 0, new ArrayBuffer(0), 0);",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_arraybuffer_slice",
       r"let inbuf = new ArrayBuffer(10);
       (new Uint8Array(inbuf))[0] = 1;
@@ -1817,7 +1850,7 @@ mod tests {
   #[tokio::test]
   pub async fn test_op_buffer_copy() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_buffer_copy",
       r"
       let input = new Uint8Array(10);
@@ -1895,7 +1928,7 @@ mod tests {
   #[tokio::test]
   pub async fn test_external() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_external_make, op_external_process",
       "op_external_process(op_external_make())",
     )?;
@@ -1919,12 +1952,12 @@ mod tests {
   #[tokio::test]
   pub async fn test_external_null() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_external_make_ptr, op_external_process_ptr",
       "assert(op_external_process_ptr(op_external_make_ptr(0), 0) === null)",
     )?;
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_external_make_ptr, op_external_process_ptr",
       "assert(op_external_process_ptr(op_external_make_ptr(6), -6) === null)",
     )?;
@@ -1956,7 +1989,7 @@ mod tests {
   #[tokio::test]
   pub async fn test_typed_external() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+       JIT_ITERATIONS,
       "op_typed_external, op_typed_external_process, op_typed_external_take",
       "let external = op_typed_external(); op_typed_external_process(external); assert(op_typed_external_take(external) == 43);",
     )?;
@@ -1981,7 +2014,7 @@ mod tests {
   #[tokio::test]
   pub async fn test_isolate() -> Result<(), Box<dyn std::error::Error>> {
     run_test2(
-      10000,
+      JIT_ITERATIONS,
       "op_isolate_queue_microtask,op_isolate_run_microtasks",
       "op_isolate_queue_microtask(() => {}); op_isolate_run_microtasks();",
     )?;
@@ -1993,7 +2026,8 @@ mod tests {
 
   #[tokio::test]
   pub async fn test_op_async_void() -> Result<(), Box<dyn std::error::Error>> {
-    run_async_test(10000, "op_async_void", "await op_async_void()").await?;
+    run_async_test(JIT_ITERATIONS, "op_async_void", "await op_async_void()")
+      .await?;
     Ok(())
   }
 
@@ -2020,13 +2054,13 @@ mod tests {
   pub async fn test_op_async_number() -> Result<(), Box<dyn std::error::Error>>
   {
     run_async_test(
-      10000,
+      JIT_ITERATIONS,
       "op_async_number",
       "assert(await op_async_number(__index__) == __index__)",
     )
     .await?;
     run_async_test(
-      10000,
+      JIT_ITERATIONS,
       "op_async_add",
       "assert(await op_async_add(__index__, 100) == __index__ + 100)",
     )
@@ -2096,13 +2130,13 @@ mod tests {
   pub async fn test_op_async_deferred() -> Result<(), Box<dyn std::error::Error>>
   {
     run_async_test(
-      1000,
+      JIT_SLOW_ITERATIONS,
       "op_async_deferred_success",
       "assert(await op_async_deferred_success() == 42)",
     )
     .await?;
     run_async_test(
-      1000,
+       JIT_SLOW_ITERATIONS,
       "op_async_deferred_error",
       "try { await op_async_deferred_error(); assert(false) } catch (e) {{ assertErrorContains(e, 'whoops') }}",
     )
@@ -2123,13 +2157,13 @@ mod tests {
   #[tokio::test]
   pub async fn test_op_async_lazy() -> Result<(), Box<dyn std::error::Error>> {
     run_async_test(
-      1000,
+      JIT_SLOW_ITERATIONS,
       "op_async_lazy_success",
       "assert(await op_async_lazy_success() == 42)",
     )
     .await?;
     run_async_test(
-      1000,
+       JIT_SLOW_ITERATIONS,
       "op_async_lazy_error",
       "try { await op_async_lazy_error(); assert(false) } catch (e) {{ assertErrorContains(e, 'whoops') }}",
     )
diff --git a/ops/Cargo.toml b/ops/Cargo.toml
index f61e7a6..53d178c 100644
--- a/ops/Cargo.toml
+++ b/ops/Cargo.toml
@@ -2,7 +2,7 @@
 
 [package]
 name = "deno_ops"
-version = "0.148.0"
+version = "0.149.0"
 authors.workspace = true
 edition.workspace = true
 license.workspace = true
diff --git a/serde_v8/Cargo.toml b/serde_v8/Cargo.toml
index 69fda21..f84182e 100644
--- a/serde_v8/Cargo.toml
+++ b/serde_v8/Cargo.toml
@@ -2,7 +2,7 @@
 
 [package]
 name = "serde_v8"
-version = "0.181.0"
+version = "0.182.0"
 authors.workspace = true
 edition.workspace = true
 license.workspace = true


Test patch:
diff --git a/.github/workflows/ci-test-valgrind/action.yml b/.github/workflows/ci-test-valgrind/action.yml
new file mode 100644
index 0000000..8cb48c7
--- /dev/null
+++ b/.github/workflows/ci-test-valgrind/action.yml
@@ -0,0 +1,18 @@
+name: Test workflow
+runs:
+  using: "composite"
+  steps:
+    - name: Install valgrind
+      shell: bash
+      run: |
+        # Installing packages
+        sudo rm /var/lib/man-db/auto-update || true
+        sudo apt-get install -y --no-install-recommends valgrind
+    - name: Cargo test (valgrind)
+      shell: bash
+      run: |
+        CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUNNER="
+          valgrind --error-exitcode=1 --leak-check=no
+          --suppressions=/home/runner/work/deno_core/deno_core/.github/workflows/ci-test-valgrind/suppressions.txt
+          --gen-suppressions=all" \
+          cargo test -p deno_core -p deno_core_testing -p serde_v8 --release
diff --git a/.github/workflows/ci-test-valgrind/suppressions.txt b/.github/workflows/ci-test-valgrind/suppressions.txt
new file mode 100644
index 0000000..a6092c2
--- /dev/null
+++ b/.github/workflows/ci-test-valgrind/suppressions.txt
@@ -0,0 +1,141 @@
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Addr8
+   fun:_ZN9deno_core8external24ExternalPointer*validate_pointer*
+   fun:_ZN4core3ops8function6FnOnce9call_once*
+   fun:_ZN4test28__rust_begin_short_backtrace*
+   fun:_ZN4test8run_test*
+   fun:_ZN3std10sys_common9backtrace28__rust_begin_short_backtrace*
+   fun:_ZN4core3ops8function6FnOnce40call_once*
+   fun:_ZN3std3sys4unix6thread6Thread3new12thread_start*
+   fun:start_thread
+   fun:clone
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+   fun:_ZZN2v88internal4Heap14CollectGarbageENS0_15AllocationSpaceENS0_23GarbageCollectionReasonENS_15GCCallbackFlagsEENK3$_1clEv
+   fun:_ZN4heap4base5Stack24SetMarkerAndCallbackImplIZN2v88internal4Heap14CollectGarbageENS4_15AllocationSpaceENS4_23GarbageCollectionReasonENS3_15GCCallbackFlagsEE3$_1EEvPS1_PvPKv
+   obj:*
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+   fun:_ZZN2v88internal4Heap14CollectGarbageENS0_15AllocationSpaceENS0_23GarbageCollectionReasonENS_15GCCallbackFlagsEENK3$_1clEv
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+   fun:_ZZN2v88internal4Heap14CollectGarbageENS0_15AllocationSpaceENS0_23GarbageCollectionReasonENS_15GCCallbackFlagsEENK3$_1clEv
+}
+{
+   <insert_a_suppression_name_here>
+   Memcheck:Cond
+   fun:_ZZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKvENK3$_0clEPh
+   fun:_ZN5cppgc8internal26ConservativeTracingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN2v88internal12_GLOBAL__N_137UnifiedHeapConservativeMarkingVisitor27TraceConservativelyIfNeededEPKv
+   fun:_ZN4heap4base12_GLOBAL__N_122IteratePointersInStackEPNS0_12StackVisitorEPKvS5_S5_
+   fun:_ZNK4heap4base5Stack26IteratePointersUntilMarkerEPNS0_12StackVisitorE
+   fun:_ZN5cppgc8internal10MarkerBase10VisitRootsENS_18EmbedderStackStateE
+   fun:_ZN5cppgc8internal10MarkerBase16EnterAtomicPauseENS_18EmbedderStackStateE
+   fun:_ZN2v88internal7CppHeap15EnterFinalPauseEN5cppgc18EmbedderStackStateE
+   fun:_ZN2v88internal20MarkCompactCollector15MarkLiveObjectsEv
+   fun:_ZN2v88internal20MarkCompactCollector14CollectGarbageEv
+   fun:_ZN2v88internal4Heap11MarkCompactEv
+   fun:_ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS0_23GarbageCollectionReasonEPKc
+}
\ No newline at end of file
diff --git a/core/modules/tests.rs b/core/modules/tests.rs
index 167380b..09683c5 100644
--- a/core/modules/tests.rs
+++ b/core/modules/tests.rs
@@ -456,6 +456,13 @@ fn test_lazy_loaded_esm() {
     ..Default::default()
   });
 
+  runtime
+    .lazy_load_es_module_with_code(
+      "ext:cli/more_lazy.js",
+      crate::ascii_str_include!("testdata/lazy_loaded.js"),
+    )
+    .unwrap();
+
   runtime
     .execute_script(
       "setup.js",
diff --git a/core/runtime/tests/misc.rs b/core/runtime/tests/misc.rs
index a54dea0..1ab7ed0 100644
--- a/core/runtime/tests/misc.rs
+++ b/core/runtime/tests/misc.rs
@@ -1131,12 +1131,16 @@ async fn task_spawner_cross_thread() {
     .borrow::<V8CrossThreadTaskSpawner>()
     .clone();
 
+  let barrier = Arc::new(std::sync::Barrier::new(2));
+  let barrier2 = barrier.clone();
   std::thread::spawn(move || {
+    barrier2.wait();
     spawner.spawn(move |scope| {
       let res = call_i32_function(scope);
       value_clone.store(res as _, Ordering::SeqCst);
     });
   });
+  barrier.wait();
 
   // Async spin while we wait for this to complete
   let start = Instant::now();
@@ -1145,7 +1149,7 @@ async fn task_spawner_cross_thread() {
       .await
       .unwrap();
     tokio::time::sleep(Duration::from_millis(10)).await;
-    assert!(start.elapsed().as_secs() < 60);
+    assert!(start.elapsed().as_secs() < 180);
   }
 }
 
@@ -1161,10 +1165,14 @@ async fn task_spawner_cross_thread_blocking() {
     .borrow::<V8CrossThreadTaskSpawner>()
     .clone();
 
+  let barrier = Arc::new(std::sync::Barrier::new(2));
+  let barrier2 = barrier.clone();
   std::thread::spawn(move || {
+    barrier2.wait();
     let res = spawner.spawn_blocking(call_i32_function);
     value_clone.store(res as _, Ordering::SeqCst);
   });
+  barrier.wait();
 
   // Async spin while we wait for this to complete
   let start = Instant::now();
@@ -1173,7 +1181,7 @@ async fn task_spawner_cross_thread_blocking() {
       .await
       .unwrap();
     tokio::time::sleep(Duration::from_millis(10)).await;
-    assert!(start.elapsed().as_secs() < 60);
+    assert!(start.elapsed().as_secs() < 180);
   }
 }
 
@@ -1181,7 +1189,7 @@ async fn task_spawner_cross_thread_blocking() {
 async fn terminate_execution_run_event_loop_js() {
   #[op2(async)]
   async fn op_async_sleep() -> Result<(), Error> {
-    tokio::time::sleep(std::time::Duration::from_millis(2000)).await;
+    tokio::time::sleep(std::time::Duration::from_millis(100)).await;
     Ok(())
   }
   deno_core::extension!(test_ext, ops = [op_async_sleep]);
@@ -1190,29 +1198,20 @@ async fn terminate_execution_run_event_loop_js() {
     ..Default::default()
   });
 
-  // Create sleep function that waits for 2 seconds.
-  runtime
-    .execute_script(
-      "sleep_code.js",
-      r#"
-              const { op_async_sleep } = Deno.core.ops; 
-              async function sleep() {
-                await op_async_sleep();
-              }
-      "#,
-    )
-    .unwrap();
+  // Start async task
+  runtime.execute_script("sleep.js", "(async () => { while (true) { await Deno.core.ops.op_async_sleep(); } })()").unwrap();
 
   // Terminate execution after 1 second.
   let v8_isolate_handle = runtime.v8_isolate().thread_safe_handle();
+  let barrier = Arc::new(std::sync::Barrier::new(2));
+  let barrier2 = barrier.clone();
   let terminator_thread = std::thread::spawn(move || {
+    barrier2.wait();
     std::thread::sleep(std::time::Duration::from_millis(1000));
     let ok = v8_isolate_handle.terminate_execution();
     assert!(ok);
   });
-
-  // Start waiting period of 2 seconds.
-  runtime.execute_script("sleep.js", "sleep()").unwrap();
+  barrier.wait();
 
   let err = runtime
     .run_event_loop(Default::default())
diff --git a/testing/checkin/runner/mod.rs b/testing/checkin/runner/mod.rs
index 075d3a0..f144a54 100644
--- a/testing/checkin/runner/mod.rs
+++ b/testing/checkin/runner/mod.rs
@@ -106,16 +106,17 @@ fn create_runtime(
   let snapshot = runtime_for_snapshot.snapshot();
   let snapshot = Box::leak(snapshot);
   let extensions = vec![checkin_runtime::init_ops()];
+  let module_loader =
+    Rc::new(ts_module_loader::TypescriptModuleLoader::default());
   let mut runtime = JsRuntime::new(RuntimeOptions {
     extensions,
     startup_snapshot: Some(snapshot),
-    module_loader: Some(Rc::new(
-      ts_module_loader::TypescriptModuleLoader::default(),
-    )),
+    module_loader: Some(module_loader.clone()),
     get_error_class_fn: Some(&|error| {
       deno_core::error::get_custom_error_class(error).unwrap_or("Error")
     }),
     shared_array_buffer_store: Some(CrossIsolateStore::default()),
+    source_map_getter: Some(module_loader),
     ..Default::default()
   });
 
diff --git a/testing/checkin/runner/ts_module_loader.rs b/testing/checkin/runner/ts_module_loader.rs
index 77f4feb..347fa8b 100644
--- a/testing/checkin/runner/ts_module_loader.rs
+++ b/testing/checkin/runner/ts_module_loader.rs
@@ -9,9 +9,11 @@ use anyhow::Error;
 
 use deno_ast::MediaType;
 use deno_ast::ParseParams;
+use deno_ast::SourceMapOption;
 use deno_ast::SourceTextInfo;
 use deno_core::error::AnyError;
 use deno_core::resolve_import;
+use deno_core::url::Url;
 use deno_core::ModuleCodeString;
 use deno_core::ModuleLoadResponse;
 use deno_core::ModuleLoader;
@@ -28,9 +30,9 @@ use deno_core::SourceMapGetter;
 #[derive(Clone, Default)]
 struct SourceMapStore(Rc<RefCell<HashMap<String, Vec<u8>>>>);
 
-impl SourceMapGetter for SourceMapStore {
+impl SourceMapGetter for TypescriptModuleLoader {
   fn get_source_map(&self, specifier: &str) -> Option<Vec<u8>> {
-    self.0.borrow().get(specifier).cloned()
+    self.source_maps.0.borrow().get(specifier).cloned()
   }
 
   fn get_source_line(
@@ -98,7 +100,7 @@ impl ModuleLoader for TypescriptModuleLoader {
       let code = std::fs::read_to_string(&path)?;
       let code = if should_transpile {
         let parsed = deno_ast::parse_module(ParseParams {
-          specifier: module_specifier.to_string(),
+          specifier: module_specifier.clone(),
           text_info: SourceTextInfo::from_string(code),
           media_type,
           capture_tokens: false,
@@ -106,9 +108,10 @@ impl ModuleLoader for TypescriptModuleLoader {
           maybe_syntax: None,
         })?;
         let res = parsed.transpile(&deno_ast::EmitOptions {
-          inline_source_map: false,
-          source_map: true,
-          inline_sources: true,
+          imports_not_used_as_values: deno_ast::ImportsNotUsedAsValues::Remove,
+          source_map: SourceMapOption::Separate,
+          inline_sources: false,
+          use_decorators_proposal: true,
           ..Default::default()
         })?;
         let source_map = res.source_map.unwrap();
@@ -154,7 +157,7 @@ pub fn maybe_transpile_source(
   }
 
   let parsed = deno_ast::parse_module(ParseParams {
-    specifier: specifier.to_string(),
+    specifier: Url::parse(&specifier).unwrap(),
     text_info: SourceTextInfo::from_string(source.as_str().to_owned()),
     media_type,
     capture_tokens: false,
@@ -163,9 +166,9 @@ pub fn maybe_transpile_source(
   })?;
   let transpiled_source = parsed.transpile(&deno_ast::EmitOptions {
     imports_not_used_as_values: deno_ast::ImportsNotUsedAsValues::Remove,
-    inline_source_map: false,
-    source_map: true,
-    inline_sources: true,
+    source_map: SourceMapOption::Separate,
+    inline_sources: false,
+    use_decorators_proposal: true,
     ..Default::default()
   })?;
 
diff --git a/testing/integration/error_ext_stack/error_ext_stack.out b/testing/integration/error_ext_stack/error_ext_stack.out
index b585138..c84dd79 100644
--- a/testing/integration/error_ext_stack/error_ext_stack.out
+++ b/testing/integration/error_ext_stack/error_ext_stack.out
@@ -1,4 +1,4 @@
 [ERR] Error: Failed
 [ERR]     at innerThrowInExt (checkin:throw:11:9)
 [ERR]     at throwExceptionFromExtension (checkin:throw:7:3)
-[ERR]     at test:///integration/error_ext_stack/error_ext_stack.ts:4:1
+[ERR]     at test:///integration/error_ext_stack/error_ext_stack.ts:5:1
diff --git a/testing/integration/error_with_stack/error_with_stack.out b/testing/integration/error_with_stack/error_with_stack.out
index 627c100..c3049ee 100644
--- a/testing/integration/error_with_stack/error_with_stack.out
+++ b/testing/integration/error_with_stack/error_with_stack.out
@@ -1,4 +1,4 @@
 [ERR] Error: assert
-[ERR]     at assert (test:///integration/error_with_stack/error_with_stack.ts:5:11)
-[ERR]     at main (test:///integration/error_with_stack/error_with_stack.ts:9:3)
-[ERR]     at test:///integration/error_with_stack/error_with_stack.ts:11:1
+[ERR]     at assert (test:///integration/error_with_stack/error_with_stack.ts:6:11)
+[ERR]     at main (test:///integration/error_with_stack/error_with_stack.ts:10:3)
+[ERR]     at test:///integration/error_with_stack/error_with_stack.ts:12:1
diff --git a/testing/integration/timer_ref/timer_ref.ts b/testing/integration/timer_ref/timer_ref.ts
index e8fc786..4dced03 100644
--- a/testing/integration/timer_ref/timer_ref.ts
+++ b/testing/integration/timer_ref/timer_ref.ts
@@ -1,5 +1,6 @@
 // Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
 setTimeout(() => console.log("a"), 1000);
 setTimeout(() => console.log("b"), 2000);
-const c = setTimeout(() => console.log("c"), 3000);
+// Make this long enough that we'll never hit it
+const c = setTimeout(() => console.log("c"), 120_000);
 Deno.core.unrefTimer(c);
diff --git a/testing/integration/timer_ref_and_cancel/timer_ref_and_cancel.ts b/testing/integration/timer_ref_and_cancel/timer_ref_and_cancel.ts
index c2f4845..e04ac7e 100644
--- a/testing/integration/timer_ref_and_cancel/timer_ref_and_cancel.ts
+++ b/testing/integration/timer_ref_and_cancel/timer_ref_and_cancel.ts
@@ -1,8 +1,9 @@
 // Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
 setTimeout(() => console.log("a"), 1000);
 setTimeout(() => console.log("b"), 2000);
-const c = setTimeout(() => console.log("c"), 3000);
-const d = setTimeout(() => console.log("d"), 4000);
+// Make these long enough that we'll never hit them
+const c = setTimeout(() => console.log("c"), 120_000);
+const d = setTimeout(() => console.log("d"), 150_000);
 // c should not run, if d is cancelled
 Deno.unrefTimer(c);
 clearTimeout(d);