the map is keyed by register, and value by when an assumption holds to a byte
offset if we have passed when the assumption holds, clear the item from the
map

@param assumptionTill the map of assumptions
@param pc             // * the current pc
770628
public static void clearAssumptions(Map<Integer, Integer> assumptionTill, int pc) {
        Iterator<Integer> it = assumptionTill.values().iterator();
        while (it.hasNext()) {
            if (it.next().intValue() <= pc) {
                it.remove();
            }
        }
    }
1348022
private GinjectorBindings computeInitialPosition(Key<?> key) {
    GinjectorBindings initialPosition = output.getGraph().getOrigin();
    boolean pinned = initialPosition.isPinned(key);

    // If the key is pinned (explicitly bound) at the origin, we may be in a situation where we need
    // to install a binding at the origin, even though we should *use* the binding form a higher
    // location.
    // If key is already bound in parent, there is a reason that {@link DependencyExplorer}
    // chose not to use that binding.  Specifically, it implies that the key is exposed to the
    // parent from the origin.  While we are fine using the higher binding, it is still necessary
    // to install the binding in the origin.
    if (pinned) {
      PrettyPrinter.log(logger, TreeLogger.DEBUG,
          PrettyPrinter.format("Forcing %s to be installed in %s due to a pin.", key,
              initialPosition));
      installOverrides.put(key, initialPosition);
    }

    while (canExposeKeyFrom(key, initialPosition, pinned)) {
      PrettyPrinter.log(logger, TreeLogger.SPAM,
          "Moving the highest visible position of %s from %s to %s.", key, initialPosition,
          initialPosition.getParent());
      initialPosition = initialPosition.getParent();
    }
    return initialPosition;
  }
108839
protected final PrcAccSettingsLineSave lazyGetPrcAccSettingsLineSave(
    final Map<String, Object> pAddParam) throws Exception {
    @SuppressWarnings("unchecked")
    PrcAccSettingsLineSave<RS, IHasId<Long>> proc =
      (PrcAccSettingsLineSave<RS, IHasId<Long>>) this.processorsMap
        .get(PrcAccSettingsLineSave.class.getSimpleName());
    if (proc == null) {
      proc = new PrcAccSettingsLineSave<RS, IHasId<Long>>();
      proc.setSrvAccSettings(getSrvAccSettings());
      @SuppressWarnings("unchecked")
      PrcEntityFolSave<RS, IHasId<Long>, Long> procDlg =
        (PrcEntityFolSave<RS, IHasId<Long>, Long>) this.fctBnEntitiesProcessors
          .lazyGet(pAddParam, PrcEntityFolSave.class.getSimpleName());
      proc.setPrcEntityFolSave(procDlg);
      //assigning fully initialized object:
      this.processorsMap
        .put(PrcAccSettingsLineSave.class.getSimpleName(), proc);
    }
    return proc;
  }
490317
public void removeByKey(Object key)
    {
        Object value = keyTable.remove(key);
        if (value != null)
        {
            valueTable.remove(value);
        }
    }
674177
@Override
	public void cacheResult(
		List<CPDefinitionSpecificationOptionValue> cpDefinitionSpecificationOptionValues) {
		for (CPDefinitionSpecificationOptionValue cpDefinitionSpecificationOptionValue : cpDefinitionSpecificationOptionValues) {
			if (entityCache.getResult(
						CPDefinitionSpecificationOptionValueModelImpl.ENTITY_CACHE_ENABLED,
						CPDefinitionSpecificationOptionValueImpl.class,
						cpDefinitionSpecificationOptionValue.getPrimaryKey()) == null) {
				cacheResult(cpDefinitionSpecificationOptionValue);
			}
			else {
				cpDefinitionSpecificationOptionValue.resetOriginalValues();
			}
		}
	}
781203
protected void assume(final int decision) {
        assert propagated();
        this.level++;
        final int height = this.trail.size();
        this.control.push(new CLFrame(decision, this.level, height));
        assert this.level + 1 == this.control.size();
        assign(decision, null);
    }
230952
public void clearPolicy() {
        if (model.containsKey("p")) {
            for (Assertion ast : model.get("p").values()) {
                ast.policy = new ArrayList<>();
            }
        }

        if (model.containsKey("g")) {
            for (Assertion ast : model.get("g").values()) {
                ast.policy = new ArrayList<>();
            }
        }
    }
942288
def resolve_operands(self, encoding_map, operation, pc):
        
        convert = Encoder.to_binary
        branch_replace = False
        jump_replace = False

        for operand, value in encoding_map.iteritems():
            if (operand == 'rs' or operand == 'rt' or operand == 'rd'):
                encoding_map[operand] = MIPS.registers[value]

            elif (operand == 'imm'):
                encoding_map[operand] = convert(int(value), MIPS.IMMEDIATE_SIZE)

            elif (operand == 'addr'):
                encoding_map[operand] = convert(int(value), MIPS.ADDRESS_SIZE)

            elif (operand == 'shamt'):
                encoding_map[operand] = convert(int(value), MIPS.SHAMT_SIZE)

            elif (operand == 'label'):
                label = encoding_map[operand]
                hit, index = self.label_cache.query(label)

                if not hit:
                    raise RuntimeError('No address found for label: {}'.format(label))

                if ((operation == 'beq') or (operation == 'bne')):
                    # Calculate the relative instruction offset. The MIPS ISA uses
                    # PC + 4 + (branch offset) to resolve branch targets.
                    if index > pc:
                        encoding_map[operand] = convert(index - pc - 1, MIPS.IMMEDIATE_SIZE)
                    elif index < pc:
                        encoding_map[operand] = convert((pc + 1) - index, MIPS.IMMEDIATE_SIZE)
                    else:
                        # Not sure why a branch would resolve to itself, but ok
                        # (PC + 4) - 4 = 
                        encoding_map[operand] = convert(-1, MIPS.IMMEDIATE_SIZE)

                    branch_replace = True

                elif ((operation == 'j') or (operation == 'jal')):
                    # Jump addresses are absolute
                    encoding_map[operand] = convert(index, MIPS.ADDRESS_SIZE)
                    jump_replace = True

        # Need to convert references to 'label' back to references the instruction
        # encoding string recognizes, otherwise we end up with the default value (zero)
        # This doesn't feel very clean, but working on a fix.
        if branch_replace:
            encoding_map['imm'] = encoding_map['label']
        elif jump_replace:
            encoding_map['addr'] = encoding_map['label']
1263869
static void removeFromCache(String key) {
        HashMap<String, MPApiResponse> mapCache = getMapCache();
        mapCache.remove(key);
    }
232139
public void closeTx() {

        //Clear Collection Caches
        modifiedThings.clear();
        modifiedRoles.clear();
        modifiedRelationTypes.clear();
        modifiedRules.clear();
        modifiedCastings.clear();
        newAttributes.clear();
        newRelations.clear();
        shardingCount.clear();
        conceptCache.clear();
        schemaConceptCache.clear();
        labelCache.clear();
    }
248219
public void clearCache(CacheInvocationContext<CacheRemove> context) {
        HystrixCacheKeyGenerator defaultCacheKeyGenerator = HystrixCacheKeyGenerator.getInstance();
        String cacheName = context.getCacheAnnotation().commandKey();
        HystrixGeneratedCacheKey hystrixGeneratedCacheKey =
                defaultCacheKeyGenerator.generateCacheKey(context);
        String key = hystrixGeneratedCacheKey.getCacheKey();
        HystrixRequestCache.getInstance(HystrixCommandKey.Factory.asKey(cacheName),
                HystrixConcurrencyStrategyDefault.getInstance()).clear(key);
    }
326647
protected void accountForFetchedKey(byte[] key) {
        fetched++;
        if (streamStats != null) {
            streamStats.reportStreamingFetch(operation);
        }

        if (recordsPerPartition <= 0) {
            return;
        }

        Integer keyPartitionId = getKeyPartitionId(key);
        Long partitionFetch = partitionFetches.get(keyPartitionId);
        Utils.notNull(partitionFetch);
        partitionFetch++;

        partitionFetches.put(keyPartitionId, partitionFetch);
        if (partitionFetch == recordsPerPartition) {
            if (partitionsToFetch.contains(keyPartitionId)) {
                partitionsToFetch.remove(keyPartitionId);
            } else {
                logger.warn("Partitions to fetch did not contain expected partition ID: "
                        + keyPartitionId);
            }
        } else if (partitionFetch > recordsPerPartition) {
            logger.warn("Partition fetch count larger than expected for partition ID "
                    + keyPartitionId + " : " + partitionFetch);
        }
    }
752934
@Override
	public void clearCache() {
		entityCache.clearCache(CPDefinitionLocalizationImpl.class);

		finderCache.clearCache(FINDER_CLASS_NAME_ENTITY);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
	}
466481
@ConditionalOnClass({Pcap.class, Inet4Address.class, Context.class})
    //@ConditionalOnBean({Pcap.Builder.class, Inet4Address.class})
    @Bean(CONTEXT_BEAN_NAME)
    public Context context(@Qualifier(PCAP_BUILDER_BEAN_NAME) Pcap.Builder builder,
                           @Qualifier(NETMASK_BEAN_NAME) Inet4Address netmask) {

        switch (properties.getPcapType()) {
            case DEAD:
                if (LOGGER.isDebugEnabled()) {
                    LOGGER.debug("Opening pcap dead handler : {}", builder);
                }
                builder.pcapType(Pcap.PcapType.DEAD);
                break;
            case OFFLINE:
                if (LOGGER.isDebugEnabled()) {
                    LOGGER.debug("Opening pcap offline hadler : {}", builder);
                }
                builder.pcapType(Pcap.PcapType.OFFLINE);
                break;
            default:
                if (LOGGER.isDebugEnabled()) {
                    LOGGER.debug("Opening pcap live hadler : {}", builder);
                }
                builder.pcapType(Pcap.PcapType.LIVE);
                break;
        }
        Application.run(applicationName, applicationDisplayName, applicationVersion, builder);
        Context context =  Application.getApplicationContext();
        if (properties.getFilter() != null) {
            if (context.pcapCompile(properties.getFilter(),
                    properties.getBpfCompileMode(),
                    netmask.toInt()) == PcapCode.PCAP_OK) {
                if (context.pcapSetFilter() != PcapCode.PCAP_OK) {
                    if (LOGGER.isWarnEnabled()) {
                        LOGGER.warn(context.pcapGetErr());
                    }
                } else {
                    LOGGER.debug("Filter \'{}\' has been applied.", this.properties.getFilter());
                }
            } else {
                if (LOGGER.isWarnEnabled()) {
                    LOGGER.warn(context.pcapGetErr());
                }
            }
        } else {
            if (LOGGER.isDebugEnabled()) {
                LOGGER.debug("No filter has been applied.");
            }
        }
        return context;
    }
912163
public static <K, V> void clear(Map<K, V> map) {
        if (map != null) {
            map.clear();
        }
    }
694406
public void clearBranchTargets(int pc) {
        Iterator<Integer> it = branchTargets.iterator();
        while (it.hasNext()) {
            int target = it.next().intValue();
            if (target <= pc) {
                it.remove();
            }
        }
    }
1299385
public void putAll(Map<KEY, VALUE> mapDataToPut) {
        int targetSize = maxSize - mapDataToPut.size();
        if (maxSize > 0 && values.size() > targetSize) {
            evictToTargetSize(targetSize);
        }
        Set<Entry<KEY, VALUE>> entries = mapDataToPut.entrySet();
        for (Entry<KEY, VALUE> entry : entries) {
            put(entry.getKey(), entry.getValue());
        }
    }