From mboxrd@z Thu Jan 1 00:00:00 1970 From: Harry Kalogirou Subject: Re: ELKS executable, time for a change? Date: 28 Oct 2002 20:52:26 +0200 Sender: linux-8086-owner@vger.kernel.org Message-ID: <1035831066.5491.106.camel@cool> References: <1035807219.5492.84.camel@cool> <1035810496.2067.7.camel@irongate.swansea.linux.org.uk> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1035810496.2067.7.camel@irongate.swansea.linux.org.uk> List-Id: Content-Type: text/plain; charset="us-ascii" To: Alan Cox Cc: Linux-8086 > If you have code to detect stack overflows then you can do it with a bit > of compiler help. It makes things a lot more expensive so I question > whether it should be done. > > Basically your entry code starts to look like > > function_entry: > if(new frame wont fit on stack) > { > alloc new stack segment > push old esp to new stack > push args to new stack > call function_entry > fix stack > pop old stack segment > free newer stack segment > ret > } > > Well, I think I can live with the fixed stack then! Harry