Documentation ¶
Index ¶
- Constants
- Variables
- func CompareTwoMaps(map1 map[*StLockingOp]bool, map2 map[*StLockingOp]bool) bool
- func Detect()
- func GetLiveMutex(inputInst ssa.Instruction) map[*StLockingOp]bool
- func InitBeforeAfterMap(inputFn *ssa.Function, contextLock map[*StLockingOp]bool)
- func InitGenKillMap(inputFn *ssa.Function)
- func Initialize()
- func KillKillSet(newbefore map[*StLockingOp]bool, pUnlocking *StUnlockingOp)
- type StDoubleLock
- type StLockingOp
- type StMutex
- type StUnlockingOp
Constants ¶
View Source
const Edited = "Edited"
View Source
const M_Lock = "M_Lock"
View Source
const M_Unlock = "M_Unlock"
View Source
const MaxCallChainDepth int = 6 // Be careful: Algorithm complexity: e^n, n = C5_call_chain_layer
View Source
const MaxInspectedFun int = 100000
View Source
const RW_Lock = "RW_Lock"
View Source
const RW_RLock = "RW_RLock"
View Source
const RW_RUnlock = "RW_RUnlock"
View Source
const RW_Unlock = "RW_Unlock"
View Source
const Unknown = "Unknown"
Variables ¶
View Source
var AnalyzedFNs map[string]bool
View Source
var MapMutex map[string]*StMutex
View Source
var VecFNsWithLocking []*ssa.Function
Functions ¶
func CompareTwoMaps ¶
func CompareTwoMaps(map1 map[*StLockingOp]bool, map2 map[*StLockingOp]bool) bool
func GetLiveMutex ¶
func GetLiveMutex(inputInst ssa.Instruction) map[*StLockingOp]bool
func InitBeforeAfterMap ¶
func InitBeforeAfterMap(inputFn *ssa.Function, contextLock map[*StLockingOp]bool)
func InitGenKillMap ¶
func Initialize ¶
func Initialize()
func KillKillSet ¶
func KillKillSet(newbefore map[*StLockingOp]bool, pUnlocking *StUnlockingOp)
Types ¶
type StDoubleLock ¶
type StDoubleLock struct { PLock1 *StLockingOp PLock2 *StLockingOp }
func GenKillAnalysis ¶
func GenKillAnalysis(inputFn *ssa.Function, contextLock map[*StLockingOp]bool) []*StDoubleLock
func UnionGenSet ¶
func UnionGenSet(newbefore map[*StLockingOp]bool, pLocking *StLockingOp) *StDoubleLock
type StLockingOp ¶
type StMutex ¶
type StMutex struct { StrName string StrType string MapLockingOps map[ssa.Instruction]*StLockingOp MapUnlockingOps map[ssa.Instruction]*StUnlockingOp Pkg string // Don't use *ssa.Package here! It's not reliable StrStatus string }
type StUnlockingOp ¶
Click to show internal directories.
Click to hide internal directories.