Opened 6 years ago

Closed 5 years ago

#54 closed task (wontfix)

Split global variables by compilation unit.

Reported by: mornfall Owned by: mornfall
Priority: major Milestone: 4.3
Component: VM Keywords:
Cc:

Description

This would be a straightforward static heuristic and could save considerable memory for many programs (especially C++ programs where a whole bunch of units from libc++ contain what are essentially read-only but non-constant globals). This would also allow reverting locale.cpp to its original upstream version without considerable loss of efficiency.

The cost would be a level of indirection (the current 'globals' object would become a vector of pointers) and more complicated ptr2i caching machinery.

Change History (1)

comment:1 Changed 5 years ago by mornfall

Resolution: wontfix
Status: newclosed

The current plan is to abolish the globals mechanism entirely and keep each global in a separate heap object. Two things are needed for that: 1) support for distinct address spaces in the heap and 2) more efficient snapshot representation (the two being closely related).

Note: See TracTickets for help on using tickets.