This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pitrou
Recipients njs, pitrou, vstinner
Date 2016-03-18.10:27:03
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <56EBD7F5.5000700@free.fr>
In-reply-to <1458273423.3.0.273373089171.issue26530@psf.upfronthosting.co.za>
Content
Le 18/03/2016 04:57, Nathaniel Smith a écrit :
> 
> What I'm talking about is different: I think it should be possible
> to
re-use the tracemalloc infrastructure to track other resources besides
"heap allocations". So for my use case, it's crucial that we index by
(domain, pointer), because the address 0xdeadbeef on the heap is
different from the address 0xdeadbeef on the GPU. We'll never want to
group by pointer alone without the domain, because that would cause us
to actually misinterpret the data (if I do PyMem_Track("gpu",
0xdeadbeef); PyMem_Untrack("heap", 0xdeadbeef), then this should not
cause tracemalloc to forget about the gpu allocation! I think this is
very different than your C backtrace example).

FWIW, LLVM calls the "domain" "address space", and simply uses an
integer for it (0 being the default CPU-addressable address space).  You
can probably restrict yourself to 8-bit address spaces...
History
Date User Action Args
2016-03-18 10:27:04pitrousetrecipients: + pitrou, vstinner, njs
2016-03-18 10:27:04pitroulinkissue26530 messages
2016-03-18 10:27:03pitroucreate