title: Can't solve "Java heap space" error in eclipse
body: <p>While running my Java code in Eclipse IDE, I got the error:</p>
  <blockquote>
  <p><strong>Exception in thread &quot;D3D Screen Updater&quot; Exception in thread</strong>
  <strong>&quot;AWT-EventQueue-0&quot; java.lang.OutOfMemoryError: Java heap space</strong></p>
  </blockquote>
  <p>I searched for this error and tried solutions described <a href="https://wiki.eclipse.org/FAQ_How_do_I_increase_the_heap_size_available_to_Eclipse%3F" rel="noreferrer">here</a> and <a href="http://choorucode.com/2013/09/29/how-to-increase-heap-space-of-eclipse/" rel="noreferrer">here</a>, but they did not work.</p>
  <p>I changed these parameters in <strong>eclipse.ini</strong>:</p>
  <blockquote>
  <p><strong>--launcher.XXMaxPermSize</strong></p>
  <p><strong>512M</strong></p>
  <p><strong>-Xms40m</strong></p>
  <p><strong>-Xmx512m</strong></p>
  </blockquote>
  <p>to:</p>
  <blockquote>
  <p><strong>--launcher.XXMaxPermSize</strong></p>
  <p><strong>1024M</strong></p>
  <p><strong>-Xms512m</strong></p>
  <p><strong>-Xmx2048m</strong></p>
  </blockquote>
  <h1>EDIT:</h1>
  <p>I changed this parameters at Run Configurations:</p>
  <p><img src="https://i.stack.imgur.com/xgKUO.png" alt="enter image description here" /></p>
  <p>But I still get the same error. Am I missing something?</p>