Do you know about automatic differentiation and / or Enzyme? Could you help sketch out how AD support for @numba_jit could be implemented? Issue / thread: https://t.co/jISDyxtEfW
I've been on Mastodon a while but I got out of the habit of using it - this is my account that I'm starting to get active with again: https://t.co/8Qcrn8yLDs (is this usually written as @[email protected]?). It has an old profile pic, still need to upload my current one.
@jonathandotcel @anthonypjshaw Yeah, the CPython Internals book is great for this, and I think there's a few blog posts on https://t.co/WJ7BjkyMra that cover some of the same / similar material too
I've been experimenting with using CUDA Unified Memory for the Python heap, towards a general goal of experimenting with a more unified CPU / GPU execution model within CPython, implemented as PyMemAllocatorEx instances. I have a few thoughts so far...
@apmasell If you optimise for size (-Os) I would imagine you have the best chance of that happening. I'm sure I've been aware of examples of that sort of thing but need to do a bit of digging.
@apmasell Maybe answering my own question, but it seems that constants in a constant pool have their own label in the asm source, so perhaps not part of the function. e.g. for 0x5f3759df in https://t.co/TtUGvTIPiI
@apmasell Years ago I recall trying to infer the size of functions, and I was working with elf files, working it out by looking for the following symbol. I maybe was an idiot and unaware of the size entry! How does it consider constant pools located near functions? Are they part of it?
@jonathandotcel @anthonypjshaw tutorial in the official docs suggests (https://t.co/D7lbOmDuJb)... Though things might have been different if I'd been working in a different domain - I've not really used Python to implement a server app or anything like that, mainly compiler toolchain support / compiler work
@jonathandotcel @anthonypjshaw From a language user standpoint, I don't feel it's been that important to understand the internals of CPython - before I started working on Numba I think I was pretty happy just knowing the basics of the GIL (basically only one thread executing Python code) and what the...
@vellamike @anthonypjshaw Whoops, totally forgot to link to https://t.co/rg9Vsykb9U earlier - basically it's memory that can be accessed from CPU and GPU and migrated transparently between devices and host as required
@anthonypjshaw 6. Finally, maybe this should have been a blog post with some code! Would that be interesting? What else should be answered / elaborated on if I write this up?
5. "CPython Internals" by @anthonypjshaw is a great intro / reference to CPython, saved me a lot of time, and got me up to speed quickly for this endeavour. Highly recommended if you want to poke about with this sort of stuff! (https://t.co/VmTiicnfYY)