Всем привет.
Подскажите какие программы вы используете для анализа организации памяти в бинарных/объектных файлах. Я говорю главным образом об отладочных инструментах, доступных в UNIX/Linux (таких как gdb, strace, ltrace, nm и objdump).
К примеру, какие переменные лежат в read-only data-сегменте, какие в bss и т.д.
Благодарю за конкретные примеры
Программы для анализа бинарных файлов (организация памяти)
Модератор: Модераторы разделов
- Stauffenberg
- Сообщения: 2042
- Статус: ☮ PEACE ☮
- ОС: открытая и свободная
Программы для анализа бинарных файлов
Labor omnia vincit
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” (Brian Kernighan)
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” (Brian Kernighan)
- Stauffenberg
- Сообщения: 2042
- Статус: ☮ PEACE ☮
- ОС: открытая и свободная
Re: Программы для анализа бинарных файлов
Ок, начну пожалуй.
Практически все необходимое можно найти в /proc/pid/name_of_process. Файлы smaps, memp и stack пожалуй самые интересные в этом каталоге. Именно их, помимо системного вызова ptrace, и используют отладочные инструменты.
Практически все необходимое можно найти в /proc/pid/name_of_process. Файлы smaps, memp и stack пожалуй самые интересные в этом каталоге. Именно их, помимо системного вызова ptrace, и используют отладочные инструменты.
Labor omnia vincit
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” (Brian Kernighan)
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” (Brian Kernighan)