Does anyone have any experience with this? Does anybody have some info pointers?
Do you need RTTI for polymorphism?
How is RTTI handled by GCC (3.3.*) ?
C++ kernel programming with RTTI
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:C++ kernel programming with RTTI
http://www.codesourcery.com/cxx-abi/
http://www.informit.com/isapi/guide~cpl ... ontent.asp
Afaik, RTTI isn't required for polymorphism, but only for <dynamic cast> operator ...
http://www.informit.com/isapi/guide~cpl ... ontent.asp
Afaik, RTTI isn't required for polymorphism, but only for <dynamic cast> operator ...
Re:C++ kernel programming with RTTI
No experience on my part. I'd daresay you don't need RTTI - or rather, if you need it, it's probably a sign that your design is screwed up...
As much as I understand your desire to have all bells & whistles enabled up front - hell, I've been there myself a year or so ago - I'd advice you start without RTTI enabled, and see whether this poses to be a problem at all for your kernel.
As much as I understand your desire to have all bells & whistles enabled up front - hell, I've been there myself a year or so ago - I'd advice you start without RTTI enabled, and see whether this poses to be a problem at all for your kernel.
Every good solution is obvious once you've found it.
Re:C++ kernel programming with RTTI
Not just synamic cast, but also catch and throw and and a few others i believe. I also don't think you need RTTI. but to get RTTI working you need a few libraries like libgcc_s and more importantly libstdc++.
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:C++ kernel programming with RTTI
libstdc++ for RTTI and exception handling ?? i wouldn't bet on this ... If you have any evidence things are so, i'd be interrested.
Re:C++ kernel programming with RTTI
He probably meant libsupc++ - libstdc++ is the standard library, i.e. streams, STL and stuff.
I haven't delved into the portability of libsupc++ myself, yet, but if that's of a breed similar to glibc, I'll pass, thank you.
I haven't delved into the portability of libsupc++ myself, yet, but if that's of a breed similar to glibc, I'll pass, thank you.
Every good solution is obvious once you've found it.
Re:C++ kernel programming with RTTI
That doesn't explain the name not being libstl or libstlc++, the absence of every iterator and collection, and the presence of a number of files starting with eh* and files like rtti.cppSolar wrote: He probably meant libsupc++ - libstdc++ is the standard library, i.e. streams, STL and stuff.
can tell, yup, it's as clear as gold (gold has a very high density, and is not clear, if you didn't guess it). Tried to read a part of it, but I happened to print the wrong pages (headers of 20 pages with three lines of interest: inclusion of a different header, 19.9 pages for the old format, one inclusion of a DIFFERENT file for the content with the actual c++ format, and the end-of-file line...I haven't delved into the portability of libsupc++ myself, yet, but if that's of a breed similar to glibc, I'll pass, thank you.
Re:C++ kernel programming with RTTI
Common misconception: The STL is a subset of the C++ standard library. There are parts of the standard library that have nothing to do with the STL.Candy wrote: That doesn't explain the name not being libstl or libstlc++...
I haven't looked at the internals of either lib yet, but you are aware that both iterators and collections would be defined in headers, since they are templates which - pending support for the "export" keyword in gcc - can't split declaration and definition?...the absence of every iterator and collection...
Exception handling is a bloody, compiler-implementation-dependent mess....and the presence of a number of files starting with eh* and files like rtti.cpp
Every good solution is obvious once you've found it.
Re:C++ kernel programming with RTTI
uh... ok... Still don't expect it to be there.Solar wrote: Common misconception: The STL is a subset of the C++ standard library. There are parts of the standard library that have nothing to do with the STL.
There were some big-@$$ files in there (hundreds of K's), must admit I didn't even give them a look. Will look tomorrow.I haven't looked at the internals of either lib yet, but you are aware that both iterators and collections would be defined in headers, since they are templates which - pending support for the "export" keyword in gcc - can't split declaration and definition?...the absence of every iterator and collection...
So true. It was indeed a mess... Did you call 112 yet (or 0900-8844 if it isn't urgent)?Exception handling is a bloody, compiler-implementation-dependent mess.
Translation for those nonconforming USers: 112 is the european 911.