[jsword-devel] [JIRA] Commented: (JS-154) BufferedReader should use an explicit buffer size.

Martin Denham (JIRA) jira at crosswire.org
Tue Jan 4 04:06:34 MST 2011


    [ http://www.crosswire.org/bugs/browse/JS-154?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13770#action_13770 ] 

Martin Denham commented on JS-154:
----------------------------------

I experimented with the affect of setting an exact size for BufferedReader yesterday and the performance affects were not significant.  A large percentage (just under half) of startup time seems to be spent doing garbage collection but obviously using less temporary memory will lead to less gc.  However, I may forward my experimental code which sets the BufferedReader size to the size of the conf file (if <8k)  because it is fairly simple and seems without risk (it's on another pc so I'll add it later).

However, a general thought regarding performance is that it is not worth doing anything that complicates the code because it will probably have little affect.  Android 2.3 has concurrent gc which will hopefully make a big difference.

> BufferedReader should use an explicit buffer size.
> --------------------------------------------------
>
>                 Key: JS-154
>                 URL: http://www.crosswire.org/bugs/browse/JS-154
>             Project: JSword
>          Issue Type: Sub-task
>    Affects Versions: 1.6
>         Environment: Android.
>            Reporter: DM Smith
>            Assignee: DM Smith
>             Fix For: 1.6.1
>
>
> When not specified, a BufferedReader uses an undefined buffer size. The javadoc claims that the size is appropriate for most uses. Android gives a warning message indicating that a specific size should be used.
> The default size in Sun's Java is 8192. Until we have better info, use this to quiet Android's vm.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://www.crosswire.org/bugs/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jsword-devel mailing list