@Override
public Precision initPrecision(Location location, StateTransformer transformer) {
ExplicitPrecision p = new ExplicitPrecision(varThreshold.getValue());
// Increase precision of ecx, esi, edi for REP prefixed instructions
Program program = Program.getProgram();
if (BoundedAddressTracking.repPrecBoost.getValue()) {
AbsoluteAddress addr = location.getAddress();
X86Instruction instr = (X86Instruction)program.getInstruction(addr);
if (instr != null && (instr.hasPrefixREPZ() || instr.hasPrefixREPNZ())) {
logger.debug("boost-rep: REP instruction at " + location + ", increasing precision of loop registers.");
p.setThreshold(ExpressionFactory.createVariable("%ecx"), 1000);
p.setThreshold(ExpressionFactory.createVariable("%esi"), 1000);
p.setThreshold(ExpressionFactory.createVariable("%edi"), 1000);