/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant last * source literally. If the upgrade is not possible, this does nothing. * * @see Insn#withLastSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withLastSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** * Upgrades this insn to a version that represents the constant source * literally. If the upgrade is not possible, this does nothing. * * @see Insn#withSourceLiteral */ public void upgradeToLiteral() { RegisterSpecList oldSources = insn.getSources(); insn = insn.withSourceLiteral(); getBlock().getParent().onSourcesChanged(this, oldSources); }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** {@inheritDoc} */ @Override public final void mapSourceRegisters(RegisterMapper mapper) { RegisterSpecList oldSources = insn.getSources(); RegisterSpecList newSources = mapper.map(oldSources); if (newSources != oldSources) { insn = insn.withNewRegisters(getResult(), newSources); getBlock().getParent().onSourcesChanged(this, oldSources); } }
/** * Changes one of the insn's sources. New source should be of same type * and category. * * @param index {@code >=0;} index of source to change * @param newSpec spec for new source */ public final void changeOneSource(int index, RegisterSpec newSpec) { RegisterSpecList origSources = insn.getSources(); int sz = origSources.size(); RegisterSpecList newSources = new RegisterSpecList(sz); for (int i = 0; i < sz; i++) { newSources.set(i, i == index ? newSpec : origSources.get(i)); } newSources.setImmutable(); RegisterSpec origSpec = origSources.get(index); if (origSpec.getReg() != newSpec.getReg()) { /* * If the register remains unchanged, we're only changing * the type or local var name so don't update use list */ getBlock().getParent().onSourceChanged(this, origSpec, newSpec); } insn = insn.withNewRegisters(getResult(), newSources); }
/** * Changes one of the insn's sources. New source should be of same type * and category. * * @param index {@code >=0;} index of source to change * @param newSpec spec for new source */ public final void changeOneSource(int index, RegisterSpec newSpec) { RegisterSpecList origSources = insn.getSources(); int sz = origSources.size(); RegisterSpecList newSources = new RegisterSpecList(sz); for (int i = 0; i < sz; i++) { newSources.set(i, i == index ? newSpec : origSources.get(i)); } newSources.setImmutable(); RegisterSpec origSpec = origSources.get(index); if (origSpec.getReg() != newSpec.getReg()) { /* * If the register remains unchanged, we're only changing * the type or local var name so don't update use list */ getBlock().getParent().onSourceChanged(this, origSpec, newSpec); } insn = insn.withNewRegisters(getResult(), newSources); }
/** * Changes one of the insn's sources. New source should be of same type * and category. * * @param index {@code >=0;} index of source to change * @param newSpec spec for new source */ public final void changeOneSource(int index, RegisterSpec newSpec) { RegisterSpecList origSources = insn.getSources(); int sz = origSources.size(); RegisterSpecList newSources = new RegisterSpecList(sz); for (int i = 0; i < sz; i++) { newSources.set(i, i == index ? newSpec : origSources.get(i)); } newSources.setImmutable(); RegisterSpec origSpec = origSources.get(index); if (origSpec.getReg() != newSpec.getReg()) { /* * If the register remains unchanged, we're only changing * the type or local var name so don't update use list */ getBlock().getParent().onSourceChanged(this, origSpec, newSpec); } insn = insn.withNewRegisters(getResult(), newSources); }
/** * Changes one of the insn's sources. New source should be of same type * and category. * * @param index {@code >=0;} index of source to change * @param newSpec spec for new source */ public final void changeOneSource(int index, RegisterSpec newSpec) { RegisterSpecList origSources = insn.getSources(); int sz = origSources.size(); RegisterSpecList newSources = new RegisterSpecList(sz); for (int i = 0; i < sz; i++) { newSources.set(i, i == index ? newSpec : origSources.get(i)); } newSources.setImmutable(); RegisterSpec origSpec = origSources.get(index); if (origSpec.getReg() != newSpec.getReg()) { /* * If the register remains unchanged, we're only changing * the type or local var name so don't update use list */ getBlock().getParent().onSourceChanged(this, origSpec, newSpec); } insn = insn.withNewRegisters(getResult(), newSources); }