Re: [ogpx] type-system : eliminate closing tags for collections in binary serialization?

Joshua Bell <josh@lindenlab.com> Tue, 30 March 2010 18:12 UTC

Return-Path: <josh@lindenlab.com>
X-Original-To: ogpx@core3.amsl.com
Delivered-To: ogpx@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id DFCF93A6A1A for <ogpx@core3.amsl.com>; Tue, 30 Mar 2010 11:12:13 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 1.541
X-Spam-Level: *
X-Spam-Status: No, score=1.541 tagged_above=-999 required=5 tests=[AWL=-0.213, BAYES_50=0.001, DNS_FROM_OPENWHOIS=1.13, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id H+WAkVW752EE for <ogpx@core3.amsl.com>; Tue, 30 Mar 2010 11:12:13 -0700 (PDT)
Received: from mail-wy0-f172.google.com (mail-wy0-f172.google.com [74.125.82.172]) by core3.amsl.com (Postfix) with ESMTP id 92F4C3A69A6 for <ogpx@ietf.org>; Tue, 30 Mar 2010 11:12:10 -0700 (PDT)
Received: by wyb29 with SMTP id 29so5868208wyb.31 for <ogpx@ietf.org>; Tue, 30 Mar 2010 11:12:36 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.216.91.8 with HTTP; Tue, 30 Mar 2010 11:12:36 -0700 (PDT)
In-Reply-To: <f72742de1003282234x34e1d23dt9149c980af556500@mail.gmail.com>
References: <b325928b1003281034x68725d0h555d608e4c8a5d36@mail.gmail.com> <201003282129.59068.bobby@sharedrealm.com> <f72742de1003282234x34e1d23dt9149c980af556500@mail.gmail.com>
Date: Tue, 30 Mar 2010 11:12:36 -0700
Received: by 10.216.89.213 with SMTP id c63mr275518wef.8.1269972756351; Tue, 30 Mar 2010 11:12:36 -0700 (PDT)
Message-ID: <f72742de1003301112w749cb994kf7c8665500bbbcd8@mail.gmail.com>
From: Joshua Bell <josh@lindenlab.com>
To: ogpx@ietf.org
Content-Type: multipart/alternative; boundary="0016e6d464cc044acb048308930a"
Subject: Re: [ogpx] type-system : eliminate closing tags for collections in binary serialization?
X-BeenThere: ogpx@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Virtual World Region Agent Protocol - IETF working group <ogpx.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/ogpx>, <mailto:ogpx-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/ogpx>
List-Post: <mailto:ogpx@ietf.org>
List-Help: <mailto:ogpx-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ogpx>, <mailto:ogpx-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 30 Mar 2010 18:12:14 -0000

On Sun, Mar 28, 2010 at 10:34 PM, Joshua Bell <josh@lindenlab.com> wrote:

> However, having just implemented a binary serializer, it occurred to me
> that the 'k' indicator for map keys is also unnecessary baggage. If we are
> truly trying to minimize byte count, that could go too.
>
>
To clarify the above:

Map keys are always strings, and keys occur in predictable locations in a
stream based on context. Therefore, strictly speaking, *no* tag is
necessary; a binary LLSD parser would always know when to begin parsing a
key, and could start immediately with reading the four-octet length.

(But I'm not advocating for the removal of unnecessary bytes.)