From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qk1-x72a.google.com (mail-qk1-x72a.google.com [IPv6:2607:f8b0:4864:20::72a]) by sourceware.org (Postfix) with ESMTPS id ECDAD3857C57 for ; Thu, 24 Sep 2020 15:21:57 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org ECDAD3857C57 Received: by mail-qk1-x72a.google.com with SMTP id o5so3559463qke.12 for ; Thu, 24 Sep 2020 08:21:57 -0700 (PDT) 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:content-transfer-encoding; bh=aVFQdM8uch6XKX97JmvCXfm0PnDBF6+W8NjxhcCgvwQ=; b=NBdepaiLwFvNsbqAywqKc9xGeLZOORAKglCLkMLLBqj6hqbCO26OCPgLnWXYBDmRqg gc0Wll7GubgY6v6VOMwX4DKzrDBCUp2RHYem/yEa4W4NFkIxk1PhK3gbG/SafJVHA3nK 197BjjCIByW5WHs/2HrifxmEeI3uuX4RSMKyRCpWJSG1vDW47x8P/Jj8Cx6INUDFO6kZ mZHg2WRHGi58RBwcUfJhvLkNlrVIBH9FOm/y3+aa3qNg0uIrKqzBM0+DFr7WgrSV6Ly3 V+C20q1P5lzaVR85DAqRd5LVyhn4gEa0jkuKsjXIhdygbyBW1i9lTbUUwbRldfXT1MHa M9dw== X-Gm-Message-State: AOAM531gEz8yxd0QWDHMopD4kkKfHIoE9zsH42TVuwCJFlUEE2PfuPsZ SmSGpk7sFlftZ4w6hLTrwiyXzVDExLNm1WruRsmXBrdXIdU= X-Google-Smtp-Source: ABdhPJxkFpBBb3G5+ErtK/c3haMMlRjUdSQf0hCs9BBXSkmAMzpoBVasR7bQCdkeL+Uj9tYH7ijH1qqsKrh1byIgIpE= X-Received: by 2002:a05:620a:103c:: with SMTP id a28mr167458qkk.376.1600960917382; Thu, 24 Sep 2020 08:21:57 -0700 (PDT) MIME-Version: 1.0 References: <28250680-67b9-7551-72fb-bb5826eeecbd@simark.ca> <20200924082621.19370-1-sergey.belyashov@gmail.com> <34795027-0954-e286-dc1a-1f810a8ff6e1@simark.ca> In-Reply-To: <34795027-0954-e286-dc1a-1f810a8ff6e1@simark.ca> From: Sergey Belyashov Date: Thu, 24 Sep 2020 18:21:46 +0300 Message-ID: Subject: Re: [PATCH] [gdb] Add Z80 CPU basic support To: Simon Marchi Cc: gdb-patches@sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-6.1 required=5.0 tests=BAYES_00, BODY_8BITS, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Sep 2020 15:21:59 -0000 =D1=87=D1=82, 24 =D1=81=D0=B5=D0=BD=D1=82. 2020 =D0=B3. =D0=B2 17:08, Simon= Marchi : > > Thanks, I was able to apply it successfully. It doesn't build, however, > please make sure it builds against the current master. Yes, you are right. I was surprised too. Fixed patch will be in the next em= ail. > Some questions: > > - What's the history behind this code? Is is currently maintained > somewhere else? Do you own it all? In order to push that code (and > transfer the copyright to the FSF), everybody who currently owns it > must have an assignment on file, normally. This code is written by me from scratch. Some code parts are copied from other GDB source files. > - How do you test this? How can I test this? Add this to the commit > message. I have tested it on my embedded device. > - Did you manage to run parts of the GDB testsuite against this? GDB testsuit cannot be used, because there are no GCC port to Z80. > - If I want more information about the Z80 architecture, such as the ISA > details, ABI, etc, where do I look? It would also be a good idea to > add this to the commit message. It can be downloaded on Zilog offical site. > - I see mention of "eZ80". Can you provide information about what CPUs > are supported, what CPUs are not supported? Include any relevant > detail like that in the commit message. eZ80 in Z80 mode is supported. I have no device with eZ80 working in ADL mo= de. > We want to avoid people dropping code and then leaving a maintenance > burden to others. Ideally, each architecture should have a maintainer > (listed in the MAINTAINERS file) responsible for reviewing patches about > that architecture, and to whom we can reach out for questions about that > architecture. Would you be ready to accept such a role? Yes, I'm ready. > Shouldn't there be two different target descriptions for Z80 and eZ80? I have not completely supported the eZ80 in ADL mode, so I do not provide a description for it. In legacy Z80 mode eZ80 has the same registers and flags as Z80/Z180. > > diff --git a/gdb/stubs/z80-stub.c b/gdb/stubs/z80-stub.c > > new file mode 100644 > > index 0000000000..36316b95ba > > --- /dev/null > > +++ b/gdb/stubs/z80-stub.c > > What is this file for? How do I use it? This file is used as an embedded debugger monitor. Currently GDB is tested with it. Best regards, Sergey Belyashov