Uploaded image for project: 'UIMA'
  1. UIMA
  2. UIMA-2715

Add bulk-add method variant to IntVector

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Trivial
    • Resolution: Fixed
    • None
    • 2.4.1SDK
    • Core Java Framework
    • None

    Description

      There are several places where an array of ints gets added to an int vector, by iterating over the array, and calling the add(int) method. This can be improved by having a bulk add operation that does various growing/bounds check just once, and then does the copy using System.arraycopy. This has a measurable effect (not too much, but observable) on things such as CAS serialization.

      Attachments

        Activity

          People

            schor Marshall Schor
            schor Marshall Schor
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: