This was first committed in r317845, but had the order of branch weights wrong and didn't properly check the output. llvm-svn: 317848
Summary: This wrapper checks if there is at least one non-zero weight before setting the metadata. Reviewers: davidxl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39872 llvm-svn: 317845