jycli 2004/05/26 14:33:09
Modified: java/src/org/apache/xalan/xsltc/compiler Mode.java
Stylesheet.java
Log:
If the local is set to Turkish, but the codepage is MS-DOS (US) 437. The BCEL
InstructionFinder.search(String) method can not find any instructions contain
letter I. In Turkish, there are 2 lower case i. Since the search() method is
case
insensitive, change the pattern string to use lower case.
Revision Changes Path
1.32 +4 -4
xml-xalan/java/src/org/apache/xalan/xsltc/compiler/Mode.java
Index: Mode.java
===================================================================
RCS file:
/home/cvs/xml-xalan/java/src/org/apache/xalan/xsltc/compiler/Mode.java,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- Mode.java 16 Feb 2004 22:24:29 -0000 1.31
+++ Mode.java 26 May 2004 21:33:08 -0000 1.32
@@ -1438,7 +1438,7 @@
String pattern;
// Remove seqences of ALOAD, POP (GTM)
- pattern = "`ALOAD'`POP'`Instruction'";
+ pattern = "`aload'`pop'`instruction'";
for(Iterator iter=find.search(pattern); iter.hasNext();){
InstructionHandle[] match = (InstructionHandle[])iter.next();
try {
@@ -1451,7 +1451,7 @@
}
}
// Replace sequences of ILOAD_?, ALOAD_?, SWAP with ALOAD_?, ILOAD_?
- pattern = "`ILOAD'`ALOAD'`SWAP'`Instruction'";
+ pattern = "`iload'`aload'`swap'`instruction'";
for(Iterator iter=find.search(pattern); iter.hasNext();){
InstructionHandle[] match = (InstructionHandle[])iter.next();
try {
@@ -1473,7 +1473,7 @@
}
// Replace sequences of ALOAD_1, ALOAD_1 with ALOAD_1, DUP
- pattern = "`ALOAD_1'`ALOAD_1'`Instruction'";
+ pattern = "`aload_1'`aload_1'`instruction'";
for(Iterator iter=find.search(pattern); iter.hasNext();){
InstructionHandle[] match = (InstructionHandle[])iter.next();
try {
1.61 +2 -2
xml-xalan/java/src/org/apache/xalan/xsltc/compiler/Stylesheet.java
Index: Stylesheet.java
===================================================================
RCS file:
/home/cvs/xml-xalan/java/src/org/apache/xalan/xsltc/compiler/Stylesheet.java,v
retrieving revision 1.60
retrieving revision 1.61
diff -u -r1.60 -r1.61
--- Stylesheet.java 10 Apr 2004 19:01:00 -0000 1.60
+++ Stylesheet.java 26 May 2004 21:33:08 -0000 1.61
@@ -1321,7 +1321,7 @@
* Peephole optimization: Remove sequences of [ALOAD, POP].
*/
private void peepHoleOptimization(MethodGenerator methodGen) {
- final String pattern = "`ALOAD'`POP'`Instruction'";
+ final String pattern = "`aload'`pop'`instruction'";
final InstructionList il = methodGen.getInstructionList();
final InstructionFinder find = new InstructionFinder(il);
for(Iterator iter=find.search(pattern); iter.hasNext(); ) {
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]