Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix rb_gc_impl_copy_finalizer #13350

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

casperisfine
Copy link
Contributor

  • Add missing VM_LOCK
  • Generate a new object_id when copying finalizers
  • Dup the finalizer entry so adding a finalizer on a cloned object doesn't impact the source object.

assert_in_out_err(["-e", <<-END], "", %w(:ok :ok :ok :ok), [])
assert_in_out_err(["-e", <<-END], "", %w(:ok :ok :ok), [])
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My understanding is that this assertion was incorrect.

  • We define 1 finalizer on the source object
  • Clone the source object, so 1+1 => 2
  • Add another finalizer on the copied object, so 2 + 1 => 3.

Copy link

launchable-app bot commented May 15, 2025

Tests Failed

✖️2 tests failed ✔️61516 tests passed(2 flakes)

22/161 test sessions failed

❌ Test session #4321615 failedos:macos-14 ![workflow:YJIT macOS Arm64](https://img.shields.io/badge/workflow-YJIT macOS Arm64-blue.svg) test_opts:--enable-yjit:dev test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28640 tests passed

❌ Test session #4321617 failedos:macos-14 ![workflow:YJIT macOS Arm64](https://img.shields.io/badge/workflow-YJIT macOS Arm64-blue.svg) test_opts:--enable-yjit test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28572 tests passed

❌ Test session #4321620 failedos:macos-15 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28591 tests passed

❌ Test session #4321625 failedos:macos-14 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28584 tests passed

❌ Test session #4321626 failedos:macos-latest workflow:ModGC test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28581 tests passed

❌ Test session #4321628 failedos:macos-14 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28548 tests passed

❌ Test session #4321629 failedos:macos-14 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28581 tests passed

❌ Test session #4321638 failedos:macos-14 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28563 tests passed

❌ Test session #4321640 failedos:ubuntu-22.04 workflow:Ubuntu test_opts:--disable-yjit test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28468 tests passed

❌ Test session #4321644 failedos:ubuntu-22.04 workflow:Ubuntu test_opts:cppflags:-DVM_CHECK_MODE test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28667 tests passed

❌ Test session #4321647 failedos:ubuntu-22.04 workflow:Ubuntu test_opts:--enable-shared--enable-load-relative test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️27671 tests passed

❌ Test session #4321650 failedos:ubuntu-22.04 ![workflow:YJIT Ubuntu](https://img.shields.io/badge/workflow-YJIT Ubuntu-blue.svg) test_opts:--enable-yjit:dev test_task:checkdetails on CI
🔔 1 issue ✖️2 tests failed ✔️no tests passed

❌ Test session #4321655 failedos:ubuntu-22.04 workflow:Ubuntu test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28457 tests passed

❌ Test session #4321661 failedos:ubuntu-22.04 ![workflow:YJIT Ubuntu](https://img.shields.io/badge/workflow-YJIT Ubuntu-blue.svg) test_opts:RUSTC:'rustc+1.58.0' test_task:checkdetails on CI
🔔 1 issue ✖️2 tests failed ✔️no tests passed

❌ Test session #4321662 failedos:ubuntu-latest workflow:ModGC test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️28602 tests passed

❌ Test session #4321680 failedos:ubuntu-22.04 ![workflow:YJIT Ubuntu](https://img.shields.io/badge/workflow-YJIT Ubuntu-blue.svg) test_opts:--enable-yjit:dev test_task:checkdetails on CI
🔔 1 issue ✖️2 tests failed ✔️no tests passed

❌ Test session #4321693 failedos:ubuntu-24.04-arm workflow:Ubuntu test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️2 tests failed ✔️32536 tests passed

❌ Test session #4321698 failedos:ubuntu-24.04 workflow:Ubuntu test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️2 tests failed ✔️32538 tests passed

❌ Test session #4321707 failedos:macos-13 workflow:macOS test_opts: test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️27630 tests passed

❌ Test session #4321798 failedos:windows-2025 workflow:Windows test_opts:none test_task:checkdetails on CI
🔔 2 issues ✖️2 tests failed ✔️28247 tests passed

❌ Test session #4321825 failedos:windows-2022 workflow:Windows test_opts:none test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️27297 tests passed

❌ Test session #4321833 failedos:windows-2022 workflow:MinGW test_opts:none test_task:checkdetails on CI
🔔 1 issue ✖️1 test failed ✔️23877 tests passed

@casperisfine casperisfine force-pushed the copy-finalizer-lock branch from c082a98 to fdf9e04 Compare May 15, 2025 12:50
@casperisfine casperisfine force-pushed the copy-finalizer-lock branch from fdf9e04 to 60f41e2 Compare May 15, 2025 14:26
@byroot byroot enabled auto-merge (rebase) May 15, 2025 14:26
@byroot byroot disabled auto-merge May 15, 2025 14:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants