runtime: allocate page table lazily
This removes the 256MB memory allocation at startup,
which conflicts with ulimit.
Also will allow to eliminate an unnecessary memory dereference in GC,
because the page table is usually mapped at known address.
Update issue 5049.
Update issue 5236.
Names than state their type are weaker than names that explain their purpose. We call ...
11 years, 11 months ago
(2013-05-28 12:54:33 UTC)
#5
Names than state their type are weaker than names that explain their purpose. We
call a variable i or index, not countinteger, for clarity and to avoid
redundancy, and to me "spanarray" sounds like "countinteger". It's type is
array, its name should say something we don't already know.
On 2013/05/28 12:54:33, r wrote: > Names than state their type are weaker than names ...
11 years, 11 months ago
(2013-05-28 15:00:53 UTC)
#6
On 2013/05/28 12:54:33, r wrote:
> Names than state their type are weaker than names that explain their purpose.
We
> call a variable i or index, not countinteger, for clarity and to avoid
> redundancy, and to me "spanarray" sounds like "countinteger". It's type is
> array, its name should say something we don't already know.
I think that the "span" part is good, we have spans only in a single place, so
it states both "type" and "purpose".
What about "spantab"?
On Mon, May 27, 2013 at 2:51 AM, <dvyukov@google.com> wrote: > Also will allow to ...
11 years, 11 months ago
(2013-05-28 16:47:36 UTC)
#11
On Mon, May 27, 2013 at 2:51 AM, <dvyukov@google.com> wrote:
> Also will allow to eliminate an unnecessary memory dereference in GC,
> because the page table is usually mapped at known address.
>
How does "usually" make a memory dereference unnecessary?
Russ
On Tue, May 28, 2013 at 8:47 PM, Russ Cox <rsc@golang.org> wrote: > On Mon, ...
11 years, 11 months ago
(2013-05-28 17:01:46 UTC)
#12
On Tue, May 28, 2013 at 8:47 PM, Russ Cox <rsc@golang.org> wrote:
> On Mon, May 27, 2013 at 2:51 AM, <dvyukov@google.com> wrote:
>
>> Also will allow to eliminate an unnecessary memory dereference in GC,
>> because the page table is usually mapped at known address.
>>
>
> How does "usually" make a memory dereference unnecessary?
>
>
Currently it's unfeasible, but if/when the GC inner loop is simpler (like
what it was before precise GC), we can have 2 inner loops: one that
reads runtime·mheap->spans
and the second with the hardcoded constant.
*** Submitted as https://code.google.com/p/go/source/detail?r=2e317dfcaf96 *** runtime: allocate page table lazily This removes the 256MB memory ...
11 years, 11 months ago
(2013-05-28 18:04:40 UTC)
#13
*** Submitted as https://code.google.com/p/go/source/detail?r=2e317dfcaf96 ***
runtime: allocate page table lazily
This removes the 256MB memory allocation at startup,
which conflicts with ulimit.
Also will allow to eliminate an unnecessary memory dereference in GC,
because the page table is usually mapped at known address.
Update issue 5049.
Update issue 5236.
R=golang-dev, khr, r, khr, rsc
CC=golang-dev
https://codereview.appspot.com/9791044
Issue 9791044: code review 9791044: runtime: allocate page table lazily
(Closed)
Created 11 years, 11 months ago by dvyukov
Modified 11 years, 11 months ago
Reviewers:
Base URL:
Comments: 3