WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Here we can discuss about the problem found
Post Reply
michaelvrba72
Posts: 15
Joined: Sat Mar 02, 2024 1:32 am
Location: Ořech, Czechia
Has thanked: 33 times
Been thanked: 2 times

WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by michaelvrba72 »

Hello friends, I have found that the WORD.FIND function is gradually taking up free RAM until the OUT OF MEMORY error occurs and the system is not working. Only a system restart will free the memory. System Annex32 CAN 1.70.5 LFS.
Here is the test code:

Code: [Local Link Removed for Guests]

a = 0
b = 45
c = 50
d$ = "27 28"
TIMER0 60000, vypis_ram
TIMER1 5000, cykl_5000
GOSUB vypis_ram
WAIT

cykl_5000:
IF WORD.FIND (d$, WORD$ (DATE$, 1, "/")) THEN e = c ELSE e = b
IF e <> a THEN
  a = e
  Print "Set."
END IF
RETURN

vypis_ram:
print time$ + " RAM FREE: " + str$ (ramfree)
RETURN
Here is a listing of the amount of free memory.

Code: [Local Link Removed for Guests]

Number of program lines :20
Basic File Loaded: /test-ram.bas
Program Running
17:03:21 RAM FREE: 101952
Set.
17:04:21 RAM FREE: 103552
17:05:21 RAM FREE: 103300
17:06:21 RAM FREE: 103064
17:07:21 RAM FREE: 102824
17:08:21 RAM FREE: 102576
17:09:21 RAM FREE: 102336
17:10:21 RAM FREE: 102096
17:11:21 RAM FREE: 101856
17:12:21 RAM FREE: 101616
17:13:21 RAM FREE: 101376
17:14:21 RAM FREE: 101136
17:15:21 RAM FREE: 100896
17:16:21 RAM FREE: 100644
17:17:21 RAM FREE: 100404
17:18:21 RAM FREE: 100152
17:19:21 RAM FREE: 99912
17:20:21 RAM FREE: 99672
Program Ended
User avatar
cicciocb
Site Admin
Posts: 2782
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 592 times
Been thanked: 1990 times
Contact:

Re: WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by cicciocb »

Thanks for the feedback, I'll fix in the next release
User avatar
cicciocb
Site Admin
Posts: 2782
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 592 times
Been thanked: 1990 times
Contact:

Re: WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by cicciocb »

I've fixed this in the version 1.70.52.

Please let me know
michaelvrba72
Posts: 15
Joined: Sat Mar 02, 2024 1:32 am
Location: Ořech, Czechia
Has thanked: 33 times
Been thanked: 2 times

Re: WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by michaelvrba72 »

As always, bug fixed. Thanks, thanks!
:D
22:28:35 RAM FREE: 155400
22:29:35 RAM FREE: 155392
22:30:35 RAM FREE: 155408
22:31:35 RAM FREE: 155404
22:32:35 RAM FREE: 155404
22:33:35 RAM FREE: 155396
...
23:45:35 RAM FREE: 155416
23:46:35 RAM FREE: 155412
23:47:35 RAM FREE: 155412
Monki
Posts: 79
Joined: Mon Feb 27, 2023 12:56 pm
Location: Berlin
Has thanked: 29 times
Been thanked: 18 times

Re: WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by Monki »

Good morning Francesco,
could you please upload the new version for the s3 and s3 qspi too?

Thanks Monki
User avatar
cicciocb
Site Admin
Posts: 2782
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 592 times
Been thanked: 1990 times
Contact:

Re: WORD.FIND gradually occupies free RAM until OUT OF MEMORY is reached

Post by cicciocb »

[Local Link Removed for Guests] wrote: [Local Link Removed for Guests]Tue Jan 28, 2025 6:30 am Good morning Francesco,
could you please upload the new version for the s3 and s3 qspi too?

Thanks Monki
done!
Post Reply