Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion SpecsUtils/src/pt/up/fe/specs/util/DotRenderFormat.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ public String getFlag() {
/**
* Gets the file extension associated with the rendering format.
* <p>
* The extension is used for naming output files generated by graph rendering utilities.
* The extension is used for naming output files generated by graph rendering
* utilities.
* </p>
*
* @return the file extension for the rendering format
Expand Down
4 changes: 1 addition & 3 deletions SpecsUtils/src/pt/up/fe/specs/util/ExtensionFilter.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ public ExtensionFilter(String extension) {

public ExtensionFilter(String extension, boolean followSymlinks) {
this.extension = extension;
// this.separator = SpecsIo.DEFAULT_EXTENSION_SEPARATOR;
this.separator = ".";
this.followSymlinks = followSymlinks;
}
Expand All @@ -62,5 +61,4 @@ public boolean accept(File dir, String name) {

return name.toLowerCase().endsWith(suffix);
}

}
}
422 changes: 222 additions & 200 deletions SpecsUtils/src/pt/up/fe/specs/util/Preconditions.java

Large diffs are not rendered by default.

32 changes: 20 additions & 12 deletions SpecsUtils/src/pt/up/fe/specs/util/SpecsAsm.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
/**
* Utility methods for assembly code operations.
* <p>
* Provides static helper methods for parsing, formatting, and manipulating assembly code.
* Provides static helper methods for parsing, formatting, and manipulating
* assembly code.
* </p>
*
* @author Joao Bispo
Expand All @@ -30,7 +31,7 @@ public class SpecsAsm {
*
* @param input1 the first operand
* @param input2 the second operand
* @param carry the carry value (0 or 1)
* @param carry the carry value (0 or 1)
* @return the result of the addition
*/
public static long add64(long input1, long input2, long carry) {
Expand All @@ -42,19 +43,20 @@ public static long add64(long input1, long input2, long carry) {
*
* @param input1 the first operand
* @param input2 the second operand
* @param carry the carry value (0 or 1)
* @param carry the carry value (0 or 1)
* @return the result of the reverse subtraction
*/
public static long rsub64(long input1, long input2, long carry) {
return input2 + ~input1 + carry;
}

/**
* Calculates the carryOut of the sum of rA with rB and carry. Operation is rA + rB + carry.
* Calculates the carryOut of the sum of rA with rB and carry. Operation is rA +
* rB + carry.
*
* @param input1 the first operand
* @param input2 the second operand
* @param carry the carry from the previous operation. Should be 0 or 1.
* @param carry the carry from the previous operation. Should be 0 or 1.
* @return an ArithmeticResult32 containing the result and carry out
*/
public static ArithmeticResult32 add32(int input1, int input2, int carry) {
Expand All @@ -79,11 +81,12 @@ public static ArithmeticResult32 add32(int input1, int input2, int carry) {
}

/**
* Calculates the carryOut of the reverse subtraction of rA with rB and carry. Operation is rB + ~rA + carry.
* Calculates the carryOut of the reverse subtraction of rA with rB and carry.
* Operation is rB + ~rA + carry.
*
* @param input1 the first operand
* @param input2 the second operand
* @param carry the carry from the previous operation. Should be 0 or 1.
* @param carry the carry from the previous operation. Should be 0 or 1.
* @return an ArithmeticResult32 containing the result and carry out
*/
public static ArithmeticResult32 rsub32(int input1, int input2, int carry) {
Expand Down Expand Up @@ -162,7 +165,8 @@ public static int xor32(int input1, int input2) {
}

/**
* Compares two signed 32-bit integers and modifies the MSB to reflect the relation.
* Compares two signed 32-bit integers and modifies the MSB to reflect the
* relation.
*
* @param input1 the first operand
* @param input2 the second operand
Expand All @@ -180,7 +184,8 @@ public static int mbCompareSigned(int input1, int input2) {
}

/**
* Compares two unsigned 32-bit integers and modifies the MSB to reflect the relation.
* Compares two unsigned 32-bit integers and modifies the MSB to reflect the
* relation.
*
* @param input1 the first operand
* @param input2 the second operand
Expand Down Expand Up @@ -232,7 +237,8 @@ public static int shiftRightLogical(int input1, int input2) {
}

/**
* Performs a logical left shift on a 32-bit integer, taking into account a mask.
* Performs a logical left shift on a 32-bit integer, taking into account a
* mask.
*
* @param input1 the operand to shift
* @param input2 the number of positions to shift
Expand All @@ -245,7 +251,8 @@ public static int shiftLeftLogical(int input1, int input2, int input3) {
}

/**
* Performs an arithmetic right shift on a 32-bit integer, taking into account a mask.
* Performs an arithmetic right shift on a 32-bit integer, taking into account a
* mask.
*
* @param input1 the operand to shift
* @param input2 the number of positions to shift
Expand All @@ -258,7 +265,8 @@ public static int shiftRightArithmetical(int input1, int input2, int input3) {
}

/**
* Performs a logical right shift on a 32-bit integer, taking into account a mask.
* Performs a logical right shift on a 32-bit integer, taking into account a
* mask.
*
* @param input1 the operand to shift
* @param input2 the number of positions to shift
Expand Down
Loading
Loading