Martin Zenzes
2014-07-15 15:40:12 UTC
Hi,
playing around a little bit, reading into this nice codebase of
LLVM/clang and talking to Matthias. Concerned with this horrible state
of gccxml -- no offense -- but it does not make sense to force it to
cross-compile if it is going to be replaced sooner than later. So:
What does a replacement for gccxml in typelib have to provide:
- the full qualifying names of all types defined in a given set of
header-files
- their memory layout: offset+type of all members, the sizeof the type
itself
right?
Nice would be:
- bail out if types use too fancy features, like virtual functions or
dynamic members (except some whitelisted special cases)
The proof-of-concept-level stuff I have so far is living in
$WIESE/temp/mzenzes/clang-typelib.bare but it would make more sense to
push it out into the internet -- should i use my private github account
for things like this?
--
The second point can be done using "clang -fdump-record-layouts" (see
http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-July/037778.html. It
results in an output like this:
0 | struct base::JointState
0 | double position
8 | float speed
12 | float effort
16 | float raw
| [sizeof=24, dsize=20, align=8
| nvsize=20, nvalign=8]
for the first point (and third) "clang-check -ast-list" could be used --
but it prints too much. So a small clang-tool with added filtering might
come in handy?
Greetings
Martin
--
M.Sc. Martin Zenzes
Space Robotics
Hauptgesch?ftsstelle Standort Bremen:
DFKI GmbH
Robotics Innovation Center
Robert-Hooke-Stra?e 5
28359 Bremen, Germany
Phone: +49 (0) 421 178 45 - 6658
Fax: +49 (0) 421 178 45 - 4150
E-Mail: martin.zenzes at dfki.de
Weitere Informationen: http://www.dfki.de/robotik
-----------------------------------------------------------------------
Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH
Firmensitz: Trippstadter Stra?e 122, D-67663 Kaiserslautern
Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
(Vorsitzender) Dr. Walter Olthoff
Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
Amtsgericht Kaiserslautern, HRB 2313
Sitz der Gesellschaft: Kaiserslautern (HRB 2313)
USt-Id.Nr.: DE 148646973
Steuernummer: 19/673/0060/3
-----------------------------------------------------------------------
playing around a little bit, reading into this nice codebase of
LLVM/clang and talking to Matthias. Concerned with this horrible state
of gccxml -- no offense -- but it does not make sense to force it to
cross-compile if it is going to be replaced sooner than later. So:
What does a replacement for gccxml in typelib have to provide:
- the full qualifying names of all types defined in a given set of
header-files
- their memory layout: offset+type of all members, the sizeof the type
itself
right?
Nice would be:
- bail out if types use too fancy features, like virtual functions or
dynamic members (except some whitelisted special cases)
The proof-of-concept-level stuff I have so far is living in
$WIESE/temp/mzenzes/clang-typelib.bare but it would make more sense to
push it out into the internet -- should i use my private github account
for things like this?
--
The second point can be done using "clang -fdump-record-layouts" (see
http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-July/037778.html. It
results in an output like this:
0 | struct base::JointState
0 | double position
8 | float speed
12 | float effort
16 | float raw
| [sizeof=24, dsize=20, align=8
| nvsize=20, nvalign=8]
for the first point (and third) "clang-check -ast-list" could be used --
but it prints too much. So a small clang-tool with added filtering might
come in handy?
Greetings
Martin
--
M.Sc. Martin Zenzes
Space Robotics
Hauptgesch?ftsstelle Standort Bremen:
DFKI GmbH
Robotics Innovation Center
Robert-Hooke-Stra?e 5
28359 Bremen, Germany
Phone: +49 (0) 421 178 45 - 6658
Fax: +49 (0) 421 178 45 - 4150
E-Mail: martin.zenzes at dfki.de
Weitere Informationen: http://www.dfki.de/robotik
-----------------------------------------------------------------------
Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH
Firmensitz: Trippstadter Stra?e 122, D-67663 Kaiserslautern
Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
(Vorsitzender) Dr. Walter Olthoff
Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
Amtsgericht Kaiserslautern, HRB 2313
Sitz der Gesellschaft: Kaiserslautern (HRB 2313)
USt-Id.Nr.: DE 148646973
Steuernummer: 19/673/0060/3
-----------------------------------------------------------------------