Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Spark-14138][SQL][master] Fix generated SpecificColumnarIterator code can exceed JVM size limit for cached DataFrames #12108

Closed
wants to merge 2 commits into from

Conversation

kiszk
Copy link
Member

@kiszk kiszk commented Apr 1, 2016

What changes were proposed in this pull request?

This PR reduces Java byte code size of method in SpecificColumnarIterator by using a approach to make a group for lot of ColumnAccessor instantiations or method calls (more than 200) into a method

How was this patch tested?

Added a new unit test, which includes large instantiations and method calls, to InMemoryColumnarQuerySuite

@kiszk kiszk changed the title [Spark-14138][SQL] Fix generated SpecificColumnarIterator code can exceed JVM size limit for cached DataFrames [Spark-14138][SQL][master] Fix generated SpecificColumnarIterator code can exceed JVM size limit for cached DataFrames Apr 1, 2016
@SparkQA
Copy link

SparkQA commented Apr 1, 2016

Test build #54697 has finished for PR 12108 at commit 0a1b881.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@kiszk
Copy link
Member Author

kiszk commented Apr 1, 2016

Jenkins, retest this please

@SparkQA
Copy link

SparkQA commented Apr 1, 2016

Test build #54700 has finished for PR 12108 at commit 0a1b881.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@kiszk
Copy link
Member Author

kiszk commented Apr 1, 2016

@davies , created PR for master

@davies
Copy link
Contributor

davies commented Apr 2, 2016

LGTM, merging into master.

@asfgit asfgit closed this in 877dc71 Apr 2, 2016
@@ -114,6 +114,42 @@ object GenerateColumnAccessor extends CodeGenerator[Seq[DataType], ColumnarItera
(createCode, extract + patch)
}.unzip

/*
* 200 = 6000 bytes / 30 (up to 30 bytes per one call))
* the maximum byte code size to be compiled for HotSpot is 8000.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you give me link to the above limit of 8000 ?

The answer to http://stackoverflow.com/questions/11345034/how-many-bytes-of-bytecode-has-a-particular-method-in-java seems to show a different limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants