Merge: Use linker symbols to encode colors
authorJean Privat <jean@pryen.org>
Tue, 13 Jan 2015 01:29:02 +0000 (20:29 -0500)
committerJean Privat <jean@pryen.org>
Tue, 13 Jan 2015 01:29:02 +0000 (20:29 -0500)
Genuine constant static variables are used to store the colors used in OO mechanisms.
This makes the compiler program slower since additional indirections are required to get the values.
It also produces a little bit larger executables since static memory has to store the colors.

This PR introduce a trick user in the original PRM that uses linker symbols to encode the colors.
It is not completely portable so it must be activated with the option `--colors-are-symbols`

For numbers (with the traditional nitc/nitc/nitc)
before: 0m7.544s
after: 0m7.228s (so -4%)

Pull-Request: #1093
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

1  2 
src/compiler/abstract_compiler.nit
src/compiler/android_platform.nit
src/compiler/separate_compiler.nit

Simple merge
Simple merge
Simple merge