summaryrefslogtreecommitdiffstats
path: root/contrib/llvm/lib/Transforms/Utils/Mem2Reg.cpp
diff options
context:
space:
mode:
authorkib <kib@FreeBSD.org>2014-11-30 20:20:55 +0000
committerkib <kib@FreeBSD.org>2014-11-30 20:20:55 +0000
commita114aae162a53321a50e9aa506108ff70a3771b3 (patch)
tree38d56553963a354ec01039d3e7a705888eb70ec3 /contrib/llvm/lib/Transforms/Utils/Mem2Reg.cpp
parent12b8cb671b4be8a6160f57b8a2953b27484bb520 (diff)
downloadFreeBSD-src-a114aae162a53321a50e9aa506108ff70a3771b3.zip
FreeBSD-src-a114aae162a53321a50e9aa506108ff70a3771b3.tar.gz
Provide mutual exclusion between zone allocation/destruction and
uma_reclaim(). Reclamation code must not see half-constructed or destructed zones. Do this by bracing uma_zcreate() and uma_zdestroy() into a shared-locked sx, and take the sx exclusively in uma_reclaim(). Usually zones are not created/destroyed during the system operation, but tmpfs mounts do cause zone operations and exposed the bug. Another solution could be to only expose a new keg on uma_kegs list after the corresponding zone is fully constructed, and similar treatment for the destruction. But it probably requires more risky code rearrangement as well. Reported and tested by: pho Discussed with: avg Sponsored by: The FreeBSD Foundation MFC after: 2 weeks
Diffstat (limited to 'contrib/llvm/lib/Transforms/Utils/Mem2Reg.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud