Write a function to compute the trivially retained size of a function
trivially_retained(node):
queue = [node]
owned = {node}
for n in queue:
for c in n.children:
if (c.parents are all contained in owned) and (c is not in owned):
owned.add(c)
queue.add(c)
Write a function to compute the trivially retained size of a function