Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alexander Kaznacheev
GHC
Commits
85bcca7e
Commit
85bcca7e
authored
13 years ago
by
Simon Marlow
Committed by
Ian Lynagh
13 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix for a bug in setNumCapabilities
parent
62d4fa7a
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
rts/sm/Storage.c
+8
-3
8 additions, 3 deletions
rts/sm/Storage.c
with
8 additions
and
3 deletions
rts/sm/Storage.c
+
8
−
3
View file @
85bcca7e
...
...
@@ -190,7 +190,7 @@ initStorage( void )
void
storageAddCapabilities
(
nat
from
,
nat
to
)
{
nat
n
,
g
;
nat
n
,
g
,
i
;
if
(
from
>
0
)
{
nurseries
=
stgReallocBytes
(
nurseries
,
to
*
sizeof
(
struct
nursery_
),
...
...
@@ -200,6 +200,12 @@ void storageAddCapabilities (nat from, nat to)
"storageAddCapabilities"
);
}
// we've moved the nurseries, so we have to update the rNursery
// pointers from the Capabilities.
for
(
i
=
0
;
i
<
to
;
i
++
)
{
capabilities
[
i
].
r
.
rNursery
=
&
nurseries
[
i
];
}
/* The allocation area. Policy: keep the allocation area
* small to begin with, even if we have a large suggested heap
* size. Reason: we're going to do a major collection first, and we
...
...
@@ -463,8 +469,7 @@ assignNurseriesToCapabilities (nat from, nat to)
nat
i
;
for
(
i
=
from
;
i
<
to
;
i
++
)
{
capabilities
[
i
].
r
.
rNursery
=
&
nurseries
[
i
];
capabilities
[
i
].
r
.
rCurrentNursery
=
nurseries
[
i
].
blocks
;
capabilities
[
i
].
r
.
rCurrentNursery
=
nurseries
[
i
].
blocks
;
capabilities
[
i
].
r
.
rCurrentAlloc
=
NULL
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment