aldweb

Fermer I. aldweb

Fermer II. Gratuitiels PC

Fermer III. Gratuitiels Palm

Fermer IV. Partagiciels Palm

Fermer V. iziBasic Palm

Fermer VI. Connaissance Palm

Fermer VII. Ordinateur Poche

Fermer VIII. miniPortail

Spécial !



Version mobile
de l'aldweb Site

m.aldweb.com


Ni Français, ni Anglais ?

Essayez donc l'un de ces drapeaux :
[de] [es] [it] [pt]
Recherche




Météo / Spam / www

Météo Lyon


aldweb contre le SPAM


Newsletter
Pour avoir des nouvelles de ce site, inscrivez-vous à notre Newsletter.
S'abonner
Se désabonner
298 Abonnés
Sites web de la famille

Webmaster - Infos
News Amis
Visites

   visiteurs

   visiteurs en ligne

Sondage
Comment trouve-tu le nouvel habillage de l'aldweb Site ?
 
Superbe !
Joli
Moyen
Moche...
Résultats
forum.gifForum - iziBasic - Sujet n°1518

Forum - Forum
iziBasic - iziBasic


Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 257

actif  Sujet n° 1518  Number Stack

le 05/03/2007 @ 16:56
par JoeV

Anonyme



Hello again.

My app is getting large, just over 16K out of 24,000 bytes available. Izibasic compiler says that I am only using 556 [+11] bytes of number stack out of 12,000. I recently received a “number stack overflow” compiler error. As per the manual, I changed some variables (only 3) to constants and that fixed the problem. Since I have more code to write, I expect to receive more overflow errors. (Maybe immediately after writing this email.) Perhaps I am writing code that inefficiently uses the numbers stack.

Therefore, my questions at this point are:

(1) 12,000-556>11,000 bytes that iziBasic needs for my app. Is this possible?
(2) How does iziBasic use the numbers stack beyond what my program variables require?
(3) How can I write my code to minimize the numbers stack usage, thereby reducing the chance of an overflow error in the future?
(4) Is there a way that I can monitor the stack's size so that I can be warned before an error occurs?

I know that's a lot to ask. As usual, any help is greatly appreciated.

JoeV
  Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 1
--------
le 06/03/2007 @ 00:26
par aldweb

Anonyme

visiteur
Hello Joev,

1) No, the code stack and the number stack are 2 different things.

2) It should not be used too much, mainly for complex calculations, but no more than 20 or so stack items, so you are far from the limit.
Make sure that you do not get an array index out of range when using the A() array...

3) With a stack of 12000 possible number values to store, you have plenty of space.
So there must be something in your code that exhausts this limit. I just cannot figure out what at this stage...

4) Yes, use the FRE function, with:
FRE(1) first free Number stack address
FRE(4) last free Number stack address
So, the difference between these 2 values should give you how your free stack evolves over time.
So just test it in various area of your source code and we might be able to isolate the area where something strange/wrong/weird occurs. From that point on, it will be easier to help you!

Cheers,
aldweb
Ecrire à aldweb   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 2
--------
le 06/03/2007 @ 01:43
par JoeV

Anonyme

visiteur
Since I am only using 556 out of 12,000 bytes of the numbers stack, it must have been another problem, such as an array. Fre(4) should help me pin this down, should it happen again.

Thanks again, Aldweb.

JoeV
  Poster une réponse  Haut
actif sujet actif   clos sujet clos   Important! Important!   Nouveau Nouveau message   -   Rectifier Rectifier message   Clôturer Clôturer sujet   Remonter Remonter
[]
Catégories de discussion  Forum 



 
^ Haut ^