title: Jetpack Compose Performance Issue that only occurs in multi module project
body: <p>I have developed a quite complex keyboard layout in Jetpack Compose. Initially, the layout works fine and animations run very smoothly when pressign the keys. Unfortunately, after a few recompositions due to events the animations and everything becomes very slow and laggy.
  I have tried to sample Jave Method calls and I can only see that some function take a lot longer than usual.</p>
  <p><strong>Edit:</strong>
  I have been able to isolate the issue. I have discovered that the performance issue only appears in multi module projects. When I put the <em>exact same</em> compose code in the root <code>app</code> module the issue disappears.</p>
  <p>I have created a project that reproduces the issue:</p>
  <ul>
  <li><a href="https://github.com/THEAccess/example_compose-keyboard-multimodule" rel="noreferrer">Mutli Module Project with performance issue</a></li>
  <li><a href="https://github.com/THEAccess/example_compose-keyboard-multimodule" rel="noreferrer">Single Module Project without performace issue</a></li>
  </ul>
  <p>If you want to reproduce the issue in the multi module project you have to switch between the categories multiple times and then everything becomes very laggy</p>
  <p><a href="https://i.stack.imgur.com/sEhtp.gif" rel="noreferrer"><img src="https://i.stack.imgur.com/sEhtp.gif" alt="Example Video" /></a></p>
  <p><em>Note: I know Jetpack Compose is still in alpha and this issue might be a bug in Jetpack Compose. But I want to make sure that it's not a bug of my code or a general limitation of Compose</em></p>