diff options
author | 2023-10-11 02:27:07 -0700 | |
---|---|---|
committer | 2023-10-11 02:27:07 -0700 | |
commit | 1bf28e0d77a8b2261befbdb708cefd03e0126960 (patch) | |
tree | 1d1120922f2fd935be47ab4255ac57455a0bede8 /src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp | |
parent | 6a17ebe6696ebdf5c20de9de3281d308959c13b5 (diff) | |
download | bun-1bf28e0d77a8b2261befbdb708cefd03e0126960.tar.gz bun-1bf28e0d77a8b2261befbdb708cefd03e0126960.tar.zst bun-1bf28e0d77a8b2261befbdb708cefd03e0126960.zip |
feat(install): automatically migrate package-lock.json to bun.lockb (#6352)bun-v1.0.5
* work so far
* stuff
* a
* basics work
* stuff
* yoo
* build lockfile
* correct
* f
* a
* install fixture havent tested
* i made it worse
* lol
* be more reasonable
* make the test easier to pass because bun install doesn't handle obscure lockfile edge cases :/
* a
* works now
* ok
* a
* a
* cool
* nah
* fix stuff
* l
* a
* idfk
* LAME
* prettier errors
* does this fix tests?
* Add more safety checks to Integrity
* Add another check
* More careful lifetime handling
* Fix linux debugger issue
* a
* tmp dir and snapshot test
---------
Co-authored-by: Jarred SUmner <jarred@jarredsumner.com>
Diffstat (limited to 'src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp')
-rw-r--r-- | src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp b/src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp index f607d586a..4db97d116 100644 --- a/src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp +++ b/src/bun.js/bindings/JSCUSocketsLoopIntegration.cpp @@ -1,12 +1,30 @@ #include "root.h" #include "JavaScriptCore/VM.h" +// On Linux, signals are used to suspend/resume threads in JavaScriptCore +// When `.acquireAccess` is called, the signal might be raised. +// This causes issues with LLDB which might catch the signal. +// So we want to avoid that, we really only want this code to be executed when the debugger is attached +// But it's pretty hard to tell if LLDB is attached or not, so we just disable this code on Linux when in debug mode +#ifndef ACQUIRE_RELEASE_HEAP_ACCESS +#if OS(DARWIN) +#define ACQUIRE_RELEASE_HEAP_ACCESS 1 +#else +#ifndef BUN_DEBUG +#define ACQUIRE_RELEASE_HEAP_ACCESS 1 +#endif +#endif +#endif + extern "C" void bun_on_tick_before(JSC::VM* vm) { - // Let the GC do some work while we are idle +#if ACQUIRE_RELEASE_HEAP_ACCESS vm->heap.releaseAccess(); +#endif } extern "C" void bun_on_tick_after(JSC::VM* vm) { +#if ACQUIRE_RELEASE_HEAP_ACCESS vm->heap.acquireAccess(); +#endif }
\ No newline at end of file |