You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Adam Lally (JIRA)" <ui...@incubator.apache.org> on 2007/06/06 22:33:25 UTC

[jira] Resolved: (UIMA-440) CAS heap doesn't grow correctly when first page exceeded

     [ https://issues.apache.org/jira/browse/UIMA-440?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adam Lally resolved UIMA-440.
-----------------------------

    Resolution: Fixed
      Assignee: Thilo Goetz

I believe I fixed this.  Thilo, please review.

> CAS heap doesn't grow correctly when first page exceeded
> --------------------------------------------------------
>
>                 Key: UIMA-440
>                 URL: https://issues.apache.org/jira/browse/UIMA-440
>             Project: UIMA
>          Issue Type: Bug
>          Components: Core Java Framework
>    Affects Versions: 2.1
>            Reporter: Adam Lally
>            Assignee: Thilo Goetz
>            Priority: Critical
>             Fix For: 2.2
>
>
> This test case (which I''ll check i under this issue) demonstrates the issue:
>       for (int j = 0; j < 10; j++) {
>         for (int i = 0; i < 200000; i++) {
>           cas.createAnnotation(annotType, i, i);
>         }
>         
>         heapSize = ((CASImpl) cas).getHeap().getCurrentTempSize();
>         bufSize = ((CASImpl)cas).getHeap().heap.length;
>         //System.out.println("Heap size: " + heapSize + ", buffer size: " + bufSize);      
>         assertTrue(heapSize <= bufSize);
>         Assert.assertTrue(bufSize < CASImpl.DEFAULT_RESET_HEAP_SIZE);      
>         cas.reset();
>       }
> The CAS should grow by one page initially (to 1,000,000 cells), but then should stay at that size.  But this test fails.  The output of the System.out.println is:
> Heap size: 800008, buffer size: 1500000
> Heap size: 800008, buffer size: 2000000
> Heap size: 800008, buffer size: 2500000
> Heap size: 800008, buffer size: 3000000
> Heap size: 800008, buffer size: 3500000
> Heap size: 800008, buffer size: 4000000
> Heap size: 800008, buffer size: 4500000
> The heap seems to be growing by one page *each* time.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.