Skip to content

Commit 1ea2897

Browse files
committed
TOOLS : Add missing M33 and M33F in python scripts
1 parent cb49241 commit 1ea2897

File tree

6 files changed

+19
-10
lines changed

6 files changed

+19
-10
lines changed

tools/targets/__init__.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@
4949
"Cortex-M23": ["M23", "CORTEX_M", "LIKE_CORTEX_M23", "CORTEX"],
5050
"Cortex-M23-NS": ["M23", "M23_NS", "CORTEX_M", "LIKE_CORTEX_M23", "CORTEX"],
5151
"Cortex-M33": ["M33", "CORTEX_M", "LIKE_CORTEX_M33", "CORTEX"],
52-
"Cortex-M33-NS": ["M33", "M33_NS", "CORTEX_M", "LIKE_CORTEX_M33", "CORTEX"]
52+
"Cortex-M33-NS": ["M33", "M33_NS", "CORTEX_M", "LIKE_CORTEX_M33", "CORTEX"],
53+
"Cortex-M33F": ["M33", "CORTEX_M", "LIKE_CORTEX_M33", "CORTEX"],
54+
"Cortex-M33F-NS": ["M33", "M33_NS", "CORTEX_M", "LIKE_CORTEX_M33", "CORTEX"]
5355
}
5456

5557
CORE_ARCH = {
@@ -66,7 +68,9 @@
6668
"Cortex-M23": 8,
6769
"Cortex-M23-NS": 8,
6870
"Cortex-M33": 8,
71+
"Cortex-M33F": 8,
6972
"Cortex-M33-NS": 8,
73+
"Cortex-M33F-NS": 8,
7074
}
7175

7276
################################################################################

tools/test/toolchains/arm_support_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
ARMC5_CORES = ["Cortex-M0", "Cortex-M0+", "Cortex-M3", "Cortex-M4",
1818
"Cortex-M4F", "Cortex-M7", "Cortex-M7F", "Cortex-M7FD"]
1919
ARMC6_CORES = ARMC5_CORES + ["Cortex-M23", "Cortex-M23-NS",
20-
"Cortex-M33", "CortexM33-NS"]
20+
"Cortex-M33", "Cortex-M33-NS", "Cortex-M33F", "Cortex-M33F-NS"]
2121

2222
CORE_SUF_ALPHA = ["MDFNS02347-+"]
2323

tools/toolchains/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,8 @@ class mbedToolchain:
7575
"Cortex-M23": ["__CORTEX_M23", "ARM_MATH_ARMV8MBL", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
7676
"Cortex-M33-NS": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "DOMAIN_NS=1", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
7777
"Cortex-M33": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
78-
"Cortex-M33F-NS": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "DOMAIN_NS=1", "__FPU_PRESENT", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
79-
"Cortex-M33F": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "__FPU_PRESENT", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
78+
"Cortex-M33F-NS": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "DOMAIN_NS=1", "__FPU_PRESENT=1U", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
79+
"Cortex-M33F": ["__CORTEX_M33", "ARM_MATH_ARMV8MML", "__FPU_PRESENT=1U", "__CMSIS_RTOS", "__MBED_CMSIS_RTOS_CM"],
8080
}
8181

8282
MBED_CONFIG_FILE_NAME="mbed_config.h"

tools/toolchains/arm.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -363,8 +363,8 @@ class ARMC6(ARM_STD):
363363
SHEBANG = "#! armclang -E --target=arm-arm-none-eabi -x c"
364364
SUPPORTED_CORES = ["Cortex-M0", "Cortex-M0+", "Cortex-M3", "Cortex-M4",
365365
"Cortex-M4F", "Cortex-M7", "Cortex-M7F", "Cortex-M7FD",
366-
"Cortex-M23", "Cortex-M23-NS", "Cortex-M33",
367-
"Cortex-M33-NS", "Cortex-A9"]
366+
"Cortex-M23", "Cortex-M23-NS", "Cortex-M33", "Cortex-M33F",
367+
"Cortex-M33-NS", "Cortex-M33F-NS", "Cortex-A9"]
368368
ARMCC_RANGE = (LooseVersion("6.10"), LooseVersion("7.0"))
369369

370370
@staticmethod
@@ -416,6 +416,9 @@ def __init__(self, target, *args, **kwargs):
416416
self.flags['common'].append("-mfloat-abi=softfp")
417417
elif target.core.startswith("Cortex-M23"):
418418
self.flags['common'].append("-march=armv8-m.base")
419+
elif target.core.startswith("Cortex-M33F"):
420+
self.flags['common'].append("-mfpu=fpv5-sp-d16")
421+
self.flags['common'].append("-mfloat-abi=softfp")
419422

420423
if target.core == "Cortex-M23" or target.core == "Cortex-M33":
421424
self.flags['cxx'].append("-mcmse")

tools/toolchains/gcc.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,10 @@ def __init__(self, target, notify=None, macros=None, build_profile=None,
6262
self.cpu = ["-mcpu=cortex-m23"]
6363
elif target.core.startswith("Cortex-M33F"):
6464
self.cpu = ["-mcpu=cortex-m33"]
65+
self.cpu = ["-mcpu=cortex-m33+nodsp"]
6566
elif target.core.startswith("Cortex-M33"):
66-
self.cpu = ["-march=armv8-m.main"]
67+
self.cpu = ["-mcpu=cortex-m33"]
68+
self.cpu = ["-mcpu=cortex-m33+nodsp+nofp"]
6769
else:
6870
self.cpu = ["-mcpu={}".format(target.core.lower())]
6971

@@ -97,7 +99,7 @@ def __init__(self, target, notify=None, macros=None, build_profile=None,
9799
"-Wl,--cmse-implib",
98100
"-Wl,--out-implib=%s" % join(build_dir, "cmse_lib.o")
99101
])
100-
elif target.core == "Cortex-M23-NS" or target.core == "Cortex-M33-NS":
102+
elif target.core == "Cortex-M23-NS" or target.core == "Cortex-M33-NS" or target.core == "Cortex-M33F-NS":
101103
self.flags["ld"].append("-DDOMAIN_NS=1")
102104

103105
self.flags["common"] += self.cpu

tools/toolchains/iar.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,12 @@ def __init__(self, target, notify=None, macros=None, build_profile=None,
7474
elif target.core == "Cortex-M7F":
7575
asm_flags_cmd += ["--fpu", "VFPv5_sp"]
7676
c_flags_cmd.append("--fpu=VFPv5_sp")
77-
elif target.core == "Cortex-M23" or target.core == "Cortex-M33":
77+
elif target.core == "Cortex-M23" or target.core == "Cortex-M33" or target.core == "Cortex-M33F":
7878
self.flags["asm"] += ["--cmse"]
7979
self.flags["common"] += ["--cmse"]
8080

8181
# Create Secure library
82-
if target.core == "Cortex-M23" or self.target.core == "Cortex-M33":
82+
if target.core == "Cortex-M23" or self.target.core == "Cortex-M33" or self.target.core == "Cortex-M33F":
8383
secure_file = join(build_dir, "cmse_lib.o")
8484
self.flags["ld"] += ["--import_cmse_lib_out=%s" % secure_file]
8585

0 commit comments

Comments
 (0)