The _func_cnt member variable in class ParseAPI::Block should be atomic<int>,
authorXiaozhu Meng <xmeng@cs.wisc.edu>
Fri, 12 Apr 2019 21:13:42 +0000 (16:13 -0500)
committerXiaozhu Meng <xmeng@cs.wisc.edu>
Fri, 12 Apr 2019 21:13:42 +0000 (16:13 -0500)
commit78cb21106399fa9b336e964231f4036a2ec30ba7
tree40e31d6ebe4be135022fe2e17cb11bb7cafd83bb
parent024018d1202700e73422c184216ce99b418956d6
The _func_cnt member variable in class ParseAPI::Block should be atomic<int>,
rather than just int. A block can be shared by multiple functions. So, when
multiple functions add/remove blocks at the same time, there will be race conditions.
parseAPI/h/CFG.h
parseAPI/src/Block.C
parseAPI/src/Function.C