# "fatal error C1060: compiler is out of heap space" for lib/edgepaint/lab\_gamut.c

**URL:** <https://forum.graphviz.org/t/fatal-error-c1060-compiler-is-out-of-heap-space-for-lib-edgepaint-lab-gamut-c/187>\
**Category:** Dev\
**Created:** [June 16, 2020, 6:04pm UTC](https://forum.graphviz.org/t/fatal-error-c1060-compiler-is-out-of-heap-space-for-lib-edgepaint-lab-gamut-c/187 "2020-06-16T18:04:11Z")\
**Posts on this page:** 1\
**Showing post:** 39

<div class="post-metadata">

**Author:** ![magjac](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/magjac/32/16_2.png) [@magjac](https://forum.graphviz.org/u/magjac)\
**Post date:** [June 22, 2020, 12:27pm UTC](https://forum.graphviz.org/t/fatal-error-c1060-compiler-is-out-of-heap-space-for-lib-edgepaint-lab-gamut-c/187/39 "2020-06-22T12:27:09Z")

</div>

Two things seem necessary to be able to build on the GitLab Windows runner:

1. Disable code analysis _completely_ (there are flavors)
2. Rewrite `lab_gamut.c` to use a plain array instead of an array of structs.

I measured the memory consumption on my local laptop with different settings:

| Code analysis | Plain array | Memory consumption | Builds on GitLab |
| --- | --- | --- | --- |
| Yes | No | 3212 MB | No |
| Yes | Yes | 2813 MB | No |
| No | No | 969 MB | No |
| No | Yes | 726 MB | Yes |

Unless I hear objections I’m going to pursue this.

TODO:

- Rewrite `lab.c` (the consumer of `lab_gamut.c`) to use the plain array and test it.
- Clean up the lab\_gamut project settings to get a MVC.
- Clean up the GitLab CI configuration and merge with current Linux builds.
- Add deploy of Windows binaries to [https://www2.graphviz.org/Packages/](https://www2.graphviz.org/Packages/)
- Create MR for review

---

_[View the full topic](https://forum.graphviz.org/t/fatal-error-c1060-compiler-is-out-of-heap-space-for-lib-edgepaint-lab-gamut-c/187)._
