aboutsummaryrefslogtreecommitdiffstats
path: root/weaver/testdata
diff options
context:
space:
mode:
authorjhugunin <jhugunin>2003-01-01 00:07:33 +0000
committerjhugunin <jhugunin>2003-01-01 00:07:33 +0000
commit28f09b17d4991c6754d0a2b701a6f6eb4abdbed0 (patch)
tree2b25293ee5214809508d761ff4bd75c0f4d45354 /weaver/testdata
parent9987be3397f667a639bc18165ef037853ccd330f (diff)
downloadaspectj-28f09b17d4991c6754d0a2b701a6f6eb4abdbed0.tar.gz
aspectj-28f09b17d4991c6754d0a2b701a6f6eb4abdbed0.zip
finished implementation of around inlining
Diffstat (limited to 'weaver/testdata')
-rw-r--r--weaver/testdata/AfterFancyHelloWorld.txt19
-rw-r--r--weaver/testdata/AfterThrowingFancyHelloWorld.txt19
-rw-r--r--weaver/testdata/AfterThrowingParamFancyHelloWorld.txt19
-rw-r--r--weaver/testdata/TraceJarHello.txt160
4 files changed, 95 insertions, 122 deletions
diff --git a/weaver/testdata/AfterFancyHelloWorld.txt b/weaver/testdata/AfterFancyHelloWorld.txt
index 16b04e4b1..b693040af 100644
--- a/weaver/testdata/AfterFancyHelloWorld.txt
+++ b/weaver/testdata/AfterFancyHelloWorld.txt
@@ -19,11 +19,11 @@ public abstract class FancyHelloWorld extends java.lang.Object:
method-execution(void FancyHelloWorld.main(java.lang.String[]))
| catch java.lang.Throwable -> E6
| | field-get(java.io.PrintStream java.lang.System.out)
- | | | catch java.lang.Throwable -> E3
+ | | | catch java.lang.Throwable -> E5
| | | | GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 9)
- | | | catch java.lang.Throwable -> E3
+ | | | catch java.lang.Throwable -> E5
| | | GOTO L0
- | | | E3: ASTORE 5
+ | | | E5: ASTORE 5
| | | INVOKESTATIC Aspect.ajc_after_field_get ()V
| | | ALOAD 5
| | | ATHROW
@@ -32,8 +32,8 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | | NOP
| | field-get(java.io.PrintStream java.lang.System.out)
| | ASTORE_1
- | | finally -> E5
- | | | catch java.lang.Exception -> E4
+ | | finally -> E4
+ | | | catch java.lang.Exception -> E3
| | | | ALOAD_1 // java.io.PrintStream out (line 11)
| | | | LDC "bye"
| | | | method-call(void java.io.PrintStream.println(java.lang.String))
@@ -50,8 +50,8 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | | | | NOP
| | | | method-call(void java.io.PrintStream.println(java.lang.String))
| | | | GOTO L3
- | | | catch java.lang.Exception -> E4
- | | | E4: ASTORE_2 (line 12)
+ | | | catch java.lang.Exception -> E3
+ | | | E3: ASTORE_2 (line 12)
| | | ALOAD_1 // java.io.PrintStream out (line 13)
| | | ALOAD_2 // java.lang.Exception e
| | | method-call(void java.io.PrintStream.println(java.lang.Object))
@@ -67,9 +67,9 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | | | INVOKESTATIC Aspect.ajc_after_method_call ()V
| | | | NOP
| | | method-call(void java.io.PrintStream.println(java.lang.Object))
- | | finally -> E5
+ | | finally -> E4
| | GOTO L3
- | | E5: ASTORE 4 (line 14)
+ | | E4: ASTORE 4 (line 14)
| | JSR L4
| | ALOAD 4
| | ATHROW
@@ -180,4 +180,5 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| ARETURN
method-execution(java.lang.String FancyHelloWorld.getName())
end public static String getName()
+
end public abstract class FancyHelloWorld
diff --git a/weaver/testdata/AfterThrowingFancyHelloWorld.txt b/weaver/testdata/AfterThrowingFancyHelloWorld.txt
index ed9e89bfd..3323beea6 100644
--- a/weaver/testdata/AfterThrowingFancyHelloWorld.txt
+++ b/weaver/testdata/AfterThrowingFancyHelloWorld.txt
@@ -17,19 +17,19 @@ public abstract class FancyHelloWorld extends java.lang.Object:
method-execution(void FancyHelloWorld.main(java.lang.String[]))
| catch java.lang.Throwable -> E6
| | field-get(java.io.PrintStream java.lang.System.out)
- | | | catch java.lang.Throwable -> E3
+ | | | catch java.lang.Throwable -> E5
| | | | GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 9)
- | | | catch java.lang.Throwable -> E3
+ | | | catch java.lang.Throwable -> E5
| | | GOTO L0
- | | | E3: ASTORE 5
+ | | | E5: ASTORE 5
| | | INVOKESTATIC Aspect.ajc_afterThrowing_field_get ()V
| | | ALOAD 5
| | | ATHROW
| | | L0: NOP
| | field-get(java.io.PrintStream java.lang.System.out)
| | ASTORE_1
- | | finally -> E5
- | | | catch java.lang.Exception -> E4
+ | | finally -> E4
+ | | | catch java.lang.Exception -> E3
| | | | ALOAD_1 // java.io.PrintStream out (line 11)
| | | | LDC "bye"
| | | | method-call(void java.io.PrintStream.println(java.lang.String))
@@ -44,8 +44,8 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | | | | L1: NOP
| | | | method-call(void java.io.PrintStream.println(java.lang.String))
| | | | GOTO L3
- | | | catch java.lang.Exception -> E4
- | | | E4: ASTORE_2 (line 12)
+ | | | catch java.lang.Exception -> E3
+ | | | E3: ASTORE_2 (line 12)
| | | ALOAD_1 // java.io.PrintStream out (line 13)
| | | ALOAD_2 // java.lang.Exception e
| | | method-call(void java.io.PrintStream.println(java.lang.Object))
@@ -59,9 +59,9 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | | | ATHROW
| | | | L2: NOP
| | | method-call(void java.io.PrintStream.println(java.lang.Object))
- | | finally -> E5
+ | | finally -> E4
| | GOTO L3
- | | E5: ASTORE 4 (line 14)
+ | | E4: ASTORE 4 (line 14)
| | JSR L4
| | ALOAD 4
| | ATHROW
@@ -158,4 +158,5 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| ATHROW
method-execution(java.lang.String FancyHelloWorld.getName())
end public static String getName()
+
end public abstract class FancyHelloWorld
diff --git a/weaver/testdata/AfterThrowingParamFancyHelloWorld.txt b/weaver/testdata/AfterThrowingParamFancyHelloWorld.txt
index 351d35649..0e995aaff 100644
--- a/weaver/testdata/AfterThrowingParamFancyHelloWorld.txt
+++ b/weaver/testdata/AfterThrowingParamFancyHelloWorld.txt
@@ -10,11 +10,11 @@ public abstract class FancyHelloWorld extends java.lang.Object:
public static void main(String[]):
method-execution(void FancyHelloWorld.main(java.lang.String[]))
| field-get(java.io.PrintStream java.lang.System.out)
- | | catch java.lang.Throwable -> E0
+ | | catch java.lang.Throwable -> E2
| | | GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 9)
- | | catch java.lang.Throwable -> E0
+ | | catch java.lang.Throwable -> E2
| | GOTO L0
- | | E0: ASTORE 5
+ | | E2: ASTORE 5
| | ALOAD 5
| | INVOKESTATIC Aspect.ajc_afterThrowing_field_get (Ljava/lang/Throwable;)V
| | ALOAD 5
@@ -22,24 +22,24 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| | L0: NOP
| field-get(java.io.PrintStream java.lang.System.out)
| ASTORE_1
- | finally -> E2
- | | catch java.lang.Exception -> E1
+ | finally -> E1
+ | | catch java.lang.Exception -> E0
| | | ALOAD_1 // java.io.PrintStream out (line 11)
| | | LDC "bye"
| | | method-call(void java.io.PrintStream.println(java.lang.String))
| | | | INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/String;)V
| | | method-call(void java.io.PrintStream.println(java.lang.String))
| | | GOTO L1
- | | catch java.lang.Exception -> E1
- | | E1: ASTORE_2 (line 12)
+ | | catch java.lang.Exception -> E0
+ | | E0: ASTORE_2 (line 12)
| | ALOAD_1 // java.io.PrintStream out (line 13)
| | ALOAD_2 // java.lang.Exception e
| | method-call(void java.io.PrintStream.println(java.lang.Object))
| | | INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/Object;)V
| | method-call(void java.io.PrintStream.println(java.lang.Object))
- | finally -> E2
+ | finally -> E1
| GOTO L1
- | E2: ASTORE 4 (line 14)
+ | E1: ASTORE 4 (line 14)
| JSR L2
| ALOAD 4
| ATHROW
@@ -83,4 +83,5 @@ public abstract class FancyHelloWorld extends java.lang.Object:
| ARETURN
method-execution(java.lang.String FancyHelloWorld.getName())
end public static String getName()
+
end public abstract class FancyHelloWorld
diff --git a/weaver/testdata/TraceJarHello.txt b/weaver/testdata/TraceJarHello.txt
index 6d96a9025..19fa930a5 100644
--- a/weaver/testdata/TraceJarHello.txt
+++ b/weaver/testdata/TraceJarHello.txt
@@ -66,33 +66,46 @@ public class DynamicHelloWorld extends java.lang.Object implements java.io.Seria
| ALOAD_0
| INVOKEVIRTUAL Trace.ajc$before$Trace$51 (Ljava/lang/Object;)V
| INVOKESTATIC MyTrace.aspectOf ()LMyTrace;
- | BIPUSH 3
- | ANEWARRAY java.lang.Object
- | ASTORE 6
- | ALOAD 6
- | BIPUSH 0
+ | ACONST_NULL
+ | ASTORE 13
+ | ASTORE 12
+ | LDC "Hi" (line 9)
+ | ASTORE 14
+ | GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 10)
+ | NEW java.lang.StringBuffer
+ | DUP
+ | LDC "start around: "
+ | INVOKESPECIAL java.lang.StringBuffer.<init> (Ljava/lang/String;)V
+ | ALOAD 14
+ | INVOKEVIRTUAL java.lang.StringBuffer.append (Ljava/lang/Object;)Ljava/lang/StringBuffer;
+ | INVOKEVIRTUAL java.lang.StringBuffer.toString ()Ljava/lang/String;
+ | INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/String;)V
+ | ALOAD 13 (line 11)
+ | ASTORE 18
| ALOAD_0
- | AASTORE
- | ALOAD 6
- | BIPUSH 1
| ALOAD_3
- | AASTORE
- | ALOAD 6
- | BIPUSH 2
| ALOAD 4
- | AASTORE
- | NEW DynamicHelloWorld$AjcClosure3
+ | INVOKESTATIC DynamicHelloWorld.doit_aroundBody1 (LDynamicHelloWorld;Ljava/lang/String;Ljava/util/List;)Ljava/lang/String;
+ | ASTORE 16
+ | GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 12)
+ | NEW java.lang.StringBuffer
| DUP
- | ALOAD 6
- | INVOKESPECIAL DynamicHelloWorld$AjcClosure3.<init> ([Ljava/lang/Object;)V
- | INVOKEVIRTUAL Trace.ajc$around$Trace$cc (Lorg/aspectj/runtime/internal/AroundClosure;)Ljava/lang/Object;
- | CHECKCAST java.lang.String
+ | LDC "exiting around with: "
+ | INVOKESPECIAL java.lang.StringBuffer.<init> (Ljava/lang/String;)V
+ | ALOAD 16
+ | INVOKEVIRTUAL java.lang.StringBuffer.append (Ljava/lang/Object;)Ljava/lang/StringBuffer;
+ | INVOKEVIRTUAL java.lang.StringBuffer.toString ()Ljava/lang/String;
+ | INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/String;)V
+ | ALOAD 16 (line 13)
| GOTO L0
- | L0: DUP
- | ASTORE 7
+ | L0: NOP
+ | CHECKCAST java.lang.String
+ | GOTO L1
+ | L1: DUP
+ | ASTORE 19
| INVOKESTATIC MyTrace.aspectOf ()LMyTrace;
| ALOAD_0
- | ALOAD 7
+ | ALOAD 19
| INVOKEVIRTUAL MyTrace.ajc$afterReturning$MyTrace$6e (Ljava/lang/Object;Ljava/lang/Object;)V
| ARETURN
method-execution(java.lang.String DynamicHelloWorld.doit(java.lang.String, java.util.List))
@@ -112,88 +125,45 @@ public class DynamicHelloWorld extends java.lang.Object implements java.io.Seria
ARETURN
end static final String doit_aroundBody0(DynamicHelloWorld, String, java.util.List)
- static final String doit_aroundBody2(DynamicHelloWorld, String, java.util.List):
+ static final String doit_aroundBody1(DynamicHelloWorld, String, java.util.List):
INVOKESTATIC MyTrace.aspectOf ()LMyTrace;
ALOAD_0
- BIPUSH 3
- ANEWARRAY java.lang.Object
+ ACONST_NULL
ASTORE_3
- ALOAD_3
- BIPUSH 0
- ALOAD_0
- AASTORE
- ALOAD_3
- BIPUSH 1
- ALOAD_1
- AASTORE
- ALOAD_3
- BIPUSH 2
- ALOAD_2
- AASTORE
- NEW DynamicHelloWorld$AjcClosure1
+ ASTORE 5
+ ASTORE 7
+ GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 17)
+ NEW java.lang.StringBuffer
DUP
+ LDC "start around(2): "
+ INVOKESPECIAL java.lang.StringBuffer.<init> (Ljava/lang/String;)V
+ ALOAD 5
+ INVOKEVIRTUAL java.lang.StringBuffer.append (Ljava/lang/Object;)Ljava/lang/StringBuffer;
+ INVOKEVIRTUAL java.lang.StringBuffer.toString ()Ljava/lang/String;
+ INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/String;)V
+ ALOAD 5 (line 18)
ALOAD_3
- INVOKESPECIAL DynamicHelloWorld$AjcClosure1.<init> ([Ljava/lang/Object;)V
- INVOKEVIRTUAL Trace.ajc$around$Trace$1bc (Ljava/lang/Object;Lorg/aspectj/runtime/internal/AroundClosure;)Ljava/lang/Object;
- CHECKCAST java.lang.String
- ARETURN
- end static final String doit_aroundBody2(DynamicHelloWorld, String, java.util.List)
-end public class DynamicHelloWorld
-
-public class DynamicHelloWorld$AjcClosure1 extends org.aspectj.runtime.internal.AroundClosure:
- public void <init>(Object[]):
- ALOAD_0
- ALOAD_1
- INVOKESPECIAL org.aspectj.runtime.internal.AroundClosure.<init> ([Ljava/lang/Object;)V
- RETURN
- end public void <init>(Object[])
-
- public Object run(Object[]):
- ALOAD_0
- GETFIELD org.aspectj.runtime.internal.AroundClosure.state [Ljava/lang/Object;
- ASTORE_2
- ALOAD_1
- BIPUSH 0
- AALOAD
+ ASTORE 9
+ ASTORE 11
+ ALOAD 11
CHECKCAST DynamicHelloWorld
- ALOAD_2
- BIPUSH 1
- AALOAD
- CHECKCAST java.lang.String
- ALOAD_2
- BIPUSH 2
- AALOAD
- CHECKCAST java.util.List
- INVOKESTATIC DynamicHelloWorld.doit_aroundBody0 (LDynamicHelloWorld;Ljava/lang/String;Ljava/util/List;)Ljava/lang/String;
- ARETURN
- end public Object run(Object[])
-end public class DynamicHelloWorld$AjcClosure1
-
-public class DynamicHelloWorld$AjcClosure3 extends org.aspectj.runtime.internal.AroundClosure:
- public void <init>(Object[]):
- ALOAD_0
ALOAD_1
- INVOKESPECIAL org.aspectj.runtime.internal.AroundClosure.<init> ([Ljava/lang/Object;)V
- RETURN
- end public void <init>(Object[])
-
- public Object run(Object[]):
- ALOAD_0
- GETFIELD org.aspectj.runtime.internal.AroundClosure.state [Ljava/lang/Object;
- ASTORE_2
- ALOAD_2
- BIPUSH 0
- AALOAD
- CHECKCAST DynamicHelloWorld
ALOAD_2
- BIPUSH 1
- AALOAD
+ INVOKESTATIC DynamicHelloWorld.doit_aroundBody0 (LDynamicHelloWorld;Ljava/lang/String;Ljava/util/List;)Ljava/lang/String;
+ ASTORE 13
+ GETSTATIC java.lang.System.out Ljava/io/PrintStream; (line 19)
+ NEW java.lang.StringBuffer
+ DUP
+ LDC "exiting around with(2): "
+ INVOKESPECIAL java.lang.StringBuffer.<init> (Ljava/lang/String;)V
+ ALOAD 13
+ INVOKEVIRTUAL java.lang.StringBuffer.append (Ljava/lang/Object;)Ljava/lang/StringBuffer;
+ INVOKEVIRTUAL java.lang.StringBuffer.toString ()Ljava/lang/String;
+ INVOKEVIRTUAL java.io.PrintStream.println (Ljava/lang/String;)V
+ ALOAD 13 (line 20)
+ GOTO L0
+ L0: NOP
CHECKCAST java.lang.String
- ALOAD_2
- BIPUSH 2
- AALOAD
- CHECKCAST java.util.List
- INVOKESTATIC DynamicHelloWorld.doit_aroundBody2 (LDynamicHelloWorld;Ljava/lang/String;Ljava/util/List;)Ljava/lang/String;
ARETURN
- end public Object run(Object[])
-end public class DynamicHelloWorld$AjcClosure3
+ end static final String doit_aroundBody1(DynamicHelloWorld, String, java.util.List)
+end public class DynamicHelloWorld