[
https://issues.apache.org/jira/browse/HIVE-5018?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13756749#comment-13756749
]
Thejas M Nair commented on HIVE-5018:
-------------------------------------
What was the runtime ? To reduce the impact of noise caused by OS process and
other things running on the system, I would recommend making sure that each run
for at least 100 seconds (by increasing the number of iterations in the loop),
and repeating it a few times (3-4?). Can you please publish the numbers with
that ?
If there is no noticeable performance difference, I would rather stick to
instantiating the variables inside the loop. That limits the scope of these
variables and makes for more readable code (and prevents accidental use).
> Avoiding object instantiation in loops (issue 6)
> ------------------------------------------------
>
> Key: HIVE-5018
> URL: https://issues.apache.org/jira/browse/HIVE-5018
> Project: Hive
> Issue Type: Sub-task
> Reporter: Benjamin Jakobus
> Assignee: Benjamin Jakobus
> Priority: Minor
> Fix For: 0.12.0
>
> Attachments: HIVE-5018.1.patch.txt
>
>
> Object instantiation inside loops is very expensive. Where possible, object
> references should be created outside the loop so that they can be reused.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira