From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qv1-xf30.google.com (mail-qv1-xf30.google.com [IPv6:2607:f8b0:4864:20::f30]) by sourceware.org (Postfix) with ESMTPS id 29A8F3857031 for ; Tue, 11 Aug 2020 15:57:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 29A8F3857031 Received: by mail-qv1-xf30.google.com with SMTP id x7so6182287qvi.5 for ; Tue, 11 Aug 2020 08:57:24 -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; bh=OgvU2svJ7EFM4cNMWGqEb5gFfQXpEeCAk0Kb1O3nBqA=; b=XsamHxY4A3SI80fsKnNXCq/o93ZJb52TQN808IbZANtzfp7cIEIwwgmc10vlB4UYi2 hUeUyjrBhuaDQtOqQY6bZC8HkpFX63YGJ4RgRwBFeS+dQpUO2PpVHNlYlYfB5sNAq640 LnywCl1N51b9XL7Q+KQjdJ5iK8fdkE3ksh1mYS8iIHHgtnUp8LKKGWkVPzs+Qatr+voC I3LyY6ZnyIYqF5rdgeVQPtEnzutnUDx68XKmtDFmG5ngTL8MT9R+CaL0l2kSJUFBARNv yR8zatI+QGO1UO49s+OTCNxMGKDHPoxvazA0UwjZOv4XXY61ZhFhNdpQaKnPIguwA9lB WNWw== X-Gm-Message-State: AOAM5304niiKVJIeIlICgywk2FrAYeM+N/ZoXPaLZ/LoFX/9R0yvmMCM p64Je/G6qPWz3l61Xf0E5aqRjuAYqkB5DAfTHDg= X-Google-Smtp-Source: ABdhPJyHshNGRY8l3zzWvHiAV1w4DriIwPbvsX3Wnta4Hd4R+yoDNoUR83BhLDqD8iibvT9aOcjhopmGKeW9tMhgPho= X-Received: by 2002:a0c:ca8f:: with SMTP id a15mr2044888qvk.46.1597161443679; Tue, 11 Aug 2020 08:57:23 -0700 (PDT) MIME-Version: 1.0 References: <20200427162914.GA21677@redhat.com> <87pnbsztze.fsf@gnu.org> <87lfmgzoic.fsf@gnu.org> <20200811153823.GA20457@redhat.com> In-Reply-To: <20200811153823.GA20457@redhat.com> From: Sergey Belyashov Date: Tue, 11 Aug 2020 18:57:12 +0300 Message-ID: Subject: Re: BUG: non-fixed-length ISAs are unsupported for now To: "Frank Ch. Eigler" Cc: Sergey Belyashov via Cgen Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, 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: cgen@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Cgen mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Aug 2020 15:57:25 -0000 Hi, Thank you for your response. > .... these sound like they could fit into a single isa. You could > have a family of ifields, one set for each of these prefix > combinations. (Many could have different names and bit offsets but be > otherwise the same.) Then for each instruction, you would have a set > of separate define-instruction's for each prefix combination (!), > using the corresponding ifields. Ideally, use a cgen macro to > generate the separate define-instructions, to factor out the > commonalities. I have already tried to stay within one ISA but my attempt fails. You may look here for full source of my try: https://github.com/b-s-a/binutils-gdb/blob/z80-cgen/cpu/z80.cpu (invalid decoder is generated for last 2 lines - "reti" (ED 4D) and "retn" (ED 45) instructions, I have tried many types of ifields with same result, but these are simpler to read). I cannot understand what I'm doing wrong. Best regards, Sergey Belyashov