public string ToStringConstraints(string identStr) { StringBuilder sb = new StringBuilder(); if (this.Solver.NumAssertions > 0) { sb.AppendLine(identStr + "Current Value constraints:"); for (int i = 0; i < (int)this.Solver.NumAssertions; ++i) { BoolExpr e = this.Solver.Assertions[i]; sb.AppendLine(identStr + string.Format(" {0}: {1}", i, ToolsZ3.ToString(e))); } } if (this.Tools.ShowUndefConstraints) { //if (this.Solver_U.NumAssertions > 0) { sb.AppendLine(identStr + "Current Undef constraints:"); for (int i = 0; i < (int)this.Solver_U.NumAssertions; ++i) { BoolExpr e = this.Solver_U.Assertions[i]; sb.AppendLine(identStr + string.Format(" {0}: {1}", i, ToolsZ3.ToString(e))); } } } sb.AppendLine(this.BranchInfoStore.ToString()); sb.Append("TailKey=" + this.TailKey + "; HeadKey=" + this.HeadKey); return(sb.ToString()); }
public string ToString2() { StringBuilder sb = new StringBuilder(); foreach (Flags flag in this._tools.StateConfig.GetFlagOn()) { BoolExpr b = this.Get_Raw_Private(flag, true); if (b != null) { sb.AppendLine(flag + ": " + ToolsZ3.ToString(b)); } } foreach (Rn reg in this._tools.StateConfig.GetRegOn()) { BoolExpr b = this.Get_Raw_Private(reg, true); if (b != null) { sb.AppendLine(reg + ": " + ToolsZ3.ToString(b)); } } if (this._branchInfo != null) { sb.AppendLine(this._branchInfo.ToString()); } return(sb.ToString()); }
public override string ToString() { StringBuilder sb = new StringBuilder("StateUpdate: PrevKey=" + this._prevKey_Regular + "; NextKey=" + this.NextKey + " "); if (this.Empty) { sb.AppendLine("Empty UpdateState"); } if (this.Reset) { sb.AppendLine("Reset UpdateState"); } foreach (Flags flag in this._tools.StateConfig.GetFlagOn()) { BoolExpr b = this.Get_Raw_Private(flag, true); if (b != null) { sb.AppendLine(flag + ": " + ToolsZ3.ToString(b)); } } foreach (Rn reg in this._tools.StateConfig.GetRegOn()) { BoolExpr b = this.Get_Raw_Private(reg, true); if (b != null) { sb.AppendLine(reg + ": " + ToolsZ3.ToString(b)); } } if (this._branchInfo != null) { sb.AppendLine(this._branchInfo.ToString()); } return(sb.ToString()); }
private string ToString(Solver solver) { StringBuilder sb = new StringBuilder(); sb.AppendLine("solver:"); foreach (BoolExpr e in solver.Assertions) { sb.AppendLine(ToolsZ3.ToString(e)); } return(sb.ToString()); }
public override string ToString() { StringBuilder sb = new StringBuilder(); if ((this._branchInfo != null) && (this._branchInfo.Count > 0)) { sb.AppendLine("Branch control flow constraints:"); int i = 0; foreach (KeyValuePair <string, BranchInfo> entry in this._branchInfo) { BoolExpr e = entry.Value.GetData(this._ctx); sb.AppendLine(string.Format(" {0}: {1}", i, ToolsZ3.ToString(e))); i++; } } return(sb.ToString()); }