-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Delete the start hook implementation and use crt0 instead. The module will initialize itself in crt0. #16154
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
Conversation
a0f45a9
to
02c9208
Compare
02c9208
to
965985f
Compare
[Experimental Bot, please feedback here] No, this PR does not fully meet the NuttX requirements. Here's why:
To make this PR compliant, address the following:
|
Should https://github.com/apache/nuttx/blob/master/libs/libc/misc/lib_cxx_initialize.c be removed by this change as well ? |
70b1faa
to
0ccd559
Compare
@anjiahao1 Please fix the conflict. Thanks :-) |
0ccd559
to
69a2f4b
Compare
ok,remove it |
69a2f4b
to
97fe263
Compare
@nuttxpr test avaota-a1:nsh |
[Experimental Bot, please feedback here] Build and Test Successful (avaota-a1:nsh)
|
@nuttxpr test milkv_duos:nsh |
[Experimental Bot, please feedback here] Build and Test Successful (milkv_duos:nsh)
|
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.
Retested OK with OSTest on Avaota-A1 A527 Arm64 SBC and Oz64 SG2000 64-bit RISC-V SBC
test: 1.use mps3-an547 build helloxx as module and run it 2.use qemu-armv7a:knsh test kernel build helloxx and run it Signed-off-by: anjiahao <[email protected]>
Signed-off-by: anjiahao <[email protected]>
aarch64-none-elf-gcc: error: unrecognized command-line option '-mlong-calls' Signed-off-by: anjiahao <[email protected]>
97fe263
to
901acf5
Compare
we use crt0 inside of start hook in pr apache#16154, so xtensa also need add it. Signed-off-by: anjiahao <[email protected]>
we use crt0 inside of start hook in pr #16154, so xtensa also need add it. Signed-off-by: anjiahao <[email protected]>
Summary
Delete the start hook implementation and use crt0 instead. The module will initialize itself in crt0.
and with delete start hook, we can unfiy
tcb_s
task_tcb_s
pthread_tcb
the modification is required to support c++ constructor for protected and kernel mode since start_hook can't call directly inside kernel space.
Impact
module build
Testing
mps3an547 module test with cxx
qemu armv7 module test with cxx