From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf1-x433.google.com (mail-pf1-x433.google.com [IPv6:2607:f8b0:4864:20::433]) by sourceware.org (Postfix) with ESMTPS id CC1933857C46 for ; Wed, 3 Jan 2024 22:04:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CC1933857C46 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org CC1933857C46 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::433 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704319484; cv=none; b=bjVTlF+Uh+N7HFdhXIhavaR7vBwtt+eBK3jbeEaJucywW4NiWRNQst1kqiz8q9MV6YGrs0f4j3Kz1UMMBzzGfSs4lX6SS7ZxZJ2Cr0lK2aZB78LRQZ9bRhU7CSbmEHW3A+5h1YdSO6XikmzkXyTmQP2yZyFirGC8AFuLX6colLQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704319484; c=relaxed/simple; bh=5E9P1wJJ8+N29PjdaFdWnyNqLo6G6HUfgc8KQlSQKqc=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=L1WUMQfURn0XzZC9CzOb7t6qQaGd356fJ3koL7+mF/KJO5ioOQ3vrJ/IspdbmSO2BIHeT/g4AKaEI8Wq2obR/6jqs+B6ElBwe+LzhIZwx3UzBoT8+NdBzLvTTc511smDFo/PKmp7ExdW9Sk/v6Npw8LWrXxyZjqwnRr1n52SLiI= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pf1-x433.google.com with SMTP id d2e1a72fcca58-6da8c470e45so158448b3a.1 for ; Wed, 03 Jan 2024 14:04:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1704319481; x=1704924281; darn=gcc.gnu.org; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:to:subject:user-agent:mime-version:date :message-id:from:to:cc:subject:date:message-id:reply-to; bh=ude4LdUdEZg/4pLR69KugaF32tTrjlUgcYgkDlLoYPc=; b=ZmsuvlbFf+lciwUw64tvnkRPaTRLz19crB+VU2mt1aniGcqQ8khzkHD1f05ZyqZ0Mu m7VCzWjxStebftNRsV+xB0oKmZ8RTy+WQ9ZplV4lifGzs9a0xk3GuRP93jlL5HrNVtMJ J5Ed9QqHQYyrm/qqYt+sfYaR87MD1PS5QlH3+SMQvzj8lp0bJhiqe/R5fzSKjoPA+Psh 3B9x5kx6MicFkEoFlPgNkphtRggj3tespAKNNJubR8b414DvBFudmHtBK4fSPqNBhB/c IExuusCI3p/VvHPIPx/DBhrEW3w/eq0YHIC/bFvKYMfCuiFKsSKV9d23s56kkjX7kyUW IOVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704319481; x=1704924281; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:to:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ude4LdUdEZg/4pLR69KugaF32tTrjlUgcYgkDlLoYPc=; b=fzExN4THPDwF0d93WQ6FEM4JKnwEZMAEf+sCdOSXKhVJlMLZXGW6kwgpqK+z6/qi57 y6eQrrTvw2juc56TrPaxeIt9pfyGaJCaZOeerzMV0gKo8Z4laZX2pbSHfVF5xulwTspm QumodRZG22oGQIuLBxMOu1fyvTKT5ns3l7fb3EdWF7yYxWddadSCL+W5xylvrFqIvfpJ YXcEFrhHmFMFZzaAnSW+L+EIOyPwrzRjGbBwwEqDzWGPQ+vaX4W0NAbRPr8BhAoTt3BH Qg/TSECsAwWbu+b7V6SQvZyQF5uvBmhy2cJ5gVu/mvnkYwxJuki0ikGOsqX9J55xwx0a Rbdw== X-Gm-Message-State: AOJu0YzMGqp58VWidU5Lr4xn4i4+UYLLG5ME2L8R3ULGL4ODCXUgfC6y KdpmR6uv0CEsyuYb8OGJMjnScgyEx04= X-Google-Smtp-Source: AGHT+IGw2a47k8uPG0V0qC2Q7yBA/VgxlOLQrKfZIv5kz4qzDdYmBZufxYOOu5OCEjgXcL010/Rc9g== X-Received: by 2002:a05:6a00:1c8d:b0:6da:736d:67c8 with SMTP id y13-20020a056a001c8d00b006da736d67c8mr13861358pfw.3.1704319481391; Wed, 03 Jan 2024 14:04:41 -0800 (PST) Received: from [192.168.1.24] ([50.37.177.113]) by smtp.gmail.com with ESMTPSA id ks21-20020a056a004b9500b006d9b8725d29sm17562994pfb.139.2024.01.03.14.04.41 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 03 Jan 2024 14:04:41 -0800 (PST) Message-ID: Date: Wed, 3 Jan 2024 14:04:40 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] libgfortran: Bugfix if not define HAVE_ATOMIC_FETCH_ADD To: fortran@gcc.gnu.org References: <20231222023605.3894839-1-lipeng.zhu@intel.com> Content-Language: en-US From: Jerry D Autocrypt: addr=jvdelisle2@gmail.com; keydata= xjMEY5TlkxYJKwYBBAHaRw8BAQdAyrkRDhmJhSTTlV/50gJLlvliU6/Lm5C9ViKV8T9y1GnN HkplcnJ5IEQgPGp2ZGVsaXNsZTJAZ21haWwuY29tPsKJBBMWCAAxFiEEOFR0TS0390uh8dRV uWXAJaWpwWoFAmOU5ZMCGwMECwkIBwUVCAkKCwUWAgMBAAAKCRC5ZcAlpanBalsJAP4wdCiH 2Of9oZv1QWgZ/AVdbWFM3Fv47/WZQHOXfoZ9HgD6AkXrKeJ+6usST7PEaDJjptaViT1fLiYY V/6XaOKSsgLOOARjlOWTEgorBgEEAZdVAQUBAQdAdA7PczYnl07vnOT9oP/wvvMDd4HP09Zl g3LzwXQJWT8DAQgHwngEGBYIACAWIQQ4VHRNLTf3S6Hx1FW5ZcAlpanBagUCY5TlkwIbDAAK CRC5ZcAlpanBasF/AQCa5WjlsVpLsEiggZyT18MOJNAdeRd7wkGDUrwedHrvawD/cE1H+/Ms L1ZwvQiLfGdx8crigQqWTQyos4kH8Wx82wc= In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_00,BODY_8BITS,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 1/3/24 3:12 AM, Tobias Burnus wrote: > On 22.12.23 03:36, Lipeng Zhu wrote: >> This patch try to fix the bug when HAVE_ATOMIC_FETCH_ADD is >> not defined in dec_waiting_unlocked function. >> >> libgfortran/ChangeLog: >> >>       * io/io.h (dec_waiting_unlocked): Use >>       __gthread_rwlock_wrlock/__gthread_rwlock_unlock or >>       __gthread_mutex_lock/__gthread_mutex_unlock functions >>       to replace WRLOCK and RWUNLOCK macros. >> >> Signed-off-by: Lipeng Zhu > > The change looks good to me + I assume it will work, but have not tested > it myself. > > Downside is that it slightly breaks with the abstraction done with all > the macros, but it seems to be the simplest solution. > > What is really missing - and should be included in the commit message > (before the ChangeLog block) - is the following information: > >    As io.h does not include async.h, the WRLOCK and RWUNLOCK macros are > undefined. > ---- snip ---- Would it make sense to include or merge async.h into io.h? Jerry