---------- Original Message ----------------------------------
>From: "Joe Pluta" <joepluta@PlutaBrothers.com>
>
>-- Mainline
>PUSH BASEPTR                           Save "this" pointer
>MOVE %ADDR(CUSTOMER), BASEPTR          Set "this" pointer
>CALL .GETPHONE, +4                     Call method saving space for return 
>value

The PUSH has to know how much to push, has to handle call stack overflow and 
extension and has to return a ptr to the stack location. It winds up being a 
call in and of itself.

The CALL has to load the return address in the call stack entry.

The RETURN from the called module has to pop the stack, deal with call stack 
extension boundaries,  call the destructor mbr function of any objects in the 
called module, unwind any "throw" and "Catch" exception handlers, ...

If you want the debugger to have some brains the call stack needs to be loaded 
with an identifier of the function being called ( so the source debugger knows 
which source code to display ).

The proof would be in the results though. Get one of the 20 people in the world 
who know how to code C++ on the AS400. Write similar code and see how many 
times faster is the RPG version.

Steve Richter




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.