Subject:
|
Re: Global Objects was Strange RCX startup issues
|
Newsgroups:
|
lugnet.robotics.rcx.legos
|
Date:
|
Tue, 9 Dec 2003 22:53:51 GMT
|
Viewed:
|
5033 times
|
| |
 | |
Doh! I think I just answered the question (of course it was After
hitting send)
Joseph Woolley wrote:
[snip]
> Also, I have a question (because of my limited knowledge of how the
> __ctors and __dtors are managed): Would the two *for* loops in your
> sample code call the ctors and dtors for all global objects, regardless
> of which program they belong (assuming Task Management and Program
> Management is built)? Would it be correct to validate that the function
> pointer is pointing to a function within the current program code before
> calling it?
So __ctors and __dtors are local to the program (address fix-up done by
genlds, etc...) ? This way the __ctors are only for the current program.
To add automatic handling of the global objects (for the kernel built
with TM and PROGRAM) would require that dll send the address of __ctors,
__ctors_end, __dtors and __dtors_end to the Program Manager.
This seems possible, but not likely in the very near future. Maybe I
can dig into it before January.
Mark, thanks for posting this code!
// Joe
|
|
Message has 1 Reply:
Message is in Reply To:
 | | Global Objects was Strange RCX startup issues
|
| Mark, This is an interesting issue. Initially, after reading your post, I was thinking that it would be easy to add this support to BrickOS. Of course, this is only partially correct. For NON Task Manager builds (therefore no Program manager), it is (...) (21 years ago, 9-Dec-03, to lugnet.robotics.rcx.legos)
|
12 Messages in This Thread:               
     
       
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|