Author Topic: GDI functions & Init problems?  (Read 16275 times)

0 Members and 2 Guests are viewing this topic.

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #30 on: May 12, 2015, 08:58:41 PM »
Hi Mike
what you mean under raw...
do you mean without examples or something else
and as i say i am not sure what might be problem... ::)

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #31 on: May 12, 2015, 09:50:46 PM »
Mike
there is no need to check whole interpreter...
do you can test only my GDI functions and and how should look properly
so without GDI leaks or multiply executions

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #32 on: May 13, 2015, 02:03:00 AM »
Yes there is a big mem leak in new dll.
In attachmant are two versions ,one with memleak and one produced with old o2 dll
without mem leak.
old version when interpreter execute mandel stay on cca 3900k
when new grove ..grove...
this is really bad

Charles
please ...please ...please ...please fix this once for all times  :(

.

Charles Pegge

  • Guest
Re: GDI functions & Init problems?
« Reply #33 on: May 13, 2015, 07:18:37 AM »
Hi Aurel,

I've done lots of string tests, but no memory leaks detected so far.

2 Suggestions which will benefit your code:

First, use #autodim off. This will expose any variable which have not been formally dim'ed.

It is essential that string variables are not created in the middle of a loop.

Second, ensure that the RTL matches the compiler. Using an old RTL with a recent compiler could be very risky.


Meanwhile, I will continue string testing for leaks. I might also create a stringy interpreter to aid this process, since there are many o2 examples that use strings but none do so in a highly iterative manner.



JRS

  • Guest
Re: GDI functions & Init problems?
« Reply #34 on: May 13, 2015, 08:35:30 AM »
Quote
Meanwhile, I will continue string testing for leaks. I might also create a stringy interpreter to aid this process, since there are many o2 examples that use strings but none do so in a highly iterative manner.

May I suggest using your DLLC interface with Script BASIC to test your string engine? SB strings are rock solid and only limited by available memory.

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #35 on: May 13, 2015, 02:02:54 PM »
Quote
Meanwhile, I will continue string testing for leaks. I might also create a stringy interpreter to aid this process, since there are many o2 examples that use strings but none do so in a highly iterative manner.
Ok i will download latest release with latest RTL if you think that part of problem is there.
But this things becomes very frustrating....
same code work with older version ...fine
but same code not work properly with new version and that is all the time  ::)

JRS

  • Guest
Re: GDI functions & Init problems?
« Reply #36 on: May 13, 2015, 02:31:32 PM »
Aurel,

It would help Charles if you could be more detailed about the issues you're having with O2. Posting small code snippets that show the problem is really helpful. As you know, O2 is a work in process and I'm not aware of a stable release. I'm sure your code base is going to change over time as Charles finds better ways of doing things.

John

Charles Pegge

  • Guest
Re: GDI functions & Init problems?
« Reply #37 on: May 13, 2015, 08:47:24 PM »
I found 6 bstrings in Ruben4. These should be strings for automatic garbage collection.

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #38 on: May 13, 2015, 09:34:47 PM »
yes there are 6 bstrings but those bstrings are not part of interpreter loop
and are present when i compile program with old oxygen too but there is no mem leak
as i get with new dll.

Charles Pegge

  • Guest
Re: GDI functions & Init problems?
« Reply #39 on: May 13, 2015, 11:52:00 PM »
No O2 memory leaks picked up so far.

My stringiest approximation to an interpreter, LeanLisp, has none

bstrings must be explicitly freed with frees (or freememory). It is important to eliminate bugs wherever they are found.

PS:

You have also commented out indexbase 0

This will cause instability when using arrays indexed at 0

Code: OxygenBasic
  1. For n = 0 TO 1000
  2. arg0[n]=""
  3. arg1[n]=""
  4. arg2[n]=""
  5. arg3[n]=""
  6. arg4[n]=""
  7. arg5[n]=""
  8. arg6[n]=""
  9. arg7[n]=""
  10. arg8[n]=""
  11. arg9[n]=""
  12. arg10[n]=""
  13. arg11[n]=""
  14. arg12[n]=""
  15. arg13[n]=""
  16. arg14[n]=""
  17. arg15[n]=""
  18. arg16[n]=""
  19. arg17[n]=""
  20. arg18[n]=""
  21. arg19[n]=""
  22. arg20[n]=""
  23. Next n
  24.  
« Last Edit: May 14, 2015, 12:06:12 AM by Charles Pegge »

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #40 on: May 14, 2015, 01:27:03 AM »
ok i will remove bstrings and reformat array to indexbase 1
then wewill see...


.

Charles Pegge

  • Guest
Re: GDI functions & Init problems?
« Reply #41 on: May 14, 2015, 01:51:32 AM »
Aurel, please stay with indexbase 0, if that is what your are accustomed to using. (As in FreeBasic)

JRS

  • Guest
Re: GDI functions & Init problems?
« Reply #42 on: May 14, 2015, 02:07:01 AM »
I'm still confuse why Aurel would REM out indexbase 0 and then base his arrays on zero anyways?  :o

A. Sloppy/lazy programmer that finds it easier to blame others and let them fix his self inflicted problems.

B. O2 should be smart enough to assume Aurel's intension at any level.

C. Aurel need to brush up on his debugging skills and not assume if it doesn't work it must be O2's fault. Getting away with unplugged holes of the past is not justification that Charles is notorious for breaking things.  ::)

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #43 on: May 14, 2015, 12:52:49 PM »
John
stop babeling about things you don't undrerstand
first try exes from zip memleak then you will see what is all about of course if
you are not stupid enough.
second problem is really in o2 because how explain that something work
as it suposed to be then in new release not work...do you understand now
mister -super john

Charles
I will try indexbase 0 & 1 and what is the difference ...
i will also test autodim off  ;)

Aurel

  • Guest
Re: GDI functions & Init problems?
« Reply #44 on: May 14, 2015, 01:40:48 PM »
Charles
i do next
all variables - #autodim off 
removed all bstrings
left indexbase 0

mem leak is now little bit less cca 50 000 k when without changes grove up to 200 000k
i have download latest release from wizzard ...do you have something new?

.