I ran into a memory limit running TPC-H Q18 100-scale text with a 8000mb memory limit.
The query was able to complete with a much lower memory limit: 1800mb.
An initial look suggests that the join nodes temporarily reserved most or all of the blocks
Probably the conditions needed for this to happen are that other nodes have partitions large enough that they consume almost all of the available blocks just with a single partition per node pinned. If these partitions are pinned before another node gets its initial reservation, the observed behaviour could result.
The problem only occurs for specific memory limit values: increasing or decreasing the memory limit will avoid the issue in most cases.