John Kitchin <jkitc...@andrew.cmu.edu> writes: > I discovered that it matters a lot which block you cache. You have to > cache the long running block. I had put cache on the block with noweb > expansion, and then the long running block still runs every time. That > was a surprise to me, since nothing was changing in that block, so I > thought it would just use the cached result. >
Just to elaborate a bit: Org mode checks whether to reevaluate a cached block by checksumming it and seeing if the sum is different from before. That's why you have to mark the actual block for caching, not its callers. -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler