Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8278447

Improve performance with the use of catchException and asSpreader combinator

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P3 P3
    • tbd
    • 18
    • core-libs
    • None

      JEP 416 implementation does not use catchException and asSpreader combinator because of the performance regression. In particular the cold startup regression is significant due to the spinning and loading of the lambda classes.

      The current implementation decodes from the stack trace to determine if NPE and CCE are thrown due to illegal argument passed to Method::invoke or thrown by the method body so that IAE or ITE is thrown properly. It also has a specialized logic to avoid using asSpreader if the method has 3 or fewer arguments. It'd be ideal to improve the performance of catchException and asSpreader or the version specified for core reflection use such that the special logics can be removed.

            mchung Mandy Chung
            mchung Mandy Chung
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: