summaryrefslogtreecommitdiff
path: root/rts/PrimOps.cmm
diff options
context:
space:
mode:
authorBen Gamari <bgamari.foss@gmail.com>2016-06-03 22:22:42 +0200
committerBen Gamari <ben@smart-cactus.org>2016-06-04 09:35:49 +0200
commit4dbacbc89a999bf371d51194b4662a209ac907f1 (patch)
tree50f20abee2974212ef19ae7660802a3da367e7b9 /rts/PrimOps.cmm
parenteda73a3ad3fdd98cf877b25c3c984c6e1b2217fc (diff)
downloadhaskell-4dbacbc89a999bf371d51194b4662a209ac907f1.tar.gz
Rename isPinnedByteArray# to isByteArrayPinned#
Reviewers: simonmar, duncan, erikd, austin Reviewed By: austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2290 GHC Trac Issues: #12059
Diffstat (limited to 'rts/PrimOps.cmm')
-rw-r--r--rts/PrimOps.cmm12
1 files changed, 9 insertions, 3 deletions
diff --git a/rts/PrimOps.cmm b/rts/PrimOps.cmm
index a8e2a1b66c..160bccd2f9 100644
--- a/rts/PrimOps.cmm
+++ b/rts/PrimOps.cmm
@@ -141,17 +141,23 @@ stg_newAlignedPinnedByteArrayzh ( W_ n, W_ alignment )
return (p);
}
-stg_isPinnedByteArrayzh ( gcptr mba )
-// MutableByteArray# s -> Int#
+stg_isByteArrayPinnedzh ( gcptr ba )
+// ByteArray# s -> Int#
{
W_ bd, flags;
- bd = Bdescr(mba);
+ bd = Bdescr(ba);
// pinned byte arrays live in blocks with the BF_PINNED flag set.
// See the comment in Storage.c:allocatePinned.
flags = TO_W_(bdescr_flags(bd));
return (flags & BF_PINNED != 0);
}
+stg_isMutableByteArrayPinnedzh ( gcptr mba )
+// MutableByteArray# s -> Int#
+{
+ jump stg_isByteArrayPinnedzh(mba);
+}
+
// shrink size of MutableByteArray in-place
stg_shrinkMutableByteArrayzh ( gcptr mba, W_ new_size )
// MutableByteArray# s -> Int# -> State# s -> State# s