Hi all,
The problem was resolved.
If anyone is interested what is the problem in this situation can read our workaround:
- there is a lot calls to member subprograms in PL/SQL objects
- these member subprograms have some defined attributes
- bacause they are defined with default IN OUT parameters and without NOCOPY keyword, the behaviour for every calling of one object after executing of this subprogram, all attributes to be copied in memory
- this causes a large overhead
- the solution is to be used the NOCOPY keyword

See the PL/SQL User's Guide and Reference 10g, Chapter 11 - Tuning PL/SQL Applications for Performance:
"If you use OUT or IN OUT parameters, PL/SQL adds some performance overhead to ensure correct behavior in case of exceptions (assigning a value to the OUT parameter, then exiting the subprogram because of an unhandled exception, so that the OUT parameter keeps its original value).

If your program does not depend on OUT parameters keeping their values in such situations, you can add the NOCOPY keyword to the parameter declarations, so the parameters are declared OUT NOCOPY or IN OUT NOCOPY.

This technique can give significant speedup if you are passing back large amounts of data in OUT parameters, such as collections, big VARCHAR2 values, or LOBs.

This technique also applies to member subprograms of object types. If these subprograms modify attributes of the object type, all the attributes are copied when the subprogram ends. To avoid this overhead, you can explicitly declare the first parameter of the member subprogram as SELF IN OUT NOCOPY, instead of relying on PL/SQL's implicit declaration SELF IN OUT.
"

After using the NOCOPY keyword, the behaviour of the function is the following:
- for 2000 lines - 20 seconds
- for 5000 lines - 71 seconds