Various stuff for benchmark and plotting