HeapView | Tool to view heap chunks and memory writes
kandi X-RAY | HeapView Summary
kandi X-RAY | HeapView Summary
Tool to view heap chunks and memory writes (using pintool) , strongly inspired by Villoc.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Parse ltrace output
- True if the item is free
- Return the starting point of the star
- Returns the dend
- Converts a state to SVG
- Return a string representation of the given address
- Returns a list of the chunks in chunks
- Gets color
- Return an svg script
- Return SVG style
- Return SVG footer
- Return svg header
- Get the minimum address
- Get max address
HeapView Key Features
HeapView Examples and Code Snippets
Community Discussions
Trending Discussions on HeapView
QUESTION
I've been trying to ensure the strictness of an in-memory model of a Haskell program using ghc-heap-view package and the utils it provides when I noticed that my HashMap
s don't seem to be in NF upon a series on inserts. I tried printing Heap tree and indeed it shows some thunks. I then tried another way of inserting elements (using union
and singleton
) and this time it comes out strict.
Could somebody please explain why is this so and advise if there's anything I can do to make insert
behave the same way as the other method?
Here's my test code:
...ANSWER
Answered 2019-May-06 at 20:49When inserting a new, non-colliding key into a Leaf
node, insert
uses a helper function called two
to generate a two-element map. The two
function is lazy in the values of the keys, which leads to GHC creating thunks to create the two new Leaf
nodes. This whole thing is pretty silly, because the keys are actually certain to be in WHNF by then. But (presumably because of a recursive go
function) GHC doesn't realize that. The problem should be fixed in the next version of unordered-containers
.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install HeapView
You can use HeapView like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page