diff options
author | Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> | 2016-10-04 12:31:21 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-10-07 16:43:57 +0100 |
commit | 8be92dcd5979a9cae55342b7493b36497de97fea (patch) | |
tree | 9718fd5c7fdcaa8d1fe163b1cda560e7cd45b468 | |
parent | 559f52fe9cce0614d1523e735860f055cbb99b4d (diff) | |
download | poky-8be92dcd5979a9cae55342b7493b36497de97fea.tar.gz |
arch-mips: Add mipsisa{32, 64}r6{el, } tunes
Add support for MIPS Release 6 ISA and the various tune
configurations.
This patch adds the tunes for 32r6 and 64r6 n64 and not the n32
variants at the moment.
Release 6 onwards, the tuples are now
- mipsisa32r6-linux-gnu
- mipsisa32r6el-linux-gnu
- mipsisa64r6-linux-gnuabi64
- mipsisa64r6el-linux-gnuabi64
- mipsisa64r6-linux-gnuabin32
- mipsisa64r6el-linux-gnuabin32
For more details, check https://wiki.debian.org/Multiarch/Tuples
(From OE-Core rev: 6b2e0c60c3222a13b33284f258d5c340222d759f)
Signed-off-by: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/conf/machine/include/mips/README | 19 | ||||
-rw-r--r-- | meta/conf/machine/include/mips/arch-mips.inc | 10 | ||||
-rw-r--r-- | meta/conf/machine/include/tune-mips32r6.inc | 29 | ||||
-rw-r--r-- | meta/conf/machine/include/tune-mips64r6.inc | 32 |
4 files changed, 88 insertions, 2 deletions
diff --git a/meta/conf/machine/include/mips/README b/meta/conf/machine/include/mips/README index c375f316df..62fa1561ba 100644 --- a/meta/conf/machine/include/mips/README +++ b/meta/conf/machine/include/mips/README | |||
@@ -1,3 +1,6 @@ | |||
1 | 2016/09/30 - Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com> | ||
2 | - Add Release 6 support | ||
3 | |||
1 | 2012/03/30 - Mark Hatle <mark.hatle@windriver.com> | 4 | 2012/03/30 - Mark Hatle <mark.hatle@windriver.com> |
2 | - Initial Version | 5 | - Initial Version |
3 | 6 | ||
@@ -6,9 +9,14 @@ MIPS currently defines 12 ABIs. Combinations of: | |||
6 | *) Hardware/Software Floating Point | 9 | *) Hardware/Software Floating Point |
7 | *) o32, n32, n64 ABI | 10 | *) o32, n32, n64 ABI |
8 | 11 | ||
12 | Release 6 of the ISA is a major revision and doesn't build up on previous | ||
13 | releases of the ISA. | ||
14 | |||
15 | For more details about tuples, check https://wiki.debian.org/Multiarch/Tuples | ||
16 | |||
9 | TUNE_ARCH, the GNU canonical arch, is defined as: | 17 | TUNE_ARCH, the GNU canonical arch, is defined as: |
10 | 18 | ||
11 | mips${MIPSPKGSFX_BYTE}${MIPSPKGSFX_ENDIAN} | 19 | "mips${MIPSPKGSFX_32R6}${MIPSPKGSFX_64R6}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}" |
12 | 20 | ||
13 | The package arch is defined in such a way to generated a standard naming | 21 | The package arch is defined in such a way to generated a standard naming |
14 | scheme. The scheme is: <mips variant>[-nf][-n32] | 22 | scheme. The scheme is: <mips variant>[-nf][-n32] |
@@ -34,3 +42,12 @@ that the tune is using a non-floating point ABI. | |||
34 | MIPSPKGSFX_ABI - This is used to specify an alternative ABI when the previous | 42 | MIPSPKGSFX_ABI - This is used to specify an alternative ABI when the previous |
35 | values are not enough to distringuish the package. "-n32" is added when | 43 | values are not enough to distringuish the package. "-n32" is added when |
36 | building for N32 ABI. | 44 | building for N32 ABI. |
45 | |||
46 | MIPSPKGSFX_R6 - This is used to specify the presence of release 6. | ||
47 | "r6" is added in the tuple for release 6 of the isa. | ||
48 | |||
49 | MIPSPKGSFX_64R6 - This is used to specify "isa" in the tuple. | ||
50 | Release 6 onwards we use "mipsisa64" instead of just "mips64". | ||
51 | |||
52 | MIPSPKGSFX_32R6 - This is used to specify "isa32" in the tuple. | ||
53 | Release 6 onwards we use "mipsisa32" instead of just "mips". | ||
diff --git a/meta/conf/machine/include/mips/arch-mips.inc b/meta/conf/machine/include/mips/arch-mips.inc index 28d3b51b05..50c4c82683 100644 --- a/meta/conf/machine/include/mips/arch-mips.inc +++ b/meta/conf/machine/include/mips/arch-mips.inc | |||
@@ -32,14 +32,22 @@ TUNEVALID[fpu-hard] = "Use hardware FPU" | |||
32 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard', ' -mhard-float', ' -msoft-float', d)}" | 32 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard', ' -mhard-float', ' -msoft-float', d)}" |
33 | TARGET_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard', '', 'soft', d)}" | 33 | TARGET_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard', '', 'soft', d)}" |
34 | 34 | ||
35 | # MIPS r6 ABI | ||
36 | TUNEVALID[r6] = "Use r6" | ||
37 | TUNEVALID[mipsisa64r6] = "Use 64r6" | ||
38 | TUNEVALID[mipsisa32r6] = "Use 32r6" | ||
39 | |||
35 | # Package naming | 40 | # Package naming |
36 | MIPSPKGSFX_ENDIAN = "${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el', d)}" | 41 | MIPSPKGSFX_ENDIAN = "${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el', d)}" |
37 | MIPSPKGSFX_BYTE = "${@bb.utils.contains('TUNE_FEATURES', 'n64' , '64', '', d)}" | 42 | MIPSPKGSFX_BYTE = "${@bb.utils.contains('TUNE_FEATURES', 'n64' , '64', '', d)}" |
38 | MIPSPKGSFX_BYTE .= "${@bb.utils.contains('TUNE_FEATURES', 'n32' , '64', '', d)}" | 43 | MIPSPKGSFX_BYTE .= "${@bb.utils.contains('TUNE_FEATURES', 'n32' , '64', '', d)}" |
39 | MIPSPKGSFX_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard' , '', '-nf', d)}" | 44 | MIPSPKGSFX_FPU = "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard' , '', '-nf', d)}" |
40 | MIPSPKGSFX_ABI = "${@bb.utils.contains('TUNE_FEATURES', 'n32', '-n32', '', d)}" | 45 | MIPSPKGSFX_ABI = "${@bb.utils.contains('TUNE_FEATURES', 'n32', '-n32', '', d)}" |
46 | MIPSPKGSFX_R6 = "${@bb.utils.contains('TUNE_FEATURES', 'r6', 'r6', '', d)}" | ||
47 | MIPSPKGSFX_64R6 = "${@bb.utils.contains('TUNE_FEATURES', 'mipsisa64r6', 'isa', '', d)}" | ||
48 | MIPSPKGSFX_32R6 = "${@bb.utils.contains('TUNE_FEATURES', 'mipsisa32r6', 'isa32', '', d)}" | ||
41 | 49 | ||
42 | TUNE_ARCH = "mips${MIPSPKGSFX_BYTE}${MIPSPKGSFX_ENDIAN}" | 50 | TUNE_ARCH = "mips${MIPSPKGSFX_32R6}${MIPSPKGSFX_64R6}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}" |
43 | TUNE_PKGARCH = "${MIPSPKGSFX_VARIANT_tune-${DEFAULTTUNE}}${MIPSPKGSFX_FPU}${MIPSPKGSFX_ABI}" | 51 | TUNE_PKGARCH = "${MIPSPKGSFX_VARIANT_tune-${DEFAULTTUNE}}${MIPSPKGSFX_FPU}${MIPSPKGSFX_ABI}" |
44 | 52 | ||
45 | # Base tunes | 53 | # Base tunes |
diff --git a/meta/conf/machine/include/tune-mips32r6.inc b/meta/conf/machine/include/tune-mips32r6.inc new file mode 100644 index 0000000000..47213198c4 --- /dev/null +++ b/meta/conf/machine/include/tune-mips32r6.inc | |||
@@ -0,0 +1,29 @@ | |||
1 | DEFAULTTUNE ?= "mipsisa32r6el" | ||
2 | |||
3 | require conf/machine/include/mips/arch-mips.inc | ||
4 | |||
5 | TUNEVALID[mipsisa32r6] = "Enable mipsisa32r6 specific processor optimizations" | ||
6 | TUNECONFLICTS[mipsisa32r6] = "n64 n32" | ||
7 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'mipsisa32r6', ' -march=mips32r6', '', d)}" | ||
8 | |||
9 | # Base Tunes | ||
10 | AVAILTUNES += "mipsisa32r6 mipsisa32r6el" | ||
11 | |||
12 | TUNE_FEATURES_tune-mipsisa32r6 = "bigendian mipsisa32r6 fpu-hard r6" | ||
13 | MIPSPKGSFX_VARIANT_tune-mipsisa32r6 = "${TUNE_ARCH}" | ||
14 | PACKAGE_EXTRA_ARCHS_tune-mipsisa32r6 = "mipsisa32r6" | ||
15 | |||
16 | TUNE_FEATURES_tune-mipsisa32r6el = "fpu-hard mipsisa32r6 r6" | ||
17 | MIPSPKGSFX_VARIANT_tune-mipsisa32r6el = "${TUNE_ARCH}" | ||
18 | PACKAGE_EXTRA_ARCHS_tune-mipsisa32r6el = "mipsisa32r6el" | ||
19 | |||
20 | # Soft Float | ||
21 | AVAILTUNES += "mipsisa32r6-nf mipsisa32r6el-nf" | ||
22 | |||
23 | TUNE_FEATURES_tune-mipsisa32r6-nf = "bigendian mipsisa32r6 r6" | ||
24 | MIPSPKGSFX_VARIANT_tune-mipsisa32r6-nf = "${TUNE_ARCH}" | ||
25 | PACKAGE_EXTRA_ARCHS_tune-mipsisa32r6-nf = "mipsisa32r6-nf" | ||
26 | |||
27 | TUNE_FEATURES_tune-mipsisa32r6el-nf = "mipsisa32r6 r6" | ||
28 | MIPSPKGSFX_VARIANT_tune-mipsisa32r6el-nf = "${TUNE_ARCH}" | ||
29 | PACKAGE_EXTRA_ARCHS_tune-mipsisa32r6el-nf = "mipsisa32r6el-nf" | ||
diff --git a/meta/conf/machine/include/tune-mips64r6.inc b/meta/conf/machine/include/tune-mips64r6.inc new file mode 100644 index 0000000000..f0ad564686 --- /dev/null +++ b/meta/conf/machine/include/tune-mips64r6.inc | |||
@@ -0,0 +1,32 @@ | |||
1 | DEFAULTTUNE ?= "mipsisa64r6el" | ||
2 | |||
3 | require conf/machine/include/mips/arch-mips.inc | ||
4 | |||
5 | TUNEVALID[mipsisa64r6] = "Enable mipsisa64r6 specific processor optimizations" | ||
6 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'mipsisa64r6', ' -march=mips64r6', '', d)}" | ||
7 | |||
8 | # Base Tunes | ||
9 | AVAILTUNES += "mipsisa64r6 mipsisa64r6el" | ||
10 | |||
11 | TUNE_FEATURES_tune-mipsisa64r6 = "bigendian fpu-hard n64 mipsisa64r6 r6" | ||
12 | MIPSPKGSFX_VARIANT_tune-mipsisa64r6 = "${TUNE_ARCH}" | ||
13 | BASE_LIB_tune-mipsisa64r6 = "lib64" | ||
14 | PACKAGE_EXTRA_ARCHS_tune-mipsisa64r6 = "mipsisa64r6" | ||
15 | |||
16 | TUNE_FEATURES_tune-mipsisa64r6el = "fpu-hard r6 n64 mipsisa64r6" | ||
17 | MIPSPKGSFX_VARIANT_tune-mipsisa64r6el = "${TUNE_ARCH}" | ||
18 | BASE_LIB_tune-mipsisa64r6el = "lib64" | ||
19 | PACKAGE_EXTRA_ARCHS_tune-mipsisa64r6el = "mipsisa64r6el" | ||
20 | |||
21 | # Soft Float | ||
22 | AVAILTUNES += "mipsisa64r6-nf mipsisa64r6el-nf" | ||
23 | |||
24 | TUNE_FEATURES_tune-mipsisa64r6-nf = "bigendian r6 n64 mipsisa64r6" | ||
25 | MIPSPKGSFX_VARIANT_tune-mipsisa64r6-nf = "${TUNE_ARCH}" | ||
26 | BASE_LIB_tune-mipsisa64r6-nf = "lib64" | ||
27 | PACKAGE_EXTRA_ARCHS_tune-mipsisa64r6-nf = "mipsisa64r6" | ||
28 | |||
29 | TUNE_FEATURES_tune-mipsisa64r6el-nf = "r6 n64 mipsisa64r6" | ||
30 | MIPSPKGSFX_VARIANT_tune-mipsisa64r6el-nf = "${TUNE_ARCH}" | ||
31 | BASE_LIB_tune-mipsisa64r6el-nf = "lib64" | ||
32 | PACKAGE_EXTRA_ARCHS_tune-mipsisa64r6el-nf = "mipsisa64r6el-nf" | ||