[llvm] Use branch weight metadata in some cases. (#16668)
commitdb626fe9d370fb1f431667ae31a370b70275ef2b
authorZoltan Varga <vargaz@gmail.com>
Wed, 4 Sep 2019 22:17:07 +0000 (4 18:17 -0400)
committerGitHub <noreply@github.com>
Wed, 4 Sep 2019 22:17:07 +0000 (4 18:17 -0400)
treed9efc1c26d2e435bc6e36335937fde66daa709d0
parentc0a36b62af155be84c5dd11e3d88c3dd1cba12b2
[llvm] Use branch weight metadata in some cases. (#16668)

* [llvm] Add functions to create weighted branches.

* [llvm] Use weighted branches in GC_SAFE_POINT, some llvm passes doesn't seem to recognize llvm.expect so the LLVM JIT generates the slow inline.
mono/mini/mini-llvm-cpp.cpp
mono/mini/mini-llvm-cpp.h
mono/mini/mini-llvm.c