From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf1-x42d.google.com (mail-pf1-x42d.google.com [IPv6:2607:f8b0:4864:20::42d]) by sourceware.org (Postfix) with ESMTPS id 999913858D37 for ; Tue, 16 Apr 2024 21:06:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 999913858D37 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 999913858D37 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::42d ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1713301569; cv=none; b=dPASt2lJj78xH3K+6m+ThhJIjCdwLc8jPJhEAzLOV3bXoUEum2FHkgaJtqTXv6o4TXBzvV4LxgD2g3oLOScl/mzUXsmr1hC3oK4BfYXXoXKZlTU9OKjZxgeyLquAcQa8omQrtReTNUwBifSdH64+Dsp5AmFgK9d4/C59pJEBbpo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1713301569; c=relaxed/simple; bh=To28htZR6tII98cDiNSQzW2XDfxUJT3o3Vdk5rVB6TQ=; h=DKIM-Signature:Date:Subject:From:To:Message-ID:Mime-Version; b=Mk6hMMuJzMSynIlR6jk3nKkgf6jB0PMRr6chNrlA0zVOHqb2D8Rot5ZoYHIEvlvMq1E5KeQCwzqYRRuKgK4GSQNF3OU59A1dSK0c+FJYl67NxzGVTukb5mX7IxN69vFsm54ko37yPDgd4tj7pt1pdNXXWQPz09ZbXV4sjcbdNWI= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-6f00f24f761so1982225b3a.3 for ; Tue, 16 Apr 2024 14:06:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1713301563; x=1713906363; darn=sourceware.org; h=content-transfer-encoding:mime-version:message-id:to:from:cc :in-reply-to:subject:date:from:to:cc:subject:date:message-id :reply-to; bh=8WSuIVEWbMMDrFwvLzqtrQUGyzDjsKT0ITsOkI0c3QM=; b=pP89gPAzlDDCyvbXqZtRYelRwFoG+lyCqRle1HLK0uSTbPyEP9iW/Ig9ewv90Q5B3R OEKPHR/19qdhlhcMWFAGEBiK25+DZxNMzW23MIGsASlpIK0YyFrWZEgntOFjcT2qLlgy jzHZONTk3cZqh8ku0fGYFJwkDg2ft+oiIL45XM9GyZ9Av3/5gaN8GH6plktMkog50/wG jYP7VqJTfLkYQGCzWps6NgI9rI1YaK8WQSzbwLcBdiYF9Dd75pQFtq653Xx4LnpLjUdS Anj3t4XlqdyNjwxinidZOJR3X3aRce1cATHIM1GONEZyOuGx9U5H6anRK+qbLuWfjMaF nZWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713301563; x=1713906363; h=content-transfer-encoding:mime-version:message-id:to:from:cc :in-reply-to:subject:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=8WSuIVEWbMMDrFwvLzqtrQUGyzDjsKT0ITsOkI0c3QM=; b=Lv3sTbuCT6grXXNnTZN42eT0mLIcsX0zdq98UNIaVsmLBfy4JsFthnGBPA09Ayyy2V dLQwSqG9GCp4itTi2IP4Rb3f1t4rSgY0nv8D4eA16rZHoaHFh6KWwVo3CueFE4UXlYU4 IsRToi3akbpqqeMs1qUBAVOM6FoKOqhIOrjtP7jv7vUwlqIi9A3NfldkuqZXFyaJrUe2 zRTeIZfKL921Zwb/9JL9coy0qHfQC8GJQgzLcbhjqfeuz6pRW02xcCtmByD5RM+r4M+y 25pCeFnQ3/aN6ngqqJvJkAoaEqkbtCnw3T7g3sA6rwxRh4LOwfowiSfoYJNe1+EB8OvI VGkA== X-Gm-Message-State: AOJu0YzOh315enePrPtS+NOMPN9aJ0oPIlpliKg96bq3uNW/FFZJAwyy jv0FQp3LkBD47tlI+I7jKpIra6MkJSIqM0N0TY1WhdabhzL1+Ljjdd/2PiSWCpGIgqXpZ5PHkI3 O X-Google-Smtp-Source: AGHT+IGgK+mzoUhqVvM0HsTXLg3/0am40MpK5R2Q44Rm63Fib5nK6eVx6hdZrOPFEJwkvJK4FVlXeA== X-Received: by 2002:a05:6a00:22c2:b0:6ed:def7:6acb with SMTP id f2-20020a056a0022c200b006eddef76acbmr15671185pfj.14.1713301562891; Tue, 16 Apr 2024 14:06:02 -0700 (PDT) Received: from localhost ([50.145.13.30]) by smtp.gmail.com with ESMTPSA id s23-20020a056a00179700b006ecf3ff65absm9467549pfg.104.2024.04.16.14.06.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Apr 2024 14:06:01 -0700 (PDT) Date: Tue, 16 Apr 2024 14:06:01 -0700 (PDT) X-Google-Original-Date: Tue, 16 Apr 2024 14:05:59 PDT (-0700) Subject: Re: [RFC] build-many-glibcs: Add a rv64gcbv-on-rv64gc/lp64d sub-variant In-Reply-To: CC: libc-alpha@sourceware.org From: Palmer Dabbelt To: Darius Rad Message-ID: Mime-Version: 1.0 (MHng) Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,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: On Tue, 16 Apr 2024 13:41:15 PDT (-0700), Darius Rad wrote: > On Tue, Apr 16, 2024 at 09:04:24AM -0700, Palmer Dabbelt wrote: >> On Tue, 16 Apr 2024 07:55:38 PDT (-0700), Darius Rad wrote: >> > On Mon, Apr 15, 2024 at 02:36:59PM -0700, Palmer Dabbelt wrote: >> > > On Mon, 15 Apr 2024 13:24:14 PDT (-0700), Darius Rad wrote: >> > > > Is this really lp64d? >> > > >> > > I guess that depend on what you mean by "ABI". Passing `-march=rv64gv >> > > -mabi=lp64d` will result in binaries that require the V extension to run, >> > > but can be linked with any other binary that is compiled with `-mabi=lp64d`. >> > > It's essentially the same as `-march=rv64g -mabi=lp64`, except for vector >> > > instead of float. >> > > >> > >> > Got it. I thought that might be the case, but wasn't sure if the vector >> > calling convention leaked in with the arch switch only (and not the abi). >> >> The intent was to avoid that, but GCC-14 will be the first release with any >> meaningful vector codegen so I guess we'll find out if we have any bugs ;) >> >> > > > What is the status of the vector ABI? >> > > >> > > We don't have a global vector ABI switch for GCC (ie, `-mabi=lp64dv`) and we >> > > decided not to put on in for GCC-14. We've essentially got all the >> > > machinery there for it, as we've got the vector calling convention >> > > attribute, but that came in pretty late and we decided it'd be better to >> > > wait. >> > > >> > > I don't see any reason it'd miss GCC-15, but no promises as there's not even >> > > a patch on the lists yet... >> > > >> > >> > Understood. Though when this hits, won't it be the most likely target for >> > vector? Meaning at that point, rv64gcbv/lp64d would be less useful or >> > important. >> >> I'm not really sure. If I was building a system I'd want an lp64dv-flavored >> ABI, but if distros are already rv64gc/lp64d then rv64gcv/lp64d would >> provide a binary compatible upgrade path for them. Assuming we end up with >> some sort of glibc-hwcaps the rv64gcv/lp64d builds might be common. >> >> It's kind of all just a guess until HW shows up, though... >> >> > > > If we need to >> > > > have (and test) more targets that are actually useful, so be it. But we >> > > > don't want to be stuck testing targets nobody uses or that provide no >> > > > testing value, and removing them is usually harder than adding them. >> > > >> > > Ya, that's kind of my worry here. We'd be going out on a limb here by >> > > targeting something without hardware availability, we've already got some >> > > baggage floating around from lightly-used targets and it'd be best to avoid >> > > too much of that. >> > > >> > >> > Maybe make an explicit note that if/when the vector ABI is in gcc, the >> > target will be switched to that, rather than another target being added. >> > Then there's some notice for people to not rely on rv64gcbv/lp64d, or at >> > least put up support and/or evidence of a use case to retain the target. >> >> Ya, I guess so far we've not really been explicit about what's supported in >> glibc and what's not -- there's some code in there to ban stuff like lv64f >> and some default ISAs in build-many-glibcs, but I don't know if any of that >> is really binding. >> > > At least build-many-glibcs, and more importantly the release notes, > indicate what is actually tested, which says something. Certainly the list of tested targets per release is a pretty strong sign of what's actually working now, which is great (and thanks for testing basically every release...). >> So maybe we should do a wiki entry with what configurations are actively >> tested and thus likely to work? >> > > Sure, if we think that can be kept up to date. I think I would rather take > an official position on what build-many-glibcs or the release testing means > for supported targets (if there isn't something glibc-wide already), then > we don't have another thing to maintain. Ya, that's best. I guess that's more of a glibc-wide question, though, so we'll have to see if someone else chimes in? >> > > IMO it's really more of a question for users/distros -- and I'm definitely a >> > > crazy person on that front, I run Gentoo