| Anonymous | Login | Signup for a new account | 2013-05-19 09:04 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||||
| 0005583 | OCaml | OCaml runtime system | public | 2012-04-11 15:18 | 2012-05-07 12:05 | ||||||
| Reporter | ygrek | ||||||||||
| Assigned To | doligez | ||||||||||
| Priority | normal | Severity | feature | Reproducibility | have not tried | ||||||
| Status | assigned | Resolution | open | ||||||||
| Platform | OS | OS Version | |||||||||
| Product Version | |||||||||||
| Target Version | Fixed in Version | ||||||||||
| Summary | 0005583: debug info for OCaml runtime | ||||||||||
| Description | Please compile the C code comprising OCaml runtime with debug information, so that looking into internal structures with gdb at run time is easier. E.g. currently : (gdb) p &caml_ref_table $1 = (<data variable, no debug info> *) 0xbed2c0 Also when compiling C bindings ocamlc should do the same. Currently -g is enabled for the debug runtime, but it has runtime cost due to -DDEBUG. | ||||||||||
| Tags | No tags attached. | ||||||||||
| Attached Files | |||||||||||
Notes |
|
|
(0007400) doligez (manager) 2012-05-02 16:53 |
What is the cost of doing this? Does -g preclude some optimizations? How much bigger is the executable? How many people want to look at the runtime with gdb? Don't they already know how to recompile with symbols? |
|
(0007419) ygrek (reporter) 2012-05-07 12:05 |
-g normally shouldn't change the generated code (but see http://stackoverflow.com/a/89619/118799 [^]), it only adds debugging sections, so the executable naturally becomes bigger. Those sections are not loaded at runtime, so the RAM usage is not affected. Debugger maps those sections to memory when needed. Moreover, debug info can be stripped from the binaries and distributed separately (that's a common practice in various distros, witness -dbg packages in debian). Size change after ./configure -cc 'gcc -g' : lib/ocaml/*.a : 3.7M -> 5.9M libasmrun.a : 296K -> 824K libcamlrun.a : 344K -> 968K Probably those who need it can recompile manually. My reason was that it doesn't hurt and can be useful sometimes. |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2012-04-11 15:18 | ygrek | New Issue | |
| 2012-05-02 16:53 | doligez | Note Added: 0007400 | |
| 2012-05-02 16:53 | doligez | Assigned To | => doligez |
| 2012-05-02 16:53 | doligez | Status | new => feedback |
| 2012-05-07 12:05 | ygrek | Note Added: 0007419 | |
| 2012-05-07 12:05 | ygrek | Status | feedback => assigned |
| Copyright © 2000 - 2011 MantisBT Group |