GPROFNG-DISPLAY-SRC(1)
π GPROFNG-DISPLAY-SRC π
okay bestie, pull up a chair, we're looking at gprofng-display-src from the User Commands manual β it's the part of gprofng that shows you the source code of your target, and (if you want) the disassembly too. no cap. π«Ά
β¨ NAME β¨
gprofng-display-src β display source code and optionally disassembly of the target object πΈ
β¨ SYNOPSIS β¨
gprofng display src [option(s)] target-file
π DESCRIPTION π
So basically: this shows you a source code listing, OR source code interleaved with disassembly code, as extracted from the target file (which can be an executable, a shared object, an object file, or a Java .class file). it's giving "let me read your code's diary" energy. π
like, say you wanna see the source code AND the disassembly listing for a function called mxv_core that lives inside the object file mxv.o β you'd do:
$ gprofng display src -disasm mxv_core mxv.o
and if you're feeling greedy and want the source + disassembly for all the functions in that file:
$ gprofng display src -disasm all -1 mxv.o
the target-file is the name of an executable, a shared object, an object file (.o), or a Java .class file. π
and listen β if you give no options at all, you just get the source code listing of the target-file. that is literally the same thing as -source all -1. but if that info isn't available? the program prints a message to that extent. it's telling on you. π
β¨ OPTIONS β¨
--versionβ print the version number and dip. out. π¦--helpβ print usage information and exit. your little guide bestie. π-functionsβ list out all the functions from the given object. the full roster, no skips.-sourceitem tag β show the source code for item in target-file. the tag is there to differentiate in case there are multiple occurences with the same name. (see the NOTES section for what item and tag even mean.) π-disasmitem tag β include the disassembly in the source listing. the default listing does not include disassembly, fyi. and if the source code isn't available, it'll show a listing of the disassembly only. (again, NOTES section for item and tag definitions.) π₯-outfilefilename β write results to file filename. a dash (-) writes to stdout, which is also the default. π«§
β οΈ bestie, careful with this one: -outfile only affects those options included to the right of the option. order matters, periodt. π
π NOTES π
use item to specify the name of a function β or of a source or object file that was used to build the executable or shared object. π
the tag is an index used to figure out which item is being referred to when multiple functions share the same name. it is required, but it'll be ignored if it isn't necessary to resolve the function. so it's required but also sometimes not. iconic, honestly. π
the item may also be specified in the form function`file` β in which case, the source or disassembly of the named function, in the source context of the named file, gets used. π§
and the special item + tag combo all -1 means "generate the source or disassembly for all functions in the target-file." that's the whole-gang pass. π
π SEE ALSO π
gprofng(1)gprofng-archive(1)gprofng-collect-app(1)gprofng-display-html(1)gprofng-display-text(1)
the user guide for gprofng is maintained as a Texinfo manual. if the info and gprofng programs are correctly installed, the command info gprofng should give you access to this document. slay. π
π COPYRIGHT π
Copyright (c) 2022-2026 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".
and that's the whole page, bestie β this gorgeous thing ships with binutils-2.47, dated 2026-09-10. go read some source code, you main character. β¨ππ
π¦ where this page comes from
- ubuntu stonking: binutils 2.47-6ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms