[Mono-list] Exceptions and error codes.

Richard Torkar richard.torkar@htu.se
21 Mar 2003 09:17:29 +0100


On Fri, 2003-03-21 at 04:10, Fergus Henderson wrote:
> On 20-Mar-2003, Thong Nguyen <tum@veridicus.com> wrote:
> > Exceptions can be much slower than using error codes, however, it
> > should be noted that the path of error is usually the least walked path.
> > Most of the time your code will not throw exceptions.  When exceptions
> > aren't thrown there is *very* little overhead.
> 
> Are you sure?  Have you measured it?
> 
> Note that the exception handling scheme used on Windows requires some
> overhead for "try" statements even in the case when no exception is thrown.

What? ^^^^^^^^^^^^^^ How can that be the case?

If the catch does not fire then the try should not be evaluated, right?
This is something I've missed completely.


/Richard
-- 
Ph.D. Student
Dept. of Informatics and Mathematics
HTU