/// <summary> /// Called when we need to generate an RtlBranch in the middle of an operation. /// Normally, branches are at the end of the Rtl's of a translated instruction, /// but in some cases, they are not. /// </summary> /// <param name="condition"></param> /// <param name="target"></param> /// <param name="?"></param> public void BranchInMiddleOfInstruction(Expression condition, Address target, RtlClass rtlClass) { var branch = new RtlBranch(condition, target, rtlClass); branch.NextStatementRequiresLabel = true; instrs.Add(branch); }
public bool VisitBranch(RtlBranch branch) { var branchPat = pattern as RtlBranch; if (branchPat == null) return false; matcher.Pattern = branchPat.Condition; return matcher.Match(branch.Condition); }
public bool VisitBranch(RtlBranch branch) { if (!(pattern is RtlBranch branchPat)) { return(false); } matcher.Pattern = branchPat.Condition; return(matcher.Match(branch.Condition)); }