From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 9300 invoked from network); 2 Aug 2021 00:18:56 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 2 Aug 2021 00:18:56 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id F257B9CA64; Mon, 2 Aug 2021 10:18:53 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 044AE9CA63; Mon, 2 Aug 2021 10:18:37 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (2048-bit key; unprotected) header.d=ccil-org.20150623.gappssmtp.com header.i=@ccil-org.20150623.gappssmtp.com header.b="oedB7FWi"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id B2F619CA63; Mon, 2 Aug 2021 10:18:35 +1000 (AEST) Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) by minnie.tuhs.org (Postfix) with ESMTPS id 5BD1D9CA60 for ; Mon, 2 Aug 2021 10:18:34 +1000 (AEST) Received: by mail-qt1-f179.google.com with SMTP id g11so10597697qts.11 for ; Sun, 01 Aug 2021 17:18:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ccil-org.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=PhSXgXfxXDLy2Qgn9s1SW8bAkKAltThW4/vfvsaMSuM=; b=oedB7FWiFLdD1mKilFrStsnPUcK24eD/I4+0P0InfLY3meznx9FiFm8AkHhQPYEQhL Sc4BtIAHsrBSKruGH/5ghQpuvjP58/CLjE5PHo97U7RJVz4HsJmXvRRkhcGjTZ5aXd7u b3uDZQF0Q8qLbOO8y2yn6R7HD76hSM2sJQnqW6sQRzsrE9l2163iX5Kg1aCM6SrnHVQC 1wPVFAsCVGc+0F3Y/ezjek4k3Ky9ti+vl6gs/5DHkoo60IQ5FUdBEBj0e62j+4Jj9o2K QN5rezydQJQ7ueWWIU14ABWmyEB9qnBbVRVvFE+fZWKiPx7zW5rK9/tN3tquGPG6iase zKNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=PhSXgXfxXDLy2Qgn9s1SW8bAkKAltThW4/vfvsaMSuM=; b=qKwpPdPNTZDFanqOyD1dp2n1vqK6G2x3UuZYq99Tjck3O7ZyiBazHh9hIePkDIOgsz eej+I6Qymti49SIHzF7Xn+beqsCEqbLnx0/c3DBmGerdsozOecHLsxsDM+5IPNslUdBj 1t0Z0tHnXSgZmLPS+ljooEJvLPfSFF0g7y8wOL4DX+QUnngluliVLYlVyUEXAYrBOnbF BolgPKhdUBTFrscgirWk+fkxTMiGKKOH+KORcswDASb2l0dM5zNtmgQADqoiRUWyk+CA 6Ngr1UxU7lnZCK0mv6GOiDa9zwaa5jMUi5sCMR1OHJ5SkED4wzDnRstprI11Jp1ZMQOX dAdg== X-Gm-Message-State: AOAM531o1nc0PXXBH4/tpPiK6V3Mfegpj/kRrwcU9+Dm3++THLxDlif7 29/N/li/LuK/OPDN8kJJhl9qCk7nPUHU2UFFeDFIHQ== X-Google-Smtp-Source: ABdhPJwNmW/Lx4cRgSzH+lh6wn9wBWhXvZGIGm9BSTvEEwhH3WjX+9ZfMg8TZrTgQFY5n9Lyr8o+KZmDS0TfSPyZXds= X-Received: by 2002:aed:2163:: with SMTP id 90mr12036986qtc.186.1627863513568; Sun, 01 Aug 2021 17:18:33 -0700 (PDT) MIME-Version: 1.0 References: <20210731142533.69caf929@moon> <40763c2d-52ad-eb01-8bf8-85acf6fee700@case.edu> In-Reply-To: From: John Cowan Date: Sun, 1 Aug 2021 20:18:22 -0400 Message-ID: To: Andrew Warkentin Content-Type: multipart/alternative; boundary="00000000000078306205c88882e0" Subject: Re: [TUHS] Systematic approach to command-line interfaces 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 main list Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --00000000000078306205c88882e0 Content-Type: text/plain; charset="UTF-8" On Sun, Aug 1, 2021 at 8:13 PM Andrew Warkentin wrote To start the child the parent would either > call exec() to start the child running a different program, or call a > new function that starts the child with a parent-provided entry point > and whatever memory mappings the parent set up. > This is what I plan to do on the OS I'm writing > (manipulating the child's state won't require any additional > primitives beyond regular file I/O since literally all process state > will have a file-based interface). > In that case you don't need *any* primitive except create_empty_process(): you can do exec() by opening the file, writing to /proc//mem and then to /pc-and-go. --00000000000078306205c88882e0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Sun, Aug 1, 20= 21 at 8:13 PM Andrew Warkentin <= andreww591@gmail.com> wrote

To start the child the parent would either
call exec() to start the child running a different program, or call a
new function that starts the child with a parent-provided entry point
and whatever memory mappings the parent set up.
=C2=A0
This is what I plan to= do on the OS I'm writing
(manipulating the child's state won't require any additional
primitives beyond regular file I/O since literally all process state
will have a file-based interface).

In that case you don't need *any* primitive except cre= ate_empty_process(): you can do exec() by opening the file, writing to /pro= c/<child>/mem=C2=A0and then to <proc/<child>/pc-and-go.
--00000000000078306205c88882e0--