Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
4,265
Issues
4,265
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
419
Merge Requests
419
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
9fdce342
Commit
9fdce342
authored
Sep 09, 2010
by
Simon Marlow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
newAlignedPinnedByteArray#: avoid allocating an extra word sometimes
parent
907fa8af
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
rts/PrimOps.cmm
rts/PrimOps.cmm
+5
-0
No files found.
rts/PrimOps.cmm
View file @
9fdce342
...
...
@@ -109,6 +109,11 @@ stg_newAlignedPinnedByteArrayzh
n
=
R1
;
alignment
=
R2
;
/* we always supply at least word-aligned memory, so there's no
need to allow extra space for alignment if the requirement is less
than a word. This also prevents mischief with alignment == 0. */
if
(
alignment
<=
SIZEOF_W
)
{
alignment
=
1
;
}
bytes
=
n
;
/* payload_words is what we will tell the profiler we had to allocate */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment