<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: excessively large executables in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195848#M714115</link>
    <description>I'm willing to bet that these are statically linked executables. That can be good from the standpoint that the developer knows that they will run on any system but it does produce large, memory-wasteful executables.&lt;BR /&gt;&lt;BR /&gt;Do a chatr filename. If you see no shared libraries listed then you are statically linked. Ldd can also be used. It will either report the shared libraries utilized or it will report ' "myfile" is not a shared executable' -- indicating that "myfile" is statically linked.&lt;BR /&gt;&lt;BR /&gt;Man chatr, ldd for details.&lt;BR /&gt;</description>
    <pubDate>Wed, 18 Feb 2004 14:37:40 GMT</pubDate>
    <dc:creator>A. Clay Stephenson</dc:creator>
    <dc:date>2004-02-18T14:37:40Z</dc:date>
    <item>
      <title>excessively large executables</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195847#M714114</link>
      <description>Hello,&lt;BR /&gt;&lt;BR /&gt;I have a machine that has executables created by developers that are very large (&amp;gt;50meg and some libs &amp;gt;200 meg). I suspect that they are linking in some large libraries that may not be needed. Any tools available to investigate what is contained in a c++ exec, and whether libs linked in are in fact used?&lt;BR /&gt;&lt;BR /&gt;Thanks...</description>
      <pubDate>Wed, 18 Feb 2004 14:30:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195847#M714114</guid>
      <dc:creator>Michael Murphy_2</dc:creator>
      <dc:date>2004-02-18T14:30:56Z</dc:date>
    </item>
    <item>
      <title>Re: excessively large executables</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195848#M714115</link>
      <description>I'm willing to bet that these are statically linked executables. That can be good from the standpoint that the developer knows that they will run on any system but it does produce large, memory-wasteful executables.&lt;BR /&gt;&lt;BR /&gt;Do a chatr filename. If you see no shared libraries listed then you are statically linked. Ldd can also be used. It will either report the shared libraries utilized or it will report ' "myfile" is not a shared executable' -- indicating that "myfile" is statically linked.&lt;BR /&gt;&lt;BR /&gt;Man chatr, ldd for details.&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Feb 2004 14:37:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195848#M714115</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2004-02-18T14:37:40Z</dc:date>
    </item>
    <item>
      <title>Re: excessively large executables</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195849#M714116</link>
      <description>Use "ldd" or "chatr" to see what shared&lt;BR /&gt;libraries are in an executable.  If the&lt;BR /&gt;library was an archive library, I don't&lt;BR /&gt;know of a tool that can get the library&lt;BR /&gt;name.  But you can use "nm" to snoop around&lt;BR /&gt;to see what objects are in the executable.&lt;BR /&gt;&lt;BR /&gt;However, I don't think the linker will link&lt;BR /&gt;in library code that's not used (either&lt;BR /&gt;archive or shared).  One thing that can&lt;BR /&gt;bloat executables is having a lot of&lt;BR /&gt;initialized arrays:&lt;BR /&gt;&lt;BR /&gt;double a[100000] = {0, 1, ...};&lt;BR /&gt;&lt;BR /&gt;The compiler will make space in the&lt;BR /&gt;executable for the entire array.&lt;BR /&gt;Unitialized arrays (the same as above,&lt;BR /&gt;minus the = {0, 1, ...} part) are set up&lt;BR /&gt;at run time.&lt;BR /&gt;&lt;BR /&gt;Use the "size -v" commmand to see how&lt;BR /&gt;much space is being used in an executable&lt;BR /&gt;for each type of data.  In the "size -v"&lt;BR /&gt;output, $CODE is the program's executable&lt;BR /&gt;code, $BSS contains the unitialized arrays&lt;BR /&gt;and variables, and $DATA is the initialized&lt;BR /&gt;arrays and variables.&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 19 Feb 2004 13:55:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/excessively-large-executables/m-p/3195849#M714116</guid>
      <dc:creator>Gregory Fruth</dc:creator>
      <dc:date>2004-02-19T13:55:09Z</dc:date>
    </item>
  </channel>
</rss>

