- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- program too slow to load and link 64bit shared lib...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 11:24 AM
тАО12-18-2002 11:24 AM
I am deciding whether to make my apps 64-bit or 32-bit.
My app process links a lot of quite big shared libraries, 43 of them reaching 650Mb.
When executing, for a same program, 64-bit version takes about 120 secs in user-mode while 32-bit version takes 10 secs also in user-mode.
The program I used:
#include
using namespace std;
int main(){
cout << "start..and it's end" << endl;
return 0;
}
Surely it doesn't need any of the shared libraries but I just "-l" them when linking.
Would anyone tell me what could be the reason?
Thanks in Advance,
Takeshi Sato
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 11:30 AM
тАО12-18-2002 11:30 AM
Re: program too slow to load and link 64bit shared library
OS:HP-UX 11
PHSS_24303 applied.
aCC.03.31.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 11:51 AM
тАО12-18-2002 11:51 AM
SolutionIf I were you, I would do a swremove of aCC and then a fresh install followed by cumulative patches.
The decision to use 64-bit or 32-bit should be based upon the libraries that are available for your applications and for the size of needed data structures. The advantage of 64-bit code is really in the removal of size limits from data; 32-bit code will actually execute faster in almost every case.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 12:40 PM
тАО12-18-2002 12:40 PM
Re: program too slow to load and link 64bit shared library
Some thing to make clear:
The program I coded above is just for this test of linker performance.
Usually my app make full use of the 43 libs of 650MB. But when I conducted a performance tests it resulted that 64-bit version was unusally slow so I coded above.
Actually I just now tested it
on HP-UX 11.11 and it behaves exactly the same.
Although the size of shared libs linked b/w 32 and 64-bit app is about the same(650mb), when it comes to executing,
32) wait for about 1 sec, shows "start...and it's end",
and ends immediately after that.
64) wait for about 10 sec, shows "start...and it's end",
and ends immediately after that.
Would there be any particular difference in behaviour between of 64bit linker (which I guess is : /usr/lib/pa20_64/dld.sl) that makes it at disadvantage when linking a lot of big libraries?
Any, any suggestion I will sincerely appreciate.
Thanks in advance, Tak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 03:22 PM
тАО12-18-2002 03:22 PM
Re: program too slow to load and link 64bit shared library
There are many options that could improve startup time for both 32-bit and 64-bit libraries. The startup time for shared libraries comes from a few activies-
1. resolving symbols
2. executing initializer and static object constructor functions
3. paging in the library memory regions needed to run those initial functions
You can use the fastbind command or ld +fb option to completely cache symbol lookup when linking a program. The feature is not very usable because the fastbind command needs to be rerun whenever any of the shared libraries are updated.
You can use the ld +gst option and related attribute options to use a faster global symbol table and precompute the hash keys used to index that table.
You can use the ld -B option to specify symbol lookup behavior. "-B deferred" will usually give the fastest startup because it does not look up as many code symbols. If a run will actually use almost all code symbols at least once, then "-B immediate" could be a little more efficient by looking up the code symbols in a big batch.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 09:04 PM
тАО12-18-2002 09:04 PM
Re: program too slow to load and link 64bit shared library
>The default for 32 bit exports only used symbols from an a.out.
>The default for 64-bit exports all symbols from an a.out.
I think that would explain all this pretty much.
Actually we've tried the +fb and -B option, but it didn't have any significant effect.
I will try +gst option but in a mean time, if anyone knows if there is a option that changes the default behaviour described by Mike, I would truely appreciate sharing.
Thanks, Tak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-18-2002 10:12 PM
тАО12-18-2002 10:12 PM
Re: program too slow to load and link 64bit shared library
Thanks to Mike my app's start up time improved significantly
with +gst option.
Now I guess it's the +gst tuning time....
If any docs showing the guideline, I would appreciate the URL.
Tak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-19-2002 12:24 AM
тАО12-19-2002 12:24 AM
Re: program too slow to load and link 64bit shared library
I went through HP-UX Linker and Libraries User's Guide HP 9000 Computers (B2355-90655.pdf), and that did not even mention it?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-19-2002 12:54 AM
тАО12-19-2002 12:54 AM
Re: program too slow to load and link 64bit shared library
Acutally, most of what is written is also available at man dld.sl.
So you might want to check that out.
Tak
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-19-2002 03:20 PM
тАО12-19-2002 03:20 PM
Re: program too slow to load and link 64bit shared library
http://www.docs.hp.com./cgi-bin/otsearch/getfile?id=/hpux/onlinedocs/dev/B2355-90721/linkhelp.html#BGHCJHIH