Compute gains and losses for US taxes.