× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On 1/3/2013 9:43 AM, RPGLIST wrote:
I'm looking for any and all suggestions on possible ways to speed up some
programs.

The typical ones that come to mind are:

1. avoiding open and closes on files
2. Not setting LR when calling a program or procedure multiple times
3. using Data structures for block reads and writes

Any other suggestions?

Random poking is the least efficient way of improving performance.
Measure, measure, measure and then you know where the low performing
areas are.

In my experience, the number one bottleneck is I/O. Typically, we do
way too much of it. Imagine a customer master file with 50 columns, 500
total bytes long. Our RPG program does a CHAIN to get the customer's
name and address. The database needs to shuffle all 500 bytes to the
RPG buffer, which in turn needs to map 50 columns to 50 fields. We
actually need a quarter of the bytes and only 5 fields. And we do that
CHAIN for every one of a million transactions. That's a lot of bytes to
copy and discard and a lot of fields to map and ignore because someone
in 1986 thought it was a bad idea to make a logical file containing only
name and address.

But measure it! It could be anything, including a giant sized return
value from a function call.

Have a look at iDoctor. https://www-912.ibm.com/i_dir/idoctor.nsf
--buck

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.