From owner-freebsd-arm@freebsd.org Wed Mar 31 21:12:07 2021 Return-Path: Delivered-To: freebsd-arm@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3D3C45B109A for ; Wed, 31 Mar 2021 21:12:07 +0000 (UTC) (envelope-from fuz@fuz.su) Received: from fuz.su (fuz.su [IPv6:2001:41d0:8:e508::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "amnesiac", Issuer "amnesiac" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4F9fCB2ZlLz4fZS for ; Wed, 31 Mar 2021 21:12:06 +0000 (UTC) (envelope-from fuz@fuz.su) Received: from fuz.su (localhost [127.0.0.1]) by fuz.su (8.16.1/8.16.1) with ESMTPS id 12VLC47K060920 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO) for ; Wed, 31 Mar 2021 23:12:04 +0200 (CEST) (envelope-from fuz@fuz.su) Received: (from fuz@localhost) by fuz.su (8.16.1/8.16.1/Submit) id 12VLC4gP060919 for freebsd-arm@freebsd.org; Wed, 31 Mar 2021 23:12:04 +0200 (CEST) (envelope-from fuz) Date: Wed, 31 Mar 2021 23:12:04 +0200 From: Robert Clausecker To: freebsd-arm@freebsd.org Subject: Re: 32-bit executables on aarch64? Message-ID: References: <202103311655.12VGtx3T036893@office.dignus.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Rspamd-Queue-Id: 4F9fCB2ZlLz4fZS X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of fuz@fuz.su designates 2001:41d0:8:e508::1 as permitted sender) smtp.mailfrom=fuz@fuz.su X-Spamd-Result: default: False [-0.30 / 15.00]; SUBJECT_ENDS_QUESTION(1.00)[]; ARC_NA(0.00)[]; NEURAL_SPAM_SHORT(1.00)[1.000]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; RBL_DBL_DONT_QUERY_IPS(0.00)[2001:41d0:8:e508::1:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arm@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; SPAMHAUS_ZRD(0.00)[2001:41d0:8:e508::1:from:127.0.2.255]; DMARC_NA(0.00)[fuz.su]; R_SPF_ALLOW(-0.20)[+a]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_TWO(0.00)[2]; ASN(0.00)[asn:16276, ipnet:2001:41d0::/32, country:FR]; MAILMAN_DEST(0.00)[freebsd-arm] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Porting FreeBSD to ARM processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Mar 2021 21:12:07 -0000 Hi Mark, This is news to me. Excellent news! I can't say how grateful I am for having this pointed out by you. Can now go ahead and throw out my dedicated armv7 test machine which has caused me a lot of head aches with world builds and all that. Yours, Robert Clausecker Am Wed, Mar 31, 2021 at 11:05:45AM -0700 schrieb Mark Millard: > > On 2021-Mar-31, at 10:46, Robert Clausecker wrote: > > > Hi Thomas, > > > > Unfortunately, there is no support for running armv7 executables > > on arm64, though it would technically be possible to implement. > > I myself would really like to have this sort of thing but I lack > > the knowledge to have it. Perhaps someone feels adventurous > > enough to look into implementing support for this sort of thing. > > aarch64 FreeBSD supports having an armv7 world installed > in a directory tree for use with chroot. > > I've a separate reply to the original submittal showing > a use of such. > > aarch64 FreeBSD lacks lib32 for more direct execution > of armv7 FreeBSD code without involving a chroot use (or > qemu use or other such). > > > For historical reasons, the i386 and amd64 ports of gcc and clang > > have a largely shared code base and are essentially the same port. > > So options -m32, -m64 can be used to switch between them. The same > > is not possible for armv7 and arm64 which are distinct ports with > > little to no shared backend code. Consider using -target armv7 > > instead. > > > > Yours, > > Robert Clausecker > > > > Am Wed, Mar 31, 2021 at 12:55:59PM -0400 schrieb Thomas David Rivers: > >> > >> I'm playing around with a (rather-old now) 13.0-pre-pre-pre release > >> on Raspberry PI 4B. > >> > >> I was naively thinking I could just use -m32 to create a 32-bit > >> executable... but the LLVM there promptly told me it didn't recognize > >> -m32. > >> > >> I installed the gcc V9 port and it said the same thing. > >> > >> This begged the question, is there no support of 32-bit ARM (armv7) > >> executables in the aarch64 environment? > > > > === > Mark Millard > marklmi at yahoo.com > ( dsl-only.net went > away in early 2018-Mar) > -- () ascii ribbon campaign - for an 8-bit clean world /\ - against html email - against proprietary attachments