Documentation for XML_TI_MAP.pm |
XML_TI_MAP.pm
Perl module for converting XML files generated by TI linkers into Perl data structures
use XML_TI_MAP; # no names imported
OR ...
use XML_TI_MAP qw(process_xml_file # import names
%symtab %rev_symtab
$output_sections $input_sections $files);
TI linkers can create a map file in XML format with the option --xml_link_info=<filename>. Use this module to turn that XML data into far more useful Perl data structures.
This module should be delivered with at least one example usage file "dump_map.pl". Start by using and exploring that script. All it does is read in the XML file and dump out the resulting Perl data structures. Understanding those data structures is key to implementing any further object file post-processing routines.
Input : One argument; name of the XML file
Returns : Data structure representing the XML
If the command line option --cg_xml_version is present, print out, on stderr, the version of the cg_xml package in use. Must be called BEFORE the main script does any command line processing.
Whether to dump the Perl data structures to stdout
Since $debug is such a common variable name, it is not exported from this package. Thus any access must be fully qualified as written above. All other functions and variable names can be written without the XML_TI_MAP qualifier if they are imported in the use statement.
Documentation for XML_TI_MAP.pm |