From patchwork Sat Oct 12 19:33:58 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alex Griffin X-Patchwork-Id: 15698 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 19520174E1; Sat, 12 Oct 2019 20:35:12 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id AA607173D5 for ; Sat, 12 Oct 2019 20:35:11 +0100 (BST) Received: from localhost ([::1]:35716 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iJNAV-0005hD-6h for patchwork@mira.cbaines.net; Sat, 12 Oct 2019 15:35:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51664) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iJNAN-0005gP-8Y for guix-patches@gnu.org; Sat, 12 Oct 2019 15:35:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iJNAM-0007x7-0q for guix-patches@gnu.org; Sat, 12 Oct 2019 15:35:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:53628) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iJNAL-0007x0-SE for guix-patches@gnu.org; Sat, 12 Oct 2019 15:35:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iJNAL-000072-O4 for guix-patches@gnu.org; Sat, 12 Oct 2019 15:35:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#37717] [PATCH 1/3] gnu: Add ghc-atomic-primops. References: <4551b258-a4e3-49f8-9c22-5840edbbd3a7@www.fastmail.com> In-Reply-To: <4551b258-a4e3-49f8-9c22-5840edbbd3a7@www.fastmail.com> Resent-From: "Alex Griffin" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 12 Oct 2019 19:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 37717 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 37717@debbugs.gnu.org Received: via spool by 37717-submit@debbugs.gnu.org id=B37717.1570908868376 (code B ref 37717); Sat, 12 Oct 2019 19:35:01 +0000 Received: (at 37717) by debbugs.gnu.org; 12 Oct 2019 19:34:28 +0000 Received: from localhost ([127.0.0.1]:34212 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJN9n-000060-Ue for submit@debbugs.gnu.org; Sat, 12 Oct 2019 15:34:28 -0400 Received: from out5-smtp.messagingengine.com ([66.111.4.29]:46755) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJN9m-00005c-CQ for 37717@debbugs.gnu.org; Sat, 12 Oct 2019 15:34:26 -0400 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 3DE9C20C55 for <37717@debbugs.gnu.org>; Sat, 12 Oct 2019 15:34:21 -0400 (EDT) Received: from imap6 ([10.202.2.56]) by compute6.internal (MEProxy); Sat, 12 Oct 2019 15:34:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ajgrf.com; h= mime-version:message-id:date:from:to:subject:content-type; s= fm1; bh=hlYS+IgVyvr/o8fDuLX/bfIcmaYBidNriuuuW9chErg=; b=bMFshDx3 CMBaY3jXagkFo9bzuF7ABGLcKGryRx80LU3xBrXyOesMhVRBF5+WL6rVrbSRMtmL HOLey0J4D0nEvfktLPbhyskxnC6Bw76+Ky9okG+HjBjGvKXMTasK1d7VWyZMnUpQ gyYGqodSh7GiXBFuvAmeKwZJzq8J9uK678FJnlo5twplm0c3xA4dd239YobQL3tx 3goEAkrV/nOMbP7ARr0x/404l8uLyJOWOu3+tddTir7ruKNTVJ/t32iczFdPhXcT 6Qfg0eVnki3717SySe/a+78uwsDnX7gvyexaXu7Sectax+6bNtP4b5OTWRa6aL2i 09IXC9VksEdRzw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:message-id :mime-version:subject:to:x-me-proxy:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; bh=hlYS+IgVyvr/o8fDuLX/bfIcmaYBi dNriuuuW9chErg=; b=HA4eFvuWxK0GtHEkWw2wChkskFOIscNS3O/LuFwWgv9OU CCUY6h5mCwGZtV+UxUtTNz6jLYJ17AahqcgOaWQnjJkLr77S53WEQaWuR7fshweP eHVQp33SxkEbiEhnTUVJ6N6Wq6tCAuM6RnUegUjY49XYSy9uHrdd0SfPhpQ2lkTg u0/i6lp61MwLk+xWLXvIyWh+LQW+AjFreD9wM4AaYLWa1hyyy8YA5kIapp2rPqQX d7ZzLLH2HivEe1Q9uz/ImgwEkJio8b2RRvkis3xa7hMLv2ku6WjD62VtNy0xdWCj 5L/15JHORCCK23QE0IwdUjKvvyJqVko9BQhWjdFeA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedufedrieejgddufeelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefofgggkfffhffvufgtsehmtderre erredtnecuhfhrohhmpedftehlvgigucfirhhifhhfihhnfdcuoegrsegrjhhgrhhfrdgt ohhmqeenucfrrghrrghmpehmrghilhhfrhhomheprgesrghjghhrfhdrtghomhenucevlh hushhtvghrufhiiigvpedt X-ME-Proxy: Received: by mailuser.nyi.internal (Postfix, from userid 501) id 0D1291400A2; Sat, 12 Oct 2019 15:34:21 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.1.7-360-g7dda896-fmstable-20191004v2 Mime-Version: 1.0 Message-Id: Date: Sat, 12 Oct 2019 19:33:58 +0000 From: "Alex Griffin" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From 77ff329dd34d307f19629086baf44c1623858fa1 Mon Sep 17 00:00:00 2001 From: Alex Griffin Date: Sat, 12 Oct 2019 13:34:43 -0500 Subject: [PATCH 1/3] gnu: Add ghc-atomic-primops. * gnu/packages/haskell-xyz.scm (ghc-atomic-primops): New variable. --- gnu/packages/haskell-xyz.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index 2977398880..37df2ed909 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -21,6 +21,7 @@ ;;; Copyright © 2019 Jacob MacDonald ;;; Copyright © 2019 John Soo ;;; Copyright © 2019 Kyle Meyer +;;; Copyright © 2019 Alex Griffin ;;; ;;; This file is part of GNU Guix. ;;; @@ -381,6 +382,31 @@ over threads in Haskell, in which @code{Async a} is a concurrent thread that will eventually deliver a value of type @code{a}.") (license license:bsd-3))) +(define-public ghc-atomic-primops + (package + (name "ghc-atomic-primops") + (version "0.8.3") + (source + (origin + (method url-fetch) + (uri (string-append + "https://hackage.haskell.org/package/atomic-primops/atomic-primops-" + version + ".tar.gz")) + (sha256 + (base32 + "03n5dmyplrqgbyf8dr91izkxci7gkl3i3fnp82i5ld869zrgjfh0")))) + (build-system haskell-build-system) + (inputs `(("ghc-primitive" ,ghc-primitive))) + (home-page "https://github.com/rrnewton/haskell-lockfree/wiki") + (synopsis "Safe approach to CAS and other atomic ops") + (description + "After GHC 7.4 a new @code{casMutVar#} primop became available, but it's +difficult to use safely, because pointer equality is a highly unstable property +in Haskell. This library provides a safer method based on the concept of +@code{Ticket}s.") + (license license:bsd-3))) + (define-public ghc-atomic-write (package (name "ghc-atomic-write") -- 2.23.0