From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Linus_Bj=C3=B6rnstam?= Newsgroups: gmane.lisp.guile.user Subject: Re: is there a way to serialize hash tables? Date: Sat, 26 Dec 2020 13:10:03 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15116"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Cyrus-JMAP/3.3.1-61-gb52c239-fm-20201210.001-gb52c2396 Cc: guile-user To: "John Cowan" , "Tim Meehan" Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Sat Dec 26 13:10:58 2020 Return-path: Envelope-to: guile-user@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kt8PS-0003qq-Bk for guile-user@m.gmane-mx.org; Sat, 26 Dec 2020 13:10:58 +0100 Original-Received: from localhost ([::1]:42834 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kt8PR-0003SJ-Cj for guile-user@m.gmane-mx.org; Sat, 26 Dec 2020 07:10:57 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37366) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kt8P1-0003Rp-7z for guile-user@gnu.org; Sat, 26 Dec 2020 07:10:31 -0500 Original-Received: from wout1-smtp.messagingengine.com ([64.147.123.24]:47511) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kt8Oz-00045P-8W for guile-user@gnu.org; Sat, 26 Dec 2020 07:10:31 -0500 Original-Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.west.internal (Postfix) with ESMTP id 0075BAF3; Sat, 26 Dec 2020 07:10:25 -0500 (EST) Original-Received: from imap1 ([10.202.2.51]) by compute6.internal (MEProxy); Sat, 26 Dec 2020 07:10:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.se; h= mime-version:message-id:in-reply-to:references:date:from:to:cc :subject:content-type:content-transfer-encoding; s=fm2; bh=9MBOA 5IJQVru/W4U4vua1qh8WS4NgI3ljr9JxrgS0Pw=; b=f9JnI15QL6mL7rC7OunBB jGzebb5ywDI/l5lC2PZwZq5g0JxkxOFPjtQ40EGWW6Z8lOO6WITOISU8Ni5b0pjj so48OMBfTEGEnbfdjFdZdAU9mTrflY5tFKlNL29Ccz/0f4EojCaST56pMPHd9bIZ LOWBvR2+446cuhkHAP3vdkzxzX3/KigV0sBw8JBapGwvUTntRijpgtJUAFgJz8nj jVkCgUxlvljECT81X28w6xcz5vJuZIGGUM7vUPAU+7w2qU1UC0nJEQgoQ5g6Wt7+ jmIYYkh/8PQgqBrddXWjPwHFka8sT1EcPYznVex14e8aeEx1aG6YOJgO6reZgGAR g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=9MBOA5IJQVru/W4U4vua1qh8WS4NgI3ljr9JxrgS0 Pw=; b=nurs3XPGeBRwEjP9VEmsBBYH7kxKeUE1iFJIs4NZ/O73ybxdWl3aj45w1 3Iu82AeXAY+df4bM4Vfw/U0jzUeIV5Ctean/hyn4Gzi4pheT23YioEgD+1qMhBXg eO+T+P4iewn8ijrgTRmLQSr0Egp965GQID8R8Uq0f1NhKLgsDi4bgM7WzWkFvMn4 00wPKKEk1BvY03b/GH2H7clJTxwt9uDsf/NXAeO3F6scsuWgLcBI8XN1iGCcPZEx ZPwLa+wlxbhtj+CeR6e6tgXkpnpyDVt5Vdw/RofYIqGAEMXJ4fKlbfCnHA8u2sBt Kiu9sFkv3rKvJJTIWu0fDa6ixbizg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrvdduhedgudekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgfgsehtqhertderreejnecuhfhrohhmpefnihhn uhhspgeujhpnrhhnshhtrghmuceolhhinhhushdrihhnthgvrhhnvghtsehfrghsthhmrg hilhdrshgvqeenucggtffrrghtthgvrhhnpeekleevieevleejffetieeltdelkeevtedu heefheduieffffdttdegjeeihedtjeenucevlhhushhtvghrufhiiigvpedtnecurfgrrh grmhepmhgrihhlfhhrohhmpehlihhnuhhsrdhinhhtvghrnhgvthesfhgrshhtmhgrihhl rdhsvg X-ME-Proxy: Original-Received: by mailuser.nyi.internal (Postfix, from userid 501) id 9130EC200A5; Sat, 26 Dec 2020 07:10:25 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface In-Reply-To: Received-SPF: pass client-ip=64.147.123.24; envelope-from=linus.internet@fastmail.se; helo=wout1-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:17114 Archived-At: Alex and I got the speed of guile-json up to about 19megs a second under= guile 3 on a 4 year old intel i5, which may or may not be adequate for = your needs, Tim. I have some code I wrote during that spurt that preforms slightly better= than guile-json in general (about 3-4% on my machine. Alex could not re= peat those numbers) an on files with many large strings in particular (1= 0% in extreme cases). If that is interesting I could put it online some= where. The functioning code is a derivate work of guile-json, so the GPL= applies. --=20 Linus Bj=C3=B6rnstam On Sat, 26 Dec 2020, at 05:28, John Cowan wrote: > I think that's the best bet, although JSON is also a possibility. I'm= > working on a more general text-serialization solution, but it will be = quite > some time before I have a chance to work on it. >=20 > On Fri, Dec 25, 2020 at 10:28 PM Tim Meehan wrote= : >=20 > > I have a big-ish blob of key-value pairs that I would like to not ha= ve to > > store as text and then convert to a hashtable when I am filtering my= data. > > > > Right now I am saving it as an alist and then converting back to a > > hashtable using "alist->hashtable" from SRFI 69. I was just hoping t= hat > > there was something more clever ... perhaps it is plenty clever enou= gh. > > >