From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on starla X-Spam-Level: X-Spam-Status: No, score=-1.1 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 Received: from nue.mailmanlists.eu (nue.mailmanlists.eu [IPv6:2a01:4f8:1c0c:6b10::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 205E01F44D for ; Mon, 8 Apr 2024 09:42:21 +0000 (UTC) Authentication-Results: dcvr.yhbt.net; dkim=pass (1024-bit key; secure) header.d=ml.ruby-lang.org header.i=@ml.ruby-lang.org header.a=rsa-sha256 header.s=mail header.b=ux/qfTrW; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.a=rsa-sha256 header.s=s1 header.b=NC7OfADg; dkim-atps=neutral Received: from nue.mailmanlists.eu (localhost [127.0.0.1]) by nue.mailmanlists.eu (Postfix) with ESMTP id F357C81486; Mon, 8 Apr 2024 09:42:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ml.ruby-lang.org; s=mail; t=1712569333; bh=Y9qIhNXTxwL77925NqIgMiShEvTTfQam/9xrva54ep4=; h=Date:References:To:Reply-To:Subject:List-Id:List-Archive: List-Help:List-Owner:List-Post:List-Subscribe:List-Unsubscribe: From:Cc:From; b=ux/qfTrWHhsNbQmMVew21rSHmM/OckccPypfnHJWNYe2fPhWrv0hIXcidxMsE2Ah9 ZA2CSqUjF+ARuwRvacUIXgyFMq+/Pom2nh09tJWyD3+8ISG/L1j/8+odGHH1gXY2QM UqkdFhqpk5zAMG7vdxrxWKahmTvUilbE9NC6oqjw= Received: from s.wrqvtzvf.outbound-mail.sendgrid.net (s.wrqvtzvf.outbound-mail.sendgrid.net [149.72.126.143]) by nue.mailmanlists.eu (Postfix) with ESMTPS id 059B48138C for ; Mon, 8 Apr 2024 09:42:08 +0000 (UTC) Authentication-Results: nue.mailmanlists.eu; dkim=pass (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.a=rsa-sha256 header.s=s1 header.b=NC7OfADg; dkim-atps=neutral DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ruby-lang.org; h=from:references:subject:mime-version:content-type: content-transfer-encoding:list-id:to:cc:content-type:from:subject:to; s=s1; bh=PnlC8UyzpmTv9xNI5NkoWPTIKb4K/K6sEQ+U/NRk99g=; b=NC7OfADgfShyVFEAraP86XN3sjZd1jBWw0rrycW4fnOanHOU9coCherW5B4azi/z4uaa QDAE6K6EzBFPW1I1EICe0S+LQpMIyw2Q7paruAlXYNkQ5vSortbsgiisYa+aJiUwzQFPJy 9seyBuhvLMqhIQK8zB6rVrnejxe7PihtdqK0k/+zfbpu9Vc7btWtdw6WXgvmJDuH54PD7d s45mfM6Yw36nHEvicENIa7677ImntfYjE95tuz+Obplppzfei0BBcwnHe1uAcc4M0ClU6o WHXosnAJFk91dzeKzugkk1wb5cuFC6usbyNCwXS5zt7xlOQ0TOYWYcgcOsaa6eFw== Received: by recvd-d98d7c8b-mf8gx with SMTP id recvd-d98d7c8b-mf8gx-1-6613BBEF-C 2024-04-08 09:42:07.833137153 +0000 UTC m=+316113.152831728 Received: from herokuapp.com (unknown) by geopod-ismtpd-canary-0 (SG) with ESMTP id zawFx2_OSiKW96d29WES5g for ; Mon, 08 Apr 2024 09:42:07.802 +0000 (UTC) Date: Mon, 08 Apr 2024 09:42:07 +0000 (UTC) Message-ID: References: Mime-Version: 1.0 X-Redmine-Project: ruby-master X-Redmine-Issue-Tracker: Bug X-Redmine-Issue-Id: 20050 X-Redmine-Issue-Author: martinemde X-Redmine-Issue-Priority: Normal X-Redmine-Sender: nagachika X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-Redmine-MailingListIntegration-Message-Ids: 94060 X-SG-EID: =?us-ascii?Q?u001=2E44VQVH0G4ktThU9FFZyDXb=2FoLGKi0xg3KhKXpO+IAEE5wRGZS=2FaUmrCxU?= =?us-ascii?Q?vRSr0kI+o91vm0PKZJNpskxVPGLEUY0z2=2FFYkjb?= =?us-ascii?Q?KjL91GsNRUBrIzsxthm1N6+g62tL8gQuERIZpt1?= =?us-ascii?Q?y5q8vu+Ny6p66cl0MBjMVHFfsnnjgw7mfqs55XL?= =?us-ascii?Q?XwN2lv7kpZ9Qyh17BlrLsCXc6p3RuJaWg=2F8oES=2F?= =?us-ascii?Q?xmVgtlqp+evoVoH9RNcwuSw7F2Z8eujbFsmEEOs?= =?us-ascii?Q?YM2QDbm8p1g5EsOULknnUwdZZg=3D=3D?= To: ruby-core@ml.ruby-lang.org X-Entity-ID: u001.I8uzylDtAfgbeCOeLBYDww== Message-ID-Hash: JLTRKUN5ALBY6XA3UVQVHGIR4JRES5GM X-Message-ID-Hash: JLTRKUN5ALBY6XA3UVQVHGIR4JRES5GM X-MailFrom: bounces+313651-b711-ruby-core=ml.ruby-lang.org@em5188.ruby-lang.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.3 Precedence: list Reply-To: Ruby developers Subject: [ruby-core:117465] [Ruby master Bug#20050] Segfault on Ruby 3.2.2 (and 3.1) on x86_64 Darwin 20 (rb_id_table_lookup for #hash) List-Id: Ruby developers Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: "nagachika (Tomoyuki Chikanaga) via ruby-core" Cc: "nagachika (Tomoyuki Chikanaga)" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Issue #20050 has been updated by nagachika (Tomoyuki Chikanaga). Backport changed from 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: REQUIRED, 3.3: DONTNEED to 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: DONE, 3.3: DONTNEED Merged https://github.com/ruby/ruby/pull/10394. @kjtsanaktsidis Thank you for the pull request. ---------------------------------------- Bug #20050: Segfault on Ruby 3.2.2 (and 3.1) on x86_64 Darwin 20 (rb_id_table_lookup for #hash) https://bugs.ruby-lang.org/issues/20050#change-107854 * Author: martinemde (Martin Emde) * Status: Closed * ruby -v: ruby 3.2.2 (2023-03-30 revision e51014f9c0) [x86_64-darwin20] * Backport: 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: DONE, 3.3: DONTNEED ---------------------------------------- Hi, In the rubygems & bundler repositories we've now had two segfaults in the same exact code within days of merging a change to that code, both on ruby 3.2.2 on darwin20. 1. https://github.com/rubygems/rubygems/actions/runs/7110489973/job/19357067789?pr=7129 2. https://github.com/rubygems/rubygems/actions/runs/7131889001/job/19421304163?pr=7228 The specific error seems to happen when calculating the hash of the array in Gem::NameTuple#hash. The array contents that is being `.hash`ed both times should be exactly: `["has_metadata", "1.0", "ruby"]`. If I'm reading this correctly, this indicates that the crash is related either to creating this hash or storing this hash in the hash table (I'm not quite sure which is triggering the crash). An excerpt of the C backtrace shows the same backtrace for both crashes: ``` -- C level backtrace information ------------------------------------------- /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_vm_bugreport+0x7c4) [0x10cb0f994] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_bug_for_fatal_signal+0x1d0) [0x10c9158c0] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(sigsegv+0x5b) [0x10ca609ab] /usr/lib/system/libsystem_platform.dylib(_sigtramp+0x1d) [0x7ff810c14dfd] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_id_table_lookup+0x16) [0x10caa2a56] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(callable_method_entry_or_negative+0x5e) [0x10cae9c8e] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_check_funcall_basic_kw+0x129) [0x10caf0039] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(obj_any_hash+0x3c) [0x10c94bd2c] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(any_hash+0x52) [0x10c94bc12] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_st_add_direct+0x1d) [0x10ca69b7d] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(ar_try_convert_table+0x85) [0x10c94d015] /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/libruby.3.2.dylib(rb_hash_aset+0x18f) [0x10c94e26f] ``` I'm not sure how to follow this instruction in this case on GitHub actions: "Don't forget to include the Crash Report log file under DiagnosticReports directory in bug reports." I have not been able to reproduce this locally with the same version of ruby (but I'm on darwin22 instead of 20). I will follow up if we continue to see this same crash. -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/