New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
apps/platform, os/binfmt: add exceptions support in loadable #6068
base: master
Are you sure you want to change the base?
Conversation
output result :
|
@@ -193,7 +193,7 @@ int up_relocate(FAR const Elf32_Rel *rel, FAR const Elf32_Sym *sym, uintptr_t ad | |||
} | |||
break; | |||
|
|||
#ifdef CONFIG_ARMV7M_TARGET2_PREL | |||
#if defined(CONFIG_ARMV7M_TARGET2_PREL) || defined(CONFIG_ARMV8M_TARGET2_PREL) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is arch_elf.c module is common for armv7-m & armv8-m?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this file is same for both.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you mean the "same"? This file is in the armv7-m
. Do you mean that armv8-m chip uses armv7-m's file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TizenRT/lib/libc/machine/arm/Make.defs
Lines 62 to 65 in 72bf01c
include ${TOPDIR}/../lib/libc/machine/arm/armv7-m/Make.defs | |
else ifeq ($(CONFIG_ARCH_ARMV8M_FAMILY),y) # Cortex-M33/M55 is ARMv8-M | |
include ${TOPDIR}/../lib/libc/machine/arm/armv7-m/Make.defs | |
else ifeq ($(CONFIG_ARCH_ARMV7A_FAMILY),y) # ARMV7A |
Yes, both use the same file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks strange. No need to move this into the common? Or make a common for m core if r core is different?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to check this
ff26a0a
to
161e65e
Compare
161e65e
to
e3a908d
Compare
e3a908d
to
7905c2b
Compare
7905c2b
to
6e7a3d5
Compare
I will comment here once I finish the testing the loadable_apps config changes, please dont merge the PR till then. |
Add support for cpp exceptions in loadable for RTL8730E and RTL8721CSM. Signed-off-by: Abhishek Akkabathula <a.akkabathul@samsung.com>
6e7a3d5
to
4d138a0
Compare
I have verified it by adding simple exception code in helloxx, diff --git a/apps/examples/helloxx/helloxx_main.cxx b/apps/examples/helloxx/helloxx_main.cxx
index a4d711883..72c1f9fc8 100644
--- a/apps/examples/helloxx/helloxx_main.cxx
+++ b/apps/examples/helloxx/helloxx_main.cxx
@@ -173,6 +173,17 @@ extern "C"
g_HelloWorld.HelloWorld();
#endif
+#if defined(CONFIG_LIBCXX_EXCEPTION)
+ try
+ {
+ throw 5;
+ }
+ catch (int &e)
+ {
+ printf("exception caught : %d\n", e);
+ }
+#endif
+
delete pHelloWorld;
return 0;
} result :
|
@@ -1082,7 +1086,7 @@ CONFIG_PM_DEVNAME_LEN=32 | |||
CONFIG_PM_SLICEMS=100 | |||
CONFIG_PM_NDOMAINS=1 | |||
CONFIG_PM_MEMORY=2 | |||
# CONFIG_PM_DVFS is not set | |||
CONFIG_PM_DVFS=y |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ritesh55555 Is it ok to enable this now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It will only enable an api for now. No other effect on working of the system.
@@ -193,7 +193,7 @@ int up_relocate(FAR const Elf32_Rel *rel, FAR const Elf32_Sym *sym, uintptr_t ad | |||
} | |||
break; | |||
|
|||
#ifdef CONFIG_ARMV7M_TARGET2_PREL | |||
#if defined(CONFIG_ARMV7M_TARGET2_PREL) || defined(CONFIG_ARMV8M_TARGET2_PREL) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to check this
Add support for cpp exceptions in loadable for RTL8730E and RTL8721CSM.