[BOLT][AArch64] add lock to FixRelaxations pass
authorDenis Revunov <revunov.denis@huawei-partners.com>
Wed, 11 Jan 2023 08:38:47 +0000 (03:38 -0500)
committerDenis Revunov <revunov.denis@huawei-partners.com>
Wed, 11 Jan 2023 10:05:42 +0000 (05:05 -0500)
commitc8ff968b8497099c68c8352c8c1a794537c3a389
treef9229b1cdb97b464e0e54963e899933aca0d1a3d
parent6f00e1165776ab3abaa175d62cb634c7b3687333
[BOLT][AArch64] add lock to FixRelaxations pass

Since the pass is multithreaded, BC.Ctx must be protected. Otherwise we get crashes when processing.

Reviewed by: yota9

Differential Revision: https://reviews.llvm.org/D141465
bolt/lib/Passes/FixRelaxationPass.cpp