title: IntelliJ Idea 2016 memory problems on OSX
body: <p>I just updated to Idea 2016.3.2. And keep getting this error.</p>
  
  <blockquote>
    <p>There is not enough memory to perform the requested operation. Please
    increase 'Xmx' setting and restart the IDE for change to take effect.</p>
  </blockquote>
  
  <p><a href="https://i.stack.imgur.com/UOHMF.png" rel="noreferrer"><img src="https://i.stack.imgur.com/UOHMF.png" alt="enter image description here"></a></p>
  
  <p>The last thing i did was to increase the Xmx memory option to 2048 in the idea.vmoptions file (as instructed by this answer <a href="https://stackoverflow.com/questions/13578062/how-to-increase-ide-memory-limit-in-intellij-idea-on-mac/13581526#13581526">How to increase IDE memory limit in IntelliJ IDEA on Mac?</a>)</p>
  
  <p>But it keeps runing out of memory still. </p>
  
  <p>Does anyone know what I need to do?</p>
  
  <p>... after looking into it some more it now seems to me like it's a git process that causes the memory failure. initiated when I open a git managed project.
  <a href="https://i.stack.imgur.com/uEgUL.png" rel="noreferrer"><img src="https://i.stack.imgur.com/uEgUL.png" alt="enter image description here"></a></p>
  
  <p>Excerp from log:</p>
  
  <blockquote>
    <p>java.lang.OutOfMemoryError: Java heap space   at
    java.util.Arrays.copyOf(Arrays.java:3332)     at
    java.lang.AbstractStringBuilder.ensureCapacityInternal(AbstractStringBuilder.java:124)
      at
    java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:448)
      at java.lang.StringBuilder.append(StringBuilder.java:136)   at
    git4idea.history.GitHistoryUtils$2.onLineAvailable(GitHistoryUtils.java:579)
      at sun.reflect.GeneratedMethodAccessor129.invoke(Unknown Source)    at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)     at
    com.intellij.util.EventDispatcher.dispatch(EventDispatcher.java:99)
      at
    com.intellij.util.EventDispatcher.access$200(EventDispatcher.java:35)
      at
    com.intellij.util.EventDispatcher$2.invoke(EventDispatcher.java:79)
      at com.sun.proxy.$Proxy123.onLineAvailable(Unknown Source)  at
    git4idea.commands.GitLineHandler.notifyLine(GitLineHandler.java:144)
      at
    git4idea.commands.GitLineHandler.notifyLines(GitLineHandler.java:106)
      at
    git4idea.commands.GitLineHandler.onTextAvailable(GitLineHandler.java:74)
      at
    git4idea.commands.GitTextHandler$1.onTextAvailable(GitTextHandler.java:90)
      at sun.reflect.GeneratedMethodAccessor72.invoke(Unknown Source)     at
    sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)     at
    com.intellij.execution.process.ProcessHandler$4.invoke(ProcessHandler.java:226)
      at com.sun.proxy.$Proxy16.onTextAvailable(Unknown Source)   at
    com.intellij.execution.process.ProcessHandler.notifyTextAvailable(ProcessHandler.java:200)
      at
    com.intellij.execution.process.BaseOSProcessHandler$SimpleOutputReader.onTextAvailable(BaseOSProcessHandler.java:290)
      at
    com.intellij.util.io.BaseOutputReader.sendText(BaseOutputReader.java:202)
      at
    com.intellij.util.io.BaseOutputReader.processInput(BaseOutputReader.java:186)
      at
    com.intellij.util.io.BaseOutputReader.readAvailableBlocking(BaseOutputReader.java:140)
      at
    com.intellij.util.io.BaseDataReader.readAvailable(BaseDataReader.java:82)
      at com.intellij.util.io.BaseDataReader.doRun(BaseDataReader.java:160)
      at com.intellij.util.io.BaseDataReader$1.run(BaseDataReader.java:61)
      at
    java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at java.util.concurrent.FutureTask.run(FutureTask.java:266)     at
    java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    2017-01-04 10:16:01,967 [ 393766]  ERROR -
    .intellij.util.EventDispatcher - IntelliJ IDEA 2016.3.2  Build
    IU-163.10154.41  2017-01-04 10:16:01,967 [ 393766]  ERROR - .intellij.util.EventDispatcher - JDK: 1.8.0_112-release  2017-01-04
    10:16:01,967 [ 393766]  ERROR - .intellij.util.EventDispatcher - VM:
    OpenJDK 64-Bit Server VM  2017-01-04 10:16:01,967 [ 393766]  ERROR -
    .intellij.util.EventDispatcher - Vendor: JetBrains s.r.o  2017-01-04
    10:16:01,967 [ 393766]  ERROR - .intellij.util.EventDispatcher - OS:
    Mac OS X  2017-01-04 10:16:01,971 [ 393770]  ERROR -
    .intellij.util.EventDispatcher - Last Action: EditCustomVmOptions 
    2017-01-04 10:16:03,231 [ 395030]  ERROR -
    .intellij.util.EventDispatcher - Java heap space</p>
  </blockquote>