Which is indicative that each boxed integer is getting it's own heap allocated element (since the data pointer is different for every element). It seems that the compiler should be able to reuse boxed elements that are of the same value.
Furthermore, I would expect this work across different types with the same underlying kind. Thus, I would also expect:
The backing store for each interface data item is currently its own static temp.
Since we don't write to those static temps, it would be ok to share them.
In order to do so we'd have to name them with their contents so the linker can merge them. That shouldn't be hard; I think we already do that for the backing of strings.
As a side note, we could use the zero value (runtime.zeroVal) for this particular case.
We are painstakingly filling out lit, one word at a time.
For some sizes and types of lit, we could instead lay out the entire data structure (duplicating the type word many times) and then do a DUFFCOPY or the like to copy it to the stack. It'd be faster to compile, probably faster to execute, perhaps smaller binary size.