English Amiga Board


Go Back   English Amiga Board > Support > support.Apps

 
 
Thread Tools
Old 16 January 2010, 21:15   #1
Bloodwych
Moderator

Bloodwych's Avatar
 
Join Date: Jun 2001
Location: I'm behind you!
Posts: 3,763
MinStack or Stackattack v2.9?

Although I'm very careful to set all programs, shell prompts and processes a generous amount of stack and suffered no stability problems, I thought it would do no harm to add a stack program as an enable/disable option in the ClassicWB packs.

The default setting will be disabled, but if users ever do suffer a stability issue with a program then enabling this may help.

What I'm stuck on is which is best to use - Minstack or the latest Stackattack v2.9?

Anyone got any opinions on these patches?

Also, does anyone know if they have an effect on Scalos processes? I'm not sure if Scalos makes the same calls it intercepts so it may do nothing?

How about OS35/9, does it have a minimum stack call built in (SYS:Prefs/Workbench->Stack Size option) or is a patch like this still useful?

Last edited by Bloodwych; 16 January 2010 at 22:40.
Bloodwych is offline  
Old 17 January 2010, 14:38   #2
PeterK
Registered User
 
Join Date: Apr 2005
Location: Hangover
Posts: 2,319
Many years ago I once wrote MinStack as my first attempt in assembler programming on the Amiga. At that time StackAttack v1 and v2 already existed but I thought that the way how StackAttack was solving the stack problems was too long winded and that it comes with unnecessary options like ADDSTACK.

I wanted a very short and fast patch because its code is executed for every new process in the system and thus it shouldn't waste any CPU time. That's why I would always prefer to use MinStack. If you don't supply any optional number then you will get at least 8000 bytes of stack for every new process. My startup-sequence has a line MinStack 10000 now which should be enough in most cases. Of course, both patches also work with Scalos or any other program. There is just one exception: the stacksize of devices won't be patched, neither with MinStack nor with StackAttack. (For example: DEVS: Dosdrivers/CD0 or other entries may just have STACKSIZE=600 or similar)

No, OS 3.5 / 3.9 don't have anything like these patches built-in. One of these two patches is a must-have for every startup-sequence because stack overflows are the most common reasons for system crashes and the C:stack instruction would only set the stacksize for the current shell and those commands which are started from it, but not for all background processes or alike. Btw, Scout shows the actual stack usage of every running task.

Last edited by PeterK; 17 January 2010 at 14:48.
PeterK is offline  
Old 17 January 2010, 14:59   #3
Bloodwych
Moderator

Bloodwych's Avatar
 
Join Date: Jun 2001
Location: I'm behind you!
Posts: 3,763
Wow, how lucky was I to get an answer out of the author.

Thanks PeterK.
Bloodwych is offline  
Old 17 January 2010, 15:24   #4
zipper
Registered User
 
Join Date: Mar 2004
Location: finland
Posts: 1,466
Quote:
Originally Posted by PeterK View Post
One of these two patches is a must-have for every startup-sequence because stack overflows are the most common reasons for system crashes
Agreed, but lazy me never updated my original stackattack as I had no problems with it. Got rid of stack owerflow errors.
zipper is online now  
Old 28 August 2015, 17:18   #5
daxb
Registered User
 
Join Date: Oct 2009
Location: Germany
Posts: 2,042
I noticed a problem with StackAttack2 V2.9 and ARexx PRAGMA('S',). Stacksize doesn`t change when StackAttack2 is running as you can see in the Shell example:

Code:
12. System:> rx "address command; stack; x = pragma('S',8000); say x; stack; y = pragma('S',x); say y; stack"
Die aktuelle Stack-Größe beträgt 32.768 Byte.
150000
Die aktuelle Stack-Größe beträgt 32.768 Byte.
8000
Die aktuelle Stack-Größe beträgt 32.768 Byte.
12. System:>
So, if a StackAttack2 user or someone else can confirm it, please report it to the author because I do not have email. For contact address look here: http://aminet.net/package/util/boot/StackAttack2
daxb is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 11:46.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2018, vBulletin Solutions Inc.
Page generated in 0.05872 seconds with 12 queries