Project

General

Profile

Bug #10373

Try to replace the StackUnwindExceptions used for control flow in BlockManager with a return value

Added by Artur Școlnic 12 months ago. Updated 12 months ago.

Status:
WIP
Priority:
Normal
Target version:
-
Start date:
Due date:
% Done:

0%

billable:
No
vendor_id:
GCD
case_num:
version_reported:
version_resolved:
reviewer:
production:
No
env_name:
topics:

Related issues

Related to Base Language - Support #4133: reduce use of throw for control flow New
Related to Base Language - Feature #7045: re-implement "normal" (non-abend) stack unwinding to avoid throwing an exception Test

History

#1 Updated by Artur Școlnic 12 months ago

StackUnwindExceptions are used in control flow logic of the iterating blocks in BlockManager, but AFAIK the exceptions are used only as a signal to the calling method that a next/leave was encountered, maybe there is merit to replace the exception handling with a return value that would be propagated upwards towards the stack, same as the exceptions, the difference being that the exception handling is a lot more expensive than a return value. The exceptions can be replaced with an enum or a complex object that also has an enum as one of of the attributes. This needs experimenting, a performance improvement is not guaranteed.

#3 Updated by Greg Shah 12 months ago

  • Related to Support #4133: reduce use of throw for control flow added

#4 Updated by Greg Shah 12 months ago

  • Related to Feature #7045: re-implement "normal" (non-abend) stack unwinding to avoid throwing an exception added

#5 Updated by Greg Shah 12 months ago

This is indeed a good idea and it will improve performance. We have worked on some of this already, including implementation of an approach that was "low hanging fruit". See #4133 and #7045.

#6 Updated by Artur Școlnic 12 months ago

  • Assignee set to Artur Școlnic
  • Status changed from New to WIP

Also available in: Atom PDF