You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by lu...@apache.org on 2012/10/02 11:36:44 UTC
svn commit: r1392814 -
/commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java
Author: luc
Date: Tue Oct 2 09:36:43 2012
New Revision: 1392814
URL: http://svn.apache.org/viewvc?rev=1392814&view=rev
Log:
Removed getTmp as no transformations need temporary variables anymore.
Modified:
commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java
Modified: commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java
URL: http://svn.apache.org/viewvc/commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java?rev=1392814&r1=1392813&r2=1392814&view=diff
==============================================================================
--- commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java (original)
+++ commons/sandbox/nabla/trunk/src/main/java/org/apache/commons/nabla/forward/analysis/MethodDifferentiator.java Tue Oct 2 09:36:43 2012
@@ -616,36 +616,6 @@ public class MethodDifferentiator {
}
}
- /** Get index of a size 2 temporary variable.
- * <p>Temporary variables can be used for very short duration
- * storage of size 2 values (i.e one double, or one long or two
- * integers). These variables are reused in many replacement
- * instructions sequences, so their content may be overridden
- * at any time: they should be considered to have a scope
- * limited to one replacement sequence only. This means that
- * one should <em>not</em> store a value in a variable in one
- * replacement sequence and retrieve it later in another
- * replacement sequence as it may have been overridden in
- * between.</p>
- * <p>At most 5 temporary variables may be used.</p>
- * @param number number of the temporary variable (must be
- * between 1 and the maximal number of available temporary
- * variables)
- * @return index of the variable within the local variables
- * array
- * @exception DifferentiationException if the number of the
- * temporary variable lies outside of the allowed range
- */
- public int getTmp(final int number) throws DifferentiationException {
- if ((number < 0) || (number > MAX_TEMP)) {
- throw new DifferentiationException(NablaMessages.NUMBER_OF_TEMPORARY_VARIABLES_OUT_OF_RANGE,
- number, 1, MAX_TEMP);
- }
- final int index = usedLocals.length - 2 * number;
- useLocal(index, 2);
- return index;
- }
-
/** Shifted the index of a variable instruction.
* @param insn variable instruction
*/