From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi1-x22c.google.com (mail-oi1-x22c.google.com [IPv6:2607:f8b0:4864:20::22c]) by sourceware.org (Postfix) with ESMTPS id 485B23858C2B for ; Fri, 1 Sep 2023 08:03:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 485B23858C2B Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-oi1-x22c.google.com with SMTP id 5614622812f47-3a81154c570so986791b6e.1 for ; Fri, 01 Sep 2023 01:03:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1693555404; x=1694160204; darn=sourceware.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ETQWbq5d3FwvMugQitmta+GUTd3m/D3iSSW/IkdggWQ=; b=ZbNnUJvjBD6yJ18OQLWL/2dnli0ecB/cg+lSyHulzavJJ513N8yvFfpbvBTJhUpDtm xkJaw0H7PCPwNSGrZI69Lx6mm9mYCp2US96w4WYvmdcZRXh1WFL+f3NTuF1ZWhtqvcNa S52HFBN+OLx1WsozIys5bmqJXaUB6lCrHoCUF/CIbtGyUa5+GxAvvegGhiqQ5C3iQ4eS rEyDAQwnPj+Z24ZX/5cyD20Iwgd8G4gXcftEXq7mz2JSrInzqKowr3ma9lKkbNsKeVXJ xp0ZZTuv8xCdrnKPqk9IgLD0cNLltS3W5oYu1p/IGjpjuxFlTcsE7jg4HmdN3GcMOOCm hNjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693555404; x=1694160204; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ETQWbq5d3FwvMugQitmta+GUTd3m/D3iSSW/IkdggWQ=; b=KCHdo4gsYCYwN9VxJ0jOpoXYRxFW7Qb4N1tFCx8mcapMjB9No7hP+BRKnI7pyQOhCc VW/BSF+SgQjyAjdKMI2sUeORtJf7pn+WvKAhlmW3D+lochy9Qibh4E9fWml3qaSlHnyZ QonNZRuu/dPXWPl2GICqO9v4/MHIEYfrcTB9xnHZWPlhhCoSejEu3hKFRmyfkPwLIRcq Vm0xGYZ+2FHISZMg1b4kXR2ab40j4VPrS/8XSA8G9watagcaLPqJQPrf5+ME3n3Tj6NZ Ntj5WEsHMwuAErskaWFlJIxnBP7jQi7gHnZYwMQZtvnTq5XGryAUXhncdRex7IP6CdgY Z7IQ== X-Gm-Message-State: AOJu0YynUDhO4gfRo/VlJzWZwfLsdDs9zGo/l2NXtjApYeX2GisbbDpK qiTkXlBEADVdqrG8kP36OF/WPSpEgr4jZua7moM5gA== X-Google-Smtp-Source: AGHT+IGkv4njJW8s8PDNRFHmWiCu95Yi1I70GQSlr/DMqGA0KIeKMACcZYQJAriaY70Uq/7/R2E+3xQiNJqA20NSNmw= X-Received: by 2002:aca:1c17:0:b0:3a8:6c27:c1f6 with SMTP id c23-20020aca1c17000000b003a86c27c1f6mr1738761oic.19.1693555404573; Fri, 01 Sep 2023 01:03:24 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Nelson Chu Date: Fri, 1 Sep 2023 16:03:13 +0800 Message-ID: Subject: Re: [RISCV] [GNU AS] Possible `vmsge{u}.vx` instruction lowering bug? To: Kiva Oyama Cc: Jan Beulich , binutils@sourceware.org Content-Type: multipart/alternative; boundary="0000000000004c245d0604479881" X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --0000000000004c245d0604479881 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks for both your clarifications, committed. Thanks Nelson On Fri, Sep 1, 2023 at 2:37=E2=80=AFPM Kiva Oyama wrote: > > Is the following expected? > > Yes. > > > Seems "vd is any" also has the same issue. > > I rechecked the spec, for every masked vmsge{u}.vx, the lowered > instruction is only masked when `vd !=3D v0`. > So your patch does fix these two problems. > > Thank you for clarifying. > > Best Regards, > Kiva Oyama > > On Wed, Aug 30, 2023 at 1:51=E2=80=AFPM Jan Beulich w= rote: > >> On 30.08.2023 04:51, Nelson Chu wrote: >> > Hi Jan, >> > Thanks for pointing that out. >> > >> > Hi Kiva, >> > Maybe you can send a better patch for this issue if you are interested, >> > including what Jan suggested. Thanks :-) >> >> Hmm, both of your replies above make me suspect a misunderstanding: I >> think your patch does exactly what is needed. >> >> Jan >> >> > On Tue, Aug 29, 2023 at 4:52=E2=80=AFPM Jan Beulich wrote: >> > >> >> On 29.08.2023 09:59, Nelson Chu wrote: >> >>> Is the following expected? >> >> >> >> I think so, but Kiva - please confirm. >> >> >> >>> Seems "vd is any" also has the same issue. >> >> >> >> Right, that's what ... >> >> >> >>>> I think this wants fixing alike in binutils: From looking at >> >>>> vector_macro(), >> >>>> it appears that emitting the masked form is merely an accident >> resulting >> >>>> from the inverted encoding of "masking". In particular, if masking >> was >> >>>> indeed meant, I expect code there would be >> >>>> >> >>>> if (vd =3D=3D vm) >> >>>> { >> >>>> macro_build (NULL, "vmslt.vx", "Vd,Vt,sVm", >> vtemp, >> >>>> vs2, vs1, vm); >> >>>> macro_build (NULL, "vmandnot.mm", "Vd,Vt,Vs", >> vd, >> >>>> vm, vtemp); >> >>>> } >> >>>> else >> >>>> ... >> >>>> >> >>>> much like it is a few lines down from there. (Apparently the "else" >> path >> >>>> omitted above is similarly affected.) >> >> >> >> ... I was referring to with the parenthesized sentence. >> >> >> >> Jan >> >> >> > >> >> --0000000000004c245d0604479881--