From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from minnie.tuhs.org (minnie.tuhs.org [45.79.103.53]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 354643e6 for ; Wed, 28 Aug 2019 01:46:59 +0000 (UTC) Received: by minnie.tuhs.org (Postfix, from userid 112) id 905DA9BCA1; Wed, 28 Aug 2019 11:46:58 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 081469BC35; Wed, 28 Aug 2019 11:46:44 +1000 (AEST) Received: by minnie.tuhs.org (Postfix, from userid 112) id 70F739BC35; Wed, 28 Aug 2019 11:46:41 +1000 (AEST) Received: from mcvoy.com (mcvoy.com [192.169.23.250]) by minnie.tuhs.org (Postfix) with ESMTPS id 2CFC89BBFD for ; Wed, 28 Aug 2019 11:46:41 +1000 (AEST) Received: by mcvoy.com (Postfix, from userid 3546) id 9CEC635E0A8; Tue, 27 Aug 2019 18:46:40 -0700 (PDT) Date: Tue, 27 Aug 2019 18:46:40 -0700 From: Larry McVoy To: Arthur Krewat Message-ID: <20190828014640.GP13570@mcvoy.com> References: <20190827024511.GU13570@mcvoy.com> <20190827145556.GD13570@mcvoy.com> <20190827224002.GB15511@mcvoy.com> <20190827231625.55E991570CEA@mail.bitblocks.com> <20190827233338.GM13570@mcvoy.com> <20190828002141.40BE41570CE9@mail.bitblocks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Subject: Re: [TUHS] If not Linux, then what? X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tuhs@minnie.tuhs.org Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" On Tue, Aug 27, 2019 at 09:21:43PM -0400, Arthur Krewat wrote: > In re: the socket() thing... > > I remember getting into something (forget what) back in the early 90's, > writing something (again, I forget what) and realizing what I needed to do > to open a socket to a remote endpoint. > > I remember thinking "wait, I can't just open("hostname:port", O_TCP); ???" So that part is fine. > And, horror of all horrors, I need to deal with little/big endian things? > ntohs(), htons(), et al? That part is reality. You can send ascii and then pay the price for parsing that or you can send binary. These days, we have CPU cycles to burn so the ascii answer seems fine. It is, mostly, it's not when it is tons of small messages that need to be processed at millions or billions/sec. In the past, CPU cycles were not a given so lots of stuff was designed to not be parsed.