From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lars Magne Ingebrigtsen Newsgroups: gmane.emacs.devel Subject: Pushing the `gnus-range-*' functions down into the C layer Date: Thu, 09 Sep 2010 17:16:56 +0200 Organization: Programmerer Ingebrigtsen Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1284045437 8319 80.91.229.12 (9 Sep 2010 15:17:17 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 9 Sep 2010 15:17:17 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Sep 09 17:17:16 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OtisG-0006oS-Ag for ged-emacs-devel@m.gmane.org; Thu, 09 Sep 2010 17:17:16 +0200 Original-Received: from localhost ([127.0.0.1]:39244 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OtisF-0000fV-Ob for ged-emacs-devel@m.gmane.org; Thu, 09 Sep 2010 11:17:15 -0400 Original-Received: from [140.186.70.92] (port=48373 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Otis7-0000fQ-1C for emacs-devel@gnu.org; Thu, 09 Sep 2010 11:17:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Otis3-0001ha-ES for emacs-devel@gnu.org; Thu, 09 Sep 2010 11:17:06 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:42206) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Otis3-0001hR-6C for emacs-devel@gnu.org; Thu, 09 Sep 2010 11:17:03 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Otis2-0006gm-LK for emacs-devel@gnu.org; Thu, 09 Sep 2010 17:17:02 +0200 Original-Received: from cm-84.215.34.171.getinternet.no ([84.215.34.171]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 09 Sep 2010 17:17:02 +0200 Original-Received: from larsi by cm-84.215.34.171.getinternet.no with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 09 Sep 2010 17:17:02 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 29 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: cm-84.215.34.171.getinternet.no Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAElBMVEUNAwYzEySiiZdyS2EC AABaNkvfwdThAAACXElEQVQ4jV2UTW7jMAyF6alnb8bVfkLBB7AI7lXAB4hM8P5XmUenyRSjpLDE j3z8kVP6HJ9ENPfjOGZ8+0xUIuJBCzMAHU9w0AGvY6ZOfe4vkCv3cIBzxnaaXmDBgXrnJZ3nn1Iw H9OEB/768lNqmdNGxHQgUermwgZbSqGFsoR3CF3HCWLz0Y/M984xzzDB/+gX+JccPc5ZAyL7f32A 8bOf/hNk6DSmJ/ic3+Brxij6WLL1LBIlIMf3ds56c6449X6lnxPQ/LVkH7SaPI4nOD5kHdSnhQGm IiJb9t6pidRB9JVgog9JgpC0izwmmnwhPH5dAKXzBf4Q/baFEHjWPDLzcoNSu0N8J0IrZ70/wQRw uwDue/DUxE5IYTXZXLaFy2CKPMZNKpSwuwMwXhOmnfkUP0U8wkTM5M7sajQKgOoLYJcAUuZ8q1Wb qLlKBfjDASeqziuOTeo3aDtbG4UU2TVUa0Y0VbdMEYVqIFIbTHAGVnhG0wYwrepNLnJp7UtgNMgR 4a+AXBaBGgFMo6GqmjJArbo6RkZyuZpmAaHuLdMkqCr44KfyVIEMWsqLQ0F5a54iifJKsiuyrK26 mADkcGqr4QCQtyvquWrdVE+4Ikcg+RvkCEKvPhT6Xr9JbaFWtG0niY3VWC9jKpVzL6fUnSTipiPc iymbxdrM0WBD8rJGcS0w+qg2wnBCDo/BA8ph656tY9rFr3IHB6srN9dawHEMrULbGL6XEgwvGMfu UGtIvmE+I98pBs+3Ee9EnAD3NeDDEXvbfCBGzfazPvA/yBSueLidiMU9u4c+/gLgZsDT5Qb6BQAA AABJRU5ErkJggg== Mail-Copies-To: never X-Now-Playing: Nadja's _Thoumogenesis_: "Thoumogenesis" User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:I36+XOapniqCOzXVLEkUvhHKEU8= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:129819 Archived-At: Would anyone mind if I implemented the `gnus-range-*' functions in C for Emacs 24? Gnus spends significant time on group entry/exit doing range handling/compressing/etc, and I think the functions are (slightly) generally useful. Gnus addresses articles by their number, so you have things like the "marked" list of articles that looks like (3 4 5 6 7 11 14 15 16 17 18) (or something). To save loading/saving time, these are stored in the .newsrc.eld file as range structures, which look like this: ((3 . 7) 11 (14 . 18)) To handle this, Gnus has a set of functions for computing intersections/differences/etc on the range structures. However, Emacs Lisp isn't really fast at doing this, so if you exit from a group that needs lots (I mean *lots*) of range handling, you get an annoying wait while it sits there computing. So I'm proposing implementing a set of useful functions in C, like `range-memq', `range-add', `range-intersection' and stuff. Thoughts? -- (domestic pets only, the antidote for overdose, milk.) larsi@gnus.org * Lars Magne Ingebrigtsen