Date: Thu, 21 Nov 2019 06:44:19 +0000 (UTC) From: Warner Losh <imp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r354936 - head/share/man/man7 Message-ID: <201911210644.xAL6iJPW087732@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: imp Date: Thu Nov 21 06:44:19 2019 New Revision: 354936 URL: https://svnweb.freebsd.org/changeset/base/354936 Log: Add table for MACHINE_CPUARCH Add table and also some additional verbage of which one to use. Modified: head/share/man/man7/arch.7 Modified: head/share/man/man7/arch.7 ============================================================================== --- head/share/man/man7/arch.7 Thu Nov 21 04:12:08 2019 (r354935) +++ head/share/man/man7/arch.7 Thu Nov 21 06:44:19 2019 (r354936) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 7, 2019 +.Dd November 20, 2019 .Dt ARCH 7 .Os .Sh NAME @@ -347,6 +347,24 @@ Unless the make variable is defined, make universe will not build mips, powerpc, nor sparc64 architectures unless the xtoolchain binaries have been installed for the architecture. +.Ss MACHINE_ARCH vs MACHINE_CPUARCH +.Dv MACHINE_CPUARCH +should be preferred in Makefiles when the generic +architecture is being tested. +.Dv MACHINE_ARCH +should be preferred when there is something specific to a particular type of +architecture where there is a choice of many, or could be a choice of many. +.Bl -column -offset indent "Dv MACHINE" "Dv MACHINE_CPUARCH" "Dv MACHINE_ARCH" +.It Dv MACHINE Ta Dv MACHINE_CPUARCH Ta Dv MACHINE_ARCH +.It arm64 Ta aarch64 Ta aarch64 +.It amd64 Ta amd64 Ta amd64 +.It arm Ta arm Ta arm, armv6, armv7 +.It i386 Ta i386 Ta i386 +.It mips Ta mips Ta mips, mipsel, mips64, mips64el, mipshf, mipselhf, mips64elhf, mipsn32 +.It powerpc Ta powerpc Ta powerpc, powerpcspe, powerpc64 +.It riscv Ta riscv Ta riscv64, riscv64sf +.It sparc64 Ta sparc64 Ta sparc64 +.El .Ss Predefined Macros The compiler provides a number of predefined macros. Some of these provide architecture-specific details and are explained below. @@ -473,6 +491,8 @@ There is no standard name for the processor: each OS s conventions. .It Dv MACHINE_CPUARCH Represents the source location for a given .Dv MACHINE_ARCH . +It is generally the common prefix for all the MACHINE_ARCH that +share the same implementation, though 'riscv' breaks this rule. For example, .Dv MACHINE_CPUARCH is defined to be mips for all the flavors of mips that we support
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201911210644.xAL6iJPW087732>