•memory — Memory
•memory x gives a record of what this thread holds, and of what x keeps alive. •memory 0 is the usual spelling for the counts alone.
pendingcounts the live pending arrays.bytescounts the bytes thatxkeeps alive: its items, the base of a view, the arrays that a pending array reads, and the parts of a value that∂is differentiating. An allocation thatxreaches twice is counted once.
pending counts the pending arrays that this thread made, even when another thread holds one. Because •memory reads no items, it never forces a pending array. It accepts values that ∂ is differentiating.
{+/ω×ω}∂ 1 2 3 ⍝ 2 4 6
•memory 0 ⍝ ["pending":0ₓ "bytes":0ₓ]A reshape is a view, which keeps all of its base’s items alive:
v←ι1000ₓ
m←2 500ρv
(•memory m).bytes ⍝ 2000ₓ•explain reports what happened while an expression ran.