Skip to content

Avoid recompiling e2e modules with global variables - #2897

Merged
phoenix-meadowlark merged 5 commits into
iree-org:mainfrom
phoenix-meadowlark:cls-variable-fix
Aug 17, 2020
Merged

phoenix-meadowlark merged 5 commits into
iree-org:mainfrom
phoenix-meadowlark:cls-variable-fix

Conversation

@phoenix-meadowlark

@phoenix-meadowlark phoenix-meadowlark commented Aug 14, 2020 •

Copy link
Copy Markdown
Contributor

Follow-up to #2899. The global variables _global_ref_module and _global_tar_modules are used to store compiled IREE modules for the TracedModuleTestCase. Storing the variables on the TracedModuleTestCase cls causes the errors in #2900, and storing the variables on the TracedModuleTestCase instance (via self) doesn't work because tf.test.TestCase wipes these variables before each unittest.

This was tested by manually running an x86-turing presubmit, which passed.

@phoenix-meadowlark phoenix-meadowlark added integrations/tensorflow TensorFlow model import and conversion integrations Relating to high-level frontend integrations hal/vulkan Runtime Vulkan GPU HAL backend labels Aug 14, 2020
@google-cla google-cla Bot added the cla: yes label Aug 14, 2020
@antiagainst

Copy link
Copy Markdown
Member

It seems this way does not address the issue. Letting the class taking hold of the context is the problematic part.

@phoenix-meadowlark phoenix-meadowlark changed the title Remove accidental class variable duplication. Avoid recompiling e2e modules with global variables Aug 17, 2020
@phoenix-meadowlark
phoenix-meadowlark merged commit 04925e2 into iree-org:main Aug 17, 2020
@ScottTodd ScottTodd mentioned this pull request Aug 17, 2020
@phoenix-meadowlark
phoenix-meadowlark deleted the cls-variable-fix branch October 6, 2020 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hal/vulkan Runtime Vulkan GPU HAL backend integrations/tensorflow TensorFlow model import and conversion integrations Relating to high-level frontend integrations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants