Advice Weaving in ÉNFASIS

Size: px
Start display at page:

Download "Advice Weaving in ÉNFASIS"

Transcription

1 2010 Electronics, Robotics and Automotive Mechanics Conference Advice Weaving in ÉNFASIS Ulises Juárez-Martínez Division of Research and Postgraduate Studies Instituto Tecnológico de Orizaba 94320, Veracruz, México Giner Alor-Hernández Division of Research and Postgraduate Studies Instituto Tecnológico de Orizaba 94320, Veracruz, México Abstract This paper describes the implementation of advice weaving in ÉNFASIS. Énfasis is a domain-specific framework designed to program fine-grained aspects and apply crosscutting on local variables. Applications of fine-grained aspects include data flow analysis, program comprehension, assertions, code coverage, among others. The ÉNFASIS framework uses bytecode instrumentation to weave statically pieces of advice. We describe how ÉNFASIS join points are mapped to specific regions of bytecode, how to implement advice, and how to expose the pointcut context without using arguments between pointcuts and pieces of advice, a novel capability in our framework not available in AspectJ-like languages. Keywords-aspect-orientation, bytecode, compilers, Énfasis, local variable crosscutting, weaving I. INTRODUCTION Aspect-Oriented Programming [1] is a paradigm that allows concerns (system attributes) modularization. Concerns like persistence, performance, logging, and concurrency require some class or instance members to perform its function. Likewise, concerns such as testing, tracing, program comprehension, program visualization, assertions, monitoring, and complexity require finer elements of a program, specifically local variables. The last concerns are not supported by AspectJ-like languages and some approaches address this problem [2], [3], [4], [5], and some authors justify fine granularity from a broader perspective [6], [7], [8], [9], even new join point models [10], [11]. ÉNFASIS [12] is a Java framework for defining finegrained aspects. The framework supports static and dynamic crosscutting. The static crosscutting allows to change the class structure to add new members, including constructors. The dynamic crosscutting changes the behavior of applications and it is used to quantify local variables. ÉNFASIS introduces path expressions, a novel concept to identify local variables in specific parts of a method. In this paper we describe the advice mechanism implemented by ÉNFASIS for ensuring that both code of classes and aspects work in a coordinated way. The paper covers only bytecode instrumentation for implementing advice and pointcut context. The locus in ÉNFASIS are local variable shadows, which are requered elements to identify join points. Additional details and applications can be found in [13], [12], [14], [15]. II. ÉNFASIS IN A NUTSHELL A HelloWorld example is suitable to be able to introduce quickly most of the concepts that ÉNFASIS provides and discuss the implications that are behind of bytecode instrumentation as part of weaving process. The HelloWorld class is the following one: public class HelloWorld { public static void main (String[] args) { double d = Math.random(); System.out.println(d); } } A possible exit of the program execution could be: In this example, local variable d is available in the whole body of the method main(). Let s consider local variable monitoring concern where we need to be able to show a message before printing its value. The message will be composed by a string and the same value of the variable. The aspect for this purpose is shown next. 1 public aspect HelloWorldEnfasis { 2 pointcut p(): getlocal (void 3 HelloWorld.main( 4 String[])/double d); 5 before(): p() { 6 System.out.println("Local 7 variable: " + d); } } As we can see, ÉNFASIS uses an AspectJ-like syntax and the pointcut primitive is getlocal. Local variable quantification is associated with method signatures (getlocal argument, lines 2 to 4). The slash indicates the local variable scope, in this case, its location within all method body. Advice code can use fields and variables available at the join point interception. The advice uses local variables without specify any arguments to expose the context. This is legal in ÉNFASIS and it is a novel capability in our framework not available in AspectJ-like languages. In some cases, thisjoinpoint reflexive variable is avoided. The weaving process modifies the bytecode changing the program behaviour. A possible exit could be: /10 $ IEEE DOI /CERMA

2 Local variable: III. HELLOWORLD BYTECODE Local variable join points are associated with events smaller than a sentence, thus it is not possible to quantify using source code, in this case we need to know the details behind of bytecode. The following fragment of bytecode shows the original method main() for HelloWorld and the local variable table (LVT). public static void main(string[]); Stack=3, Locals=3, Args_size=1 0: invokestatic [Math.random:()D] 3: dstore_1 7: dload_1 8: invokevirtual [PrintStream.println:(D)V] 11: return LocalVariableTable: Start Length Slot Name Signature args [String; d D After weaving, ÉNFASIS changes the bytecode as follows. public static void main(string[]); Stack=5, Locals=3, Args_size=1 0: invokestatic [Math.random:()D] 3: dstore_1 7: getstatic [System.out:PrintStream;] 10: new [StringBuffer] 13: dup 14: invokespecial [StringBuffer."<init>":()V] 17: ldc ["Advising a local variable!"] 19: invokevirtual [StringBuffer.append: (String;)StringBuffer;] 22: dload_1 23: invokevirtual [StringBuffer.append: (D)StringBuffer;] 26: invokevirtual [StringBuffer.toString: ()String;] 29: invokevirtual [PrintStream.println: (String;)V] 32: dload_1 33: invokevirtual [PrintStream.println:(D)V] 36: return LocalVariableTable: Start Length Slot Name Signature args [String; d D Addresses 0, 3 and 4 are the same from the original bytecode. Addresses 4, 32, and 33, were generated by the original sentence System.out.println(d);. Now they are separated by another set of instructions (addresses 7 to 29) which were inserted by the aspect. Finally, addresses Type Shadow getlocal aload, dload, fload, iload, lload setlocal astore, dstore, fstore, istore, lstore, iinc Table I STATIC SHADOWS FOR LOCAL VARIABLES. 32 to 36 are the original instructions of class HelloWorld. Note that addresses 4 and 7 are two consecutive invocations to place the same field System.out in the stack, which will never be generated by traditional compilation of Java. IV. LOCAL VARIABLE SHADOWS The weaving mechanism in ÉNFASIS uses static shadows for local variables, which are represented by two families of instructions called load and store. load instructions allow to place a local variable in the operand stack whereas store instructions store operands in a local variable. The set of shadows are shown in table I. Each group of instructions is preceded by a letter that represents a primitive data type or a reference: a is an object reference. d is a double value. f is a float value. i represents a primitive data type: boolean, byte, short and int. l is a long value. And each instruction can appear in two variants: xload_<n> and xload <n>. xstore_<n> and xstore <n>. where n is an index in the local variable array, the bottom dash ( ) is used for indexes from 0 to 4, whose operand is implicit and x is someone of the letters that represent the data type of the variable. Also, it is considered the instruction iinc that increments a constant value for a local variable. This instruction modifies directly the value of the variable in the stack, thus the static shadow identified represents only an assignment operation (setlocal). The wide instruction modifies the behavior of another instruction to allow reading additional bytes that represent the data. This instruction does not represent a shadow, but it must be considered to identify correctly the bytes involved in the instruction. V. ANALYSIS OF SHADOWS In order to identify correctly the join points using static shadows, it is necessary to know in detail how the bytecode is generated with the operators that the language provides. The implementation of ÉNFASIS does not consider operations that involve bitwise operators. For this analysis Java 1.6 was used. 91

3 A. Java operators The first case is the generation of bytecode for increment (++), assignment with increment (+=) and assignment (=) operators. The basic operation is to increase by 1 an integer (primitive). We have three options: i = i + 1; i++; i += 1; The bytecode generated by these options are shown next: 0: bipush 10 [value 10] 2: istore_1 [store in slot 1] 3: iinc 1, 1 [add 1 to value in slot 1] 6: return The second case is when a variable is increased by a big number. i = i ; i += 50000; The bytecode generated for both cases is the next one: 0: bipush 10 [value 10] 2: istore_1 [store in slot 1] 3: iload_1 [load value from slot 1] 4: ldc [int 50000] 6: iadd [add] 7: istore_1 [store result in slot 1] To understand how the generated instructions change when the size of the constant changes, let s consider the following: In the range of 1 byte (-128 to 127) the generated instruction is iinc. In the range of 2 bytes (short) the instruction is iinc_w. In the range of 4 bytes (int) the generated instructions are iload, ldc, iadd and istore. In the range of 8 bytes (long) the generated instructions are lload, ldc2_w, ladd and lstore. If the local variables are byte or short data types, then iinc instructions are not generated. Instead, explicit iload and istore instructions are generated, with additional instructions like i2b and i2s for the required conversions. It is important to consider the behavior when we use wrapper classes. Byte i = new Byte((byte)0); i++; 0: new [Byte] 3: dup 4: iconst_0 5: invokespecial [Byte."<init>":(B)V] 8: astore_1 9: aload_1 10: invokevirtual [Byte.byteValue:()B] 13: iconst_1 14: iadd 15: i2b 16: invokestatic [Byte.valueOf:(B)Byte;] 19: astore_1 Likewise, when we use autoboxing the behaviour is: Byte i = 0; i++; 0: iconst_0 1: invokestatic [Byte.valueOf:(B)Byte;] 4: astore_1 5: aload_1 6: invokevirtual [Byte.byteValue:()B] 9: iconst_1 10: iadd 11: i2b 12: invokestatic [Byte.valueOf:(B)Byte;] 15: astore_1 The generation of code is similar for Short, Integer and Long data types, except by intermediate instructions for conversions. The aload and astore instructions are the same for all the cases. For boolean and char data types and their wrappers, the same rules apply. The float and double data types and their wrappers generate fload, fstore, dload, dstore, aload and astore instructions. The last two instructions apply for any object, in this way read and write join points are easily identifiable. B. Hidden shadows: iinc instruction A sentence like i = i + 25; generates the bytecode instruction iinc 8 = 25. iinc instruction is used to directly increase the stack of local variables, the operand stack is not used to perform operations. Taking in account this, iinc represents a natural join point only for write operations. In ÉNFASIS, iinc instruction has been called a hidden static shadow because it does not allow the explicit identification of join points for read and write operations. An alternative is to transform the iinc instruction in its equivalent load and store instructions. Let s consider the bytecode instruction iinc It can be transformed in: iload 8 bipush 25 iadd istore 8 In this way, the join point is exposed with shadows for read and write join points. It is important to note that this type of transformation generates an overload in the stack operations. The justification is based in the fact that the small 92

4 increments generate bad quantification using getlocal designator. 1) Support to expose hidden shadows: ÉNFASIS uses a refactoring mechanism to translate instructions iinc and iinc_w (wide followed by iinc) in its equivalent group of instructions: load, the constant, the involved operator and store. All the indexes, pc, addresses an entries in the local variable and line number tables are updated automatically. Therefore, there is no loss of references between the modified bytecode and its source code. Current implementation of ÉNFASIS supports exposing hidden shadows by an explicit option in the compiler. C. Local constants (final) A local variable could be declared as a constant. A final variable has implications in the context of hidden shadows. The following code shows an example with a variable. public void m() { int i = 8000; System.out.println(i); } public void m(); Stack=2, Locals=2, Args_size=1 0: sipush : istore_1 7: iload_1 8: invokevirtual [PrintStream.println:(I)V] 11: return The following code shows the previous version with the same variable, but declared as final. public void m() { final int i = 8000; System.out.println(i); } public void m(); Stack=2, Locals=2, Args_size=1 0: sipush : istore_1 7: sipush : invokevirtual [PrintStream.println:(I)V] 13: return Note that the instruction at address 7 places directly the constant without calling to the instruction iload_1. The exception to this situation happens when the value of the constant comes as a result of a method invocation or it is a value from another variable or field. In this case, load instructions will be generated and now it is possible to identify join points. The next example shows this situation. public void m() { final int i = (int)(math.random()*8000); System.out.println(i); } public void m(); Stack=4, Locals=2, Args_size=1 0: invokestatic [Math.random:()D] 3: ldc2_w [double d] 6: dmul 7: d2i 8: istore_1 9: getstatic [System.out:PrintStream;] 12: iload_1 13: invokevirtual [PrintStream.println:(I)V] 16: return iload_1 instruction at address 12 recovers the constant i. At bytecode level there is no mechanism to identify a local constant, unlike fields where a final declaration could be found. An option to solve this problem is detecting final declarations at source code. Current version of ÉNFASIS does not support this kind of hidden shadows. VI. ADVICE IMPLEMENTATION This section describes the details for advice implementation showing the bytecode transformations required by ÉNFASIS. A. before advice Let s consider the assignment m = 10;. The compiler generates the bytecode: 18: bipush 10 20: istore_1 A join point could be associated with address 20, with an istore instruction (in this case variable m). before advice implementation requires to refactor the bytecode inserting its instructions as follows: 18: bipush 10 20: getstatic [System.out] 23: ldc ["before a local variable!"] 25: invokevirtual [PrintStream.println:(String;)V] 28: istore_1 B. after advice after advice implementation is analogous to before advice. 18: bipush 10 20: istore_1 21: getstatic [System.out] 24: ldc ["after a local variable!"] 26: invokevirtual [PrintStream.println:(String;)V] C. around advice around advice allows to change and replace the behavior of the application. For local variables, the substitution has the effect of changing the original value of the variable for read and write join points, plus the additional execution of code. 93

5 To achieve this, ÉNFASIS inserts instructions in order to replace the value of the variable just before calling it or storing it. If the advice contains code to execute, it is inserted first, next the instructions for replacement. 1) proceed method: This method allows to get the original value of the variable. The next example shows how to use both around advice and proceed() method. 1 public aspect AroundAspect { 2 double around(): getlocal(void 3 Class.main(..)/double i) { 4 System.out.println(thisJoinPoint); 5 return 88.88; } } Applying the AroundAspect to HelloWorld example (see section 2), the program prints: getlocal(void Class.main(String[])/double i) VII. DISCUSSION Most of cases, the instrumented bytecode does not have correspondence with the high-level statements because insertions can be done in local variable shadows such as method arguments, loops or inside expressions. The join point model can locate variables inside for, enhanced for, while and do-while loops as well as if-else statements. The weaving process inserts all pieces of advice wherever a shadow is located (the code is in-lined). After the insertion, the instructions are consumed in order to get the same state before the insertion. This approach has the advantage of being highly efficient. ÉNFASIS uses strings and wildcards to specify pointcut quantification, but this establishes lexical dependencies generating pointcut fragility. VIII. FUTURE WORK Current ÉNFASIS language supports only getlocal and setlocal pointcut designators with a complete advice mechanism. We are considering to extend the language to support all capabilities of the framework. Another improvement is to support switch statements. IX. RELATED WORK Josh [2] uses Javassist to implements and AspectJ-like language with an extensible pointcut language. The extensions are limited to Javassist capabilities, but it does not support local variable crosscutting. This work is related to ÉNFASIS because its framework uses an extension of Javassist to identify shadows and transform bytecode instructions. Bugdel [5] is an aspect-oriented system for debugging. It provides two pointcut designators: line (for line numbers) and alllines (method name). thisjoinpoint variable is extended with line and variables to provide information about local variables available at a specific line of source code. In this sense, ÉNFASIS take a step further with a more precise pattern matching mechanism to select local variables and with a join point model for many application areas. LogicAJ2 [4] introduces the concept of fine-grained genericity. Based on static analysis and logic-meta variables, it is possible to construct any new pointcut designators such as getl and setl for local variables. However, those designators are not capable for selecting specific join points for local variables neither show source code information. X. CONCLUSIONS This paper has presented the advice weaving implementation in the ÉNFASIS framework. It uses byte code instrumentation to insert advice behaviour, identify shadows, expose hidden shadows, and use pointcut context without exposing its arguments. Details about how to implement advice and how to transform instructions were presented. Advice weaving for local variables is very important to encapsulate concerns related to program verification. This approach is not currently supported by any other aspect language. ACKNOWLEDGMENT This work is supported by the General Council of Superior Technological Education of México (DGEST). Additionally, this work is sponsored by the National Council of Science and Technology (CONACYT). REFERENCES [1] G. Kiczales, J. Irwin, J. Lamping, J.-M. Loingtier, C. V. Lopes, C. Maeda, and A. Mendhekar, Aspect-Oriented Programming, ACM Comput. Surv., vol. 28, [2] S. Chiba and K. Nakagawa, Josh: An Open AspectJ-like Language, in Proceedings of the 3rd International Conference on Aspect-Oriented Software Development (AOSD 04), Lancaster, UK, March [3] B. Harbulot and J. R. Gurd, A join point for loops in AspectJ, in Foundations of Aspect-Oriented Languages workshop, AOSD, R. E. Filman, Ed. ACM, 2006, pp [4] T. Rho, G. Kniesel, and M. Appeltauer, Fine-Grained Generic Aspects, in Foundations Of Aspect-Oriented Languages workshop, Bonn, Germany, March [5] Y. Usui and S. Chiba, Bugdel: an aspect-oriented debugging system, in Proceedings of the 12th Asia-Pacific Software Engineering Conference (APSEC 05), Taipei, Taiwan, December [6] C. Kastner and S. Apel, Granularity in Software Product Lines, in Proceedings of the 30th International Conference on Software Engineering (ICSE), Leipzig, Germany, May [7] J. Park and S. Hong, Customizing Real-Time Operating Systems with Aspect-Oriented Programming Framework, in Separation of Concerns Design Conference, 2003, pp

6 [8] H. Rajan and K. Sullivan, Generalizing AOP for Aspect- Oriented Testing, in In the proceedings of the Fourth International Conference on Aspect-Oriented Software Development (AOSD 2005), Chicago, IL, USA., March [9] N. Ubayashi, H. Masuhara, and T. Tamai, An AOP Implementation Framework for Extending Join Point Models, in Workshop on Reflection, AOP, and Meta-Data for Software Evolution, Oslo, June 2004, pp [10] N. M. Ali and A. Rashid, A State-based Join Point Model for AOP, in Proceedings of the 1st ECOOP Workshop on Views, Aspects and Role (VAR 05), in 19th European Conference on Object-Oriented Programming, [11] Y. Endoh, H. Masuhara, and A. Yonezawa, Continuation Join Points, in Foundations of Aspect-Oriented Languages Workshop at AOSD, March 2006, pp [12] U. Juárez-Martínez and J. O. Olmedo-Aguirre, ÉNFASIS: A Model for Local Variable Crosscutting, in In proceedings of the 23rd Annual ACM Symposium on Applied Computing (SAC). Cear, Brazil: University of Fortaleza (UNIFOR) and Federal University of Cear (UFC), March , pp [13], A Join Point Model for Fine-Grained Aspects, in Proceedings of 2nd. European Computing Conference, Malta, September [14], Run-Time Assertion Checking with ÉNFASIS, Computación y Sistemas Journal, vol. 13, no. 4, [15] U. Juárez-Martínez, G. Alor-Hernández, and R. Posada- Gómez, An Aspect-Oriented Approach for Assertion Verification, in In Proceedings of the First International Conference on Advances in System Testing and Validation Lifecycle (VALID), Porto, Portugal, September 2009, pp

The Java Virtual Machine. CSc 553. Principles of Compilation. 3 : The Java VM. Department of Computer Science University of Arizona

The Java Virtual Machine. CSc 553. Principles of Compilation. 3 : The Java VM. Department of Computer Science University of Arizona The Java Virtual Machine CSc 553 Principles of Compilation 3 : The Java VM Department of Computer Science University of Arizona collberg@gmail.com Copyright c 2011 Christian Collberg The Java VM has gone

More information

Bugdel: An Aspect-Oriented Debugging System

Bugdel: An Aspect-Oriented Debugging System Bugdel: An Aspect-Oriented Debugging System Yoshiyuki Usui and Shigeru Chiba Dept. of Mathematical and Computing Sciences Tokyo Institute of Technology 2-12-1-W8-50 Ohkayama, Meguro-ku Tokyo 152-8552,

More information

Improving Java Performance

Improving Java Performance Improving Java Performance #perfmatters Raimon Ràfols ...or the mumbo-jumbo behind the java compiler Agenda - Disclaimer - Who am I? - Our friend the java compiler - Language additions & things to consider

More information

Compiler construction 2009

Compiler construction 2009 Compiler construction 2009 Lecture 2 Code generation 1: Generating Jasmin code JVM and Java bytecode Jasmin Naive code generation The Java Virtual Machine Data types Primitive types, including integer

More information

JVM. What This Topic is About. Course Overview. Recap: Interpretive Compilers. Abstract Machines. Abstract Machines. Class Files and Class File Format

JVM. What This Topic is About. Course Overview. Recap: Interpretive Compilers. Abstract Machines. Abstract Machines. Class Files and Class File Format Course Overview What This Topic is About PART I: overview material 1 Introduction 2 Language processors (tombstone diagrams, bootstrapping) 3 Architecture of a compiler PART II: inside a compiler 4 Syntax

More information

JVML Instruction Set. How to get more than 256 local variables! Method Calls. Example. Method Calls

JVML Instruction Set. How to get more than 256 local variables! Method Calls. Example. Method Calls CS6: Program and Data Representation University of Virginia Computer Science Spring 006 David Evans Lecture 8: Code Safety and Virtual Machines (Duke suicide picture by Gary McGraw) pushing constants JVML

More information

Introduction to Programming Using Java (98-388)

Introduction to Programming Using Java (98-388) Introduction to Programming Using Java (98-388) Understand Java fundamentals Describe the use of main in a Java application Signature of main, why it is static; how to consume an instance of your own class;

More information

Improving Java Code Performance. Make your Java/Dalvik VM happier

Improving Java Code Performance. Make your Java/Dalvik VM happier Improving Java Code Performance Make your Java/Dalvik VM happier Agenda - Who am I - Java vs optimizing compilers - Java & Dalvik - Examples - Do & dont's - Tooling Who am I? (Mobile) Software Engineering

More information

Course Overview. PART I: overview material. PART II: inside a compiler. PART III: conclusion

Course Overview. PART I: overview material. PART II: inside a compiler. PART III: conclusion Course Overview PART I: overview material 1 Introduction (today) 2 Language Processors (basic terminology, tombstone diagrams, bootstrapping) 3 The architecture of a Compiler PART II: inside a compiler

More information

Let s make some Marc R. Hoffmann Eclipse Summit Europe

Let s make some Marc R. Hoffmann Eclipse Summit Europe Let s make some Marc R. Hoffmann Eclipse Summit Europe 2012 24.10.2012 public class WhatIsFaster { int i; void inc1() { i = i + 1; } void inc2() { i += 1; } void inc3() { i++; } } Why? Compilers Scrip;ng

More information

An Aspect-Oriented Language for Exception Handling

An Aspect-Oriented Language for Exception Handling Vol. 47 No. 4 Apr. 2006 GluonJ/R GluonJ/R block recover GluonJ/R An Aspect-Oriented Language for Exception Handling Natsuko Kumahara, Kenichi Kourai and Shigeru Chiba We must often handle exceptions raised

More information

Over-view. CSc Java programs. Java programs. Logging on, and logging o. Slides by Michael Weeks Copyright Unix basics. javac.

Over-view. CSc Java programs. Java programs. Logging on, and logging o. Slides by Michael Weeks Copyright Unix basics. javac. Over-view CSc 3210 Slides by Michael Weeks Copyright 2015 Unix basics javac java.j files javap 1 2 jasmin converting from javap to jasmin classfile structure calling methods adding line numbers Java programs

More information

Profiler Instrumentation Using Metaprogramming Techniques

Profiler Instrumentation Using Metaprogramming Techniques Profiler Instrumentation Using Metaprogramming Techniques Ritu Arora, Yu Sun, Zekai Demirezen, Jeff Gray University of Alabama at Birmingham Department of Computer and Information Sciences Birmingham,

More information

Compiling Techniques

Compiling Techniques Lecture 10: Introduction to 10 November 2015 Coursework: Block and Procedure Table of contents Introduction 1 Introduction Overview Java Virtual Machine Frames and Function Call 2 JVM Types and Mnemonics

More information

A Unit Testing Framework for Aspects without Weaving

A Unit Testing Framework for Aspects without Weaving A Unit Testing Framework for Aspects without Weaving Yudai Yamazaki l01104@sic.shibaura-it.ac.jp Kouhei Sakurai sakurai@komiya.ise.shibaura-it.ac.jp Saeko Matsuura matsuura@se.shibaura-it.ac.jp Hidehiko

More information

Space Exploration EECS /25

Space Exploration EECS /25 1/25 Space Exploration EECS 4315 www.eecs.yorku.ca/course/4315/ Nondeterminism 2/25 Nondeterministic code is code that, even for the same input, can exhibit different behaviours on different runs, as opposed

More information

02 B The Java Virtual Machine

02 B The Java Virtual Machine 02 B The Java Virtual Machine CS1102S: Data Structures and Algorithms Martin Henz January 22, 2010 Generated on Friday 22 nd January, 2010, 09:46 CS1102S: Data Structures and Algorithms 02 B The Java Virtual

More information

Static Program Analysis

Static Program Analysis Static Program Analysis Thomas Noll Software Modeling and Verification Group RWTH Aachen University https://moves.rwth-aachen.de/teaching/ws-1617/spa/ Recap: Taking Conditional Branches into Account Extending

More information

Java byte code verification

Java byte code verification Java byte code verification SOS Master Science Informatique U. Rennes 1 Thomas Jensen SOS Java byte code verification 1 / 26 Java security architecture Java: programming applications with code from different

More information

Introduction to. Bruno Harbulot. ESNW, the University of Manchester.

Introduction to. Bruno Harbulot. ESNW, the University of Manchester. Introduction to Aspect-Oriented Software Development Bruno Harbulot ESNW, the University of Manchester http://www.cs.man.ac.uk/~harbulob/ ELF Developers' Forum Manchester - October 2005 1/24 Presentation

More information

INDEX. A SIMPLE JAVA PROGRAM Class Declaration The Main Line. The Line Contains Three Keywords The Output Line

INDEX. A SIMPLE JAVA PROGRAM Class Declaration The Main Line. The Line Contains Three Keywords The Output Line A SIMPLE JAVA PROGRAM Class Declaration The Main Line INDEX The Line Contains Three Keywords The Output Line COMMENTS Single Line Comment Multiline Comment Documentation Comment TYPE CASTING Implicit Type

More information

UML4COP: UML-based DSML for Context-Aware Systems

UML4COP: UML-based DSML for Context-Aware Systems UML4COP: UML-based DSML for Context-Aware Systems Naoyasu Ubayashi Kyushu University ubayashi@acm.org Yasutaka Kamei Kyushu University kamei@ait.kyushu-u.ac.jp Abstract Context-awareness plays an important

More information

Tutorial 3: Code Generation

Tutorial 3: Code Generation S C I E N C E P A S S I O N T E C H N O L O G Y Tutorial 3: Code Generation Univ.-Prof. Dr. Franz Wotawa, DI Roxane Koitz, Stephan Frühwirt, Christopher Liebmann, Martin Zimmermann Institute for Software

More information

CSC 4181 Handout : JVM

CSC 4181 Handout : JVM CSC 4181 Handout : JVM Note: This handout provides you with the basic information about JVM. Although we tried to be accurate about the description, there may be errors. Feel free to check your compiler

More information

Designing Loop Condition Constraint Model for Join Point Designation Diagrams (JPDDs)

Designing Loop Condition Constraint Model for Join Point Designation Diagrams (JPDDs) Designing Loop Condition Constraint Model for Join Point Designation Diagrams (JPDDs) Bahram Zarrin Master Student Bahram.zarrin@gmail.com Rodziah Atan Doctor rodziah@fsktm.upm.edu.my Muhammad Taufik Abdullah

More information

Under the Hood: The Java Virtual Machine. Problem: Too Many Platforms! Compiling for Different Platforms. Compiling for Different Platforms

Under the Hood: The Java Virtual Machine. Problem: Too Many Platforms! Compiling for Different Platforms. Compiling for Different Platforms Compiling for Different Platforms Under the Hood: The Java Virtual Machine Program written in some high-level language (C, Fortran, ML, ) Compiled to intermediate form Optimized Code generated for various

More information

An Introduction to Multicodes. Ben Stephenson Department of Computer Science University of Western Ontario

An Introduction to Multicodes. Ben Stephenson Department of Computer Science University of Western Ontario An Introduction to Multicodes Ben Stephenson Department of Computer Science University of Western Ontario ben@csd csd.uwo.ca Outline Java Virtual Machine Background The Current State of the Multicode Art

More information

APTE: Automated Pointcut Testing for AspectJ Programs

APTE: Automated Pointcut Testing for AspectJ Programs APTE: Automated Pointcut Testing for AspectJ Programs Prasanth Anbalagan Department of Computer Science North Carolina State University Raleigh, NC 27695 panbala@ncsu.edu Tao Xie Department of Computer

More information

CS 231 Data Structures and Algorithms, Fall 2016

CS 231 Data Structures and Algorithms, Fall 2016 CS 231 Data Structures and Algorithms, Fall 2016 Dr. Bruce A. Maxwell Department of Computer Science Colby College Course Description Focuses on the common structures used to store data and the standard

More information

Programming Language Systems

Programming Language Systems Programming Language Systems Instructors: Taiichi Yuasa and Masahiro Yasugi Course Description (overview, purpose): The course provides an introduction to run-time mechanisms such as memory allocation,

More information

Using Aspects to Make Adaptive Object-Models Adaptable

Using Aspects to Make Adaptive Object-Models Adaptable Using Aspects to Make Adaptive Object-Models Adaptable Ayla Dantas 1, Joseph Yoder 2, Paulo Borba 1, Ralph Johnson 2 1 Software Productivity Group Informatics Center Federal University of Pernambuco Recife,

More information

Chapter 5. A Closer Look at Instruction Set Architectures. Chapter 5 Objectives. 5.1 Introduction. 5.2 Instruction Formats

Chapter 5. A Closer Look at Instruction Set Architectures. Chapter 5 Objectives. 5.1 Introduction. 5.2 Instruction Formats Chapter 5 Objectives Understand the factors involved in instruction set architecture design. Chapter 5 A Closer Look at Instruction Set Architectures Gain familiarity with memory addressing modes. Understand

More information

Using Aspects to Make Adaptive Object-Models Adaptable

Using Aspects to Make Adaptive Object-Models Adaptable Using Aspects to Make Adaptive Object-Models Adaptable Ayla Dantas 1, Joseph Yoder 2, Paulo Borba, and Ralph Johnson 1 Software Productivity Group Informatics Center Federal University of Pernambuco Recife,

More information

Chapter 5. A Closer Look at Instruction Set Architectures

Chapter 5. A Closer Look at Instruction Set Architectures Chapter 5 A Closer Look at Instruction Set Architectures Chapter 5 Objectives Understand the factors involved in instruction set architecture design. Gain familiarity with memory addressing modes. Understand

More information

Taming the Java Virtual Machine. Li Haoyi, Chicago Scala Meetup, 19 Apr 2017

Taming the Java Virtual Machine. Li Haoyi, Chicago Scala Meetup, 19 Apr 2017 Taming the Java Virtual Machine Li Haoyi, Chicago Scala Meetup, 19 Apr 2017 Who Am I? Previously: Dropbox Engineering Currently: Bright Technology Services - Data Science, Scala consultancy Fluent Code

More information

CS2110 Fall 2011 Lecture 25. Under the Hood: The Java Virtual Machine, Part II

CS2110 Fall 2011 Lecture 25. Under the Hood: The Java Virtual Machine, Part II CS2110 Fall 2011 Lecture 25 Under the Hood: The Java Virtual Machine, Part II 1 Java program last time Java compiler Java bytecode (.class files) Compile for platform with JIT Interpret with JVM run native

More information

COMP3131/9102: Programming Languages and Compilers

COMP3131/9102: Programming Languages and Compilers COMP3131/9102: Programming Languages and Compilers Jingling Xue School of Computer Science and Engineering The University of New South Wales Sydney, NSW 2052, Australia http://www.cse.unsw.edu.au/~cs3131

More information

Code Generation Introduction

Code Generation Introduction Code Generation Introduction i = 0 LF w h i l e i=0 while (i < 10) { a[i] = 7*i+3 i = i + 1 lexer i = 0 while ( i < 10 ) source code (e.g. Scala, Java,C) easy to write Compiler (scalac, gcc) parser type

More information

Program Dynamic Analysis. Overview

Program Dynamic Analysis. Overview Program Dynamic Analysis Overview Dynamic Analysis JVM & Java Bytecode [2] A Java bytecode engineering library: ASM [1] 2 1 What is dynamic analysis? [3] The investigation of the properties of a running

More information

3/15/18. Overview. Program Dynamic Analysis. What is dynamic analysis? [3] Why dynamic analysis? Why dynamic analysis? [3]

3/15/18. Overview. Program Dynamic Analysis. What is dynamic analysis? [3] Why dynamic analysis? Why dynamic analysis? [3] Overview Program Dynamic Analysis Dynamic Analysis JVM & Java Bytecode [2] A Java bytecode engineering library: ASM [1] 2 What is dynamic analysis? [3] The investigation of the properties of a running

More information

Introduction Basic elements of Java

Introduction Basic elements of Java Software and Programming I Introduction Basic elements of Java Roman Kontchakov / Carsten Fuhs Birkbeck, University of London Module Information Time: Thursdays in the Spring term Lectures: MAL B04: 2

More information

A Novel Approach to Unit Testing: The Aspect-Oriented Way

A Novel Approach to Unit Testing: The Aspect-Oriented Way A Novel Approach to Unit Testing: The Aspect-Oriented Way Guoqing Xu and Zongyuan Yang Software Engineering Lab, Department of Computer Science East China Normal University 3663, North Zhongshan Rd., Shanghai

More information

Under the Hood: The Java Virtual Machine. Lecture 23 CS2110 Fall 2008

Under the Hood: The Java Virtual Machine. Lecture 23 CS2110 Fall 2008 Under the Hood: The Java Virtual Machine Lecture 23 CS2110 Fall 2008 Compiling for Different Platforms Program written in some high-level language (C, Fortran, ML,...) Compiled to intermediate form Optimized

More information

SOFTWARE ARCHITECTURE 7. JAVA VIRTUAL MACHINE

SOFTWARE ARCHITECTURE 7. JAVA VIRTUAL MACHINE 1 SOFTWARE ARCHITECTURE 7. JAVA VIRTUAL MACHINE Tatsuya Hagino hagino@sfc.keio.ac.jp slides URL https://vu5.sfc.keio.ac.jp/sa/ Java Programming Language Java Introduced in 1995 Object-oriented programming

More information

Advice Weaving in AspectJ

Advice Weaving in AspectJ Erik Hilsdale PARC 3333 Coyote Hill Rd Palo Alto, CA 94085 +1 650 812 4735 hilsdale@parc.com Advice Weaving in AspectJ Jim Hugunin Want of a Nail Software Sunnyvale, CA +1 650 812 4735 jim-aj@hugunin.net

More information

Implementing Producers/Consumers Problem Using Aspect-Oriented Framework

Implementing Producers/Consumers Problem Using Aspect-Oriented Framework Implementing Producers/Consumers Problem Using Aspect-Oriented Framework 1 Computer Science Department School of Science Bangkok University Bangkok, Thailand netipan@iit.edu Paniti Netinant 1, 2 and Tzilla

More information

Aspect-Oriented Generation of the API Documentation for AspectJ

Aspect-Oriented Generation of the API Documentation for AspectJ Aspect-Oriented Generation of the API Documentation for AspectJ Michihiro Horie Tokyo Institute of Technology 2-12-1 Ohkayama, Meguro-ku, Tokyo 152-8552, Japan www.csg.is.titech.ac.jp/ horie Shigeru Chiba

More information

Improving Software Modularity using AOP

Improving Software Modularity using AOP B Vasundhara 1 & KV Chalapati Rao 2 1 Dept. of Computer Science, AMS School of Informatics, Hyderabad, India 2 CVR College of Engineering, Ibrahimpatnam, India E-mail : vasu_venki@yahoo.com 1, chalapatiraokv@gmail.com

More information

Exercise 7 Bytecode Verification self-study exercise sheet

Exercise 7 Bytecode Verification self-study exercise sheet Concepts of ObjectOriented Programming AS 2018 Exercise 7 Bytecode Verification selfstudy exercise sheet NOTE: There will not be a regular exercise session on 9th of November, because you will take the

More information

Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model

Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model Computer Science Technical Reports Computer Science 2007 Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model Robert Dyer Iowa State University, rdyer@iastate.edu Rakesh Bangalore

More information

Analysis and Research on the Automated Generation of Unit Test

Analysis and Research on the Automated Generation of Unit Test 1+, 1 1, 1 (, 200062) Analysis and Research on the Automated Generation of Unit Test XU Guo-qing 1+, YANG Zong-yuan 1, HUANG Hai-tao 1 1 (Software Engineering Lab, Department of Computer Science, East

More information

A Quantitative Analysis of Java Bytecode Sequences

A Quantitative Analysis of Java Bytecode Sequences A Quantitative Analysis of Java Bytecode Sequences Ben Stephenson Wade Holst Department of Computer Science, University of Western Ontario, London, Ontario, Canada 1 Introduction A variety of studies have

More information

Design-Based Pointcuts Robustness Against Software Evolution

Design-Based Pointcuts Robustness Against Software Evolution Design-Based Pointcuts Robustness Against Software Evolution Walter Cazzola 1, Sonia Pini 2, and Ancona Massimo 2 1 Department of Informatics and Communication, Università degli Studi di Milano, Italy

More information

Statement Annotations for Fine-Grained Advising

Statement Annotations for Fine-Grained Advising Statement Annotations for Fine-Grained Advising Marc Eaddy Alfred Aho Department of Computer Science Columbia University New York, NY 10027 {eaddy,aho@cs.columbia.edu ABSTRACT AspectJ-like languages are

More information

Characteristics of Runtime Program Evolution

Characteristics of Runtime Program Evolution Characteristics of Runtime Program Evolution Mario Pukall and Martin Kuhlemann School of Computer Science, University of Magdeburg, Germany {pukall, kuhlemann}@iti.cs.uni-magdeburg.de Abstract. Applying

More information

CS 11 java track: lecture 1

CS 11 java track: lecture 1 CS 11 java track: lecture 1 Administrivia need a CS cluster account http://www.cs.caltech.edu/ cgi-bin/sysadmin/account_request.cgi need to know UNIX www.its.caltech.edu/its/facilities/labsclusters/ unix/unixtutorial.shtml

More information

Chapitre 6 Programmation orientée aspect (AOP)

Chapitre 6 Programmation orientée aspect (AOP) 6 Programmation orientée aspect (AOP) 2I1AC3 : Génie logiciel et Patrons de conception Régis Clouard, ENSICAEN - GREYC «L'homme est le meilleur ordinateur que l'on puisse embarquer dans un engin spatial...

More information

Aspect Oriented Programming with AspectJ. Ted Leung Sauria Associates, LLC

Aspect Oriented Programming with AspectJ. Ted Leung Sauria Associates, LLC Aspect Oriented Programming with AspectJ Ted Leung Sauria Associates, LLC twl@sauria.com Overview Why do we need AOP? What is AOP AspectJ Why do we need AOP? Modular designs are not cut and dried Responsibilities

More information

Aspect Design Pattern for Non Functional Requirements

Aspect Design Pattern for Non Functional Requirements Aspect Design Pattern for Non Functional Requirements FAZAL-E-AMIN¹, ANSAR SIDDIQ², HAFIZ FAROOQ AHMAD³ ¹ ²International Islamic University Islamabad, Pakistan ³NUST Institute of Information Technology,

More information

Using and Extending AspectJ for Separating Concerns in Parallel Java Code

Using and Extending AspectJ for Separating Concerns in Parallel Java Code Using and Extending AspectJ for Separating Concerns in Parallel Java Code Bruno Harbulot and John Gurd The University of Manchester POOSC 2005 Glasgow, July 2005 1/26 Presentation Outline Problem and Approach

More information

Java Primer 1: Types, Classes and Operators

Java Primer 1: Types, Classes and Operators Java Primer 1 3/18/14 Presentation for use with the textbook Data Structures and Algorithms in Java, 6th edition, by M. T. Goodrich, R. Tamassia, and M. H. Goldwasser, Wiley, 2014 Java Primer 1: Types,

More information

Java: framework overview and in-the-small features

Java: framework overview and in-the-small features Chair of Software Engineering Carlo A. Furia, Marco Piccioni, Bertrand Meyer Java: framework overview and in-the-small features Chair of Software Engineering Carlo A. Furia, Marco Piccioni, Bertrand Meyer

More information

CSE 431S Final Review. Washington University Spring 2013

CSE 431S Final Review. Washington University Spring 2013 CSE 431S Final Review Washington University Spring 2013 What You Should Know The six stages of a compiler and what each stage does. The input to and output of each compilation stage (especially the back-end).

More information

Course 6 7 November Adrian Iftene

Course 6 7 November Adrian Iftene Course 6 7 November 2016 Adrian Iftene adiftene@info.uaic.ro 1 Recapitulation course 5 BPMN AOP AOP Cross cutting concerns pointcuts advice AspectJ Examples In C#: NKalore 2 BPMN Elements Examples AOP

More information

Chapter 5. A Closer Look at Instruction Set Architectures. Chapter 5 Objectives. 5.1 Introduction. 5.2 Instruction Formats

Chapter 5. A Closer Look at Instruction Set Architectures. Chapter 5 Objectives. 5.1 Introduction. 5.2 Instruction Formats Chapter 5 Objectives Chapter 5 A Closer Look at Instruction Set Architectures Understand the factors involved in instruction set architecture design. Gain familiarity with memory addressing modes. Understand

More information

Chapter 5. A Closer Look at Instruction Set Architectures

Chapter 5. A Closer Look at Instruction Set Architectures Chapter 5 A Closer Look at Instruction Set Architectures Chapter 5 Objectives Understand the factors involved in instruction set architecture design. Gain familiarity with memory addressing modes. Understand

More information

Mnemonics Type-Safe Bytecode Generation in Scala

Mnemonics Type-Safe Bytecode Generation in Scala Mnemonics Type-Safe Bytecode Generation in Scala Johannes Rudolph CleverSoft GmbH, Munich Peter Thiemann Albert-Ludwigs-Universität Freiburg, Germany Scala Days 2010, Lausanne, 15.04.2010 Existing bytecode

More information

A Foundation for Programming

A Foundation for Programming 2.1 Functions A Foundation for Programming any program you might want to write objects functions and modules build bigger programs and reuse code graphics, sound, and image I/O arrays conditionals and

More information

Code Profiling. CSE260, Computer Science B: Honors Stony Brook University

Code Profiling. CSE260, Computer Science B: Honors Stony Brook University Code Profiling CSE260, Computer Science B: Honors Stony Brook University http://www.cs.stonybrook.edu/~cse260 Performance Programs should: solve a problem correctly be readable be flexible (for future

More information

AJDT: Getting started with Aspect-Oriented Programming in Eclipse

AJDT: Getting started with Aspect-Oriented Programming in Eclipse AJDT: Getting started with Aspect-Oriented Programming in Eclipse Matt Chapman IBM Java Technology Hursley, UK AJDT Committer Andy Clement IBM Java Technology Hursley, UK AJDT & AspectJ Committer Mik Kersten

More information

An Aspect-to-Class Advising Architecture Based on XML in Aspect Oriented Programming

An Aspect-to-Class Advising Architecture Based on XML in Aspect Oriented Programming An Aspect-to-Class Advising Architecture Based on XML in Aspect Oriented Programming T. Hussain, M. M. Awais, S. Shamail, M. A. Adnan Department of Computer Science Lahore University of Management Sciences,

More information

Control-Flow-Graph-Based Aspect Mining

Control-Flow-Graph-Based Aspect Mining Control-Flow-Graph-Based Aspect Mining Jens Krinke FernUniversität in Hagen, Germany krinke@acm.org Silvia Breu NASA Ames Research Center, USA silvia.breu@gmail.com Abstract Aspect mining tries to identify

More information

CSc 620 Debugging, Profiling, Tracing, and Visualizing Programs. Compiling Java. The Java Class File Format 1 : JVM

CSc 620 Debugging, Profiling, Tracing, and Visualizing Programs. Compiling Java. The Java Class File Format 1 : JVM Attributes Execute The Java Virtual Machine CSc 620 Debugging, Profiling, Tracing, and Visualizing Programs 1 : JVM Christian Collberg collberg+620@gmail.com The Java VM has gone the many complex instructions/large

More information

Lecture Set 4: More About Methods and More About Operators

Lecture Set 4: More About Methods and More About Operators Lecture Set 4: More About Methods and More About Operators Methods Definitions Invocations More arithmetic operators Operator Side effects Operator Precedence Short-circuiting main method public static

More information

Operators and Expressions

Operators and Expressions Operators and Expressions Conversions. Widening and Narrowing Primitive Conversions Widening and Narrowing Reference Conversions Conversions up the type hierarchy are called widening reference conversions

More information

Shared Mutable State SWEN-220

Shared Mutable State SWEN-220 Shared Mutable State SWEN-220 The Ultimate Culprit - Shared, Mutable State Most of your development has been in imperative languages. The fundamental operation is assignment to change state. Assignable

More information

Sir Muhammad Naveed. Arslan Ahmed Shaad ( ) Muhammad Bilal ( )

Sir Muhammad Naveed. Arslan Ahmed Shaad ( ) Muhammad Bilal ( ) Sir Muhammad Naveed Arslan Ahmed Shaad (1163135 ) Muhammad Bilal ( 1163122 ) www.techo786.wordpress.com CHAPTER: 2 NOTES:- VARIABLES AND OPERATORS The given Questions can also be attempted as Long Questions.

More information

Computational Expression

Computational Expression Computational Expression Variables, Primitive Data Types, Expressions Janyl Jumadinova 28-30 January, 2019 Janyl Jumadinova Computational Expression 28-30 January, 2019 1 / 17 Variables Variable is a name

More information

WA1278 Introduction to Java Using Eclipse

WA1278 Introduction to Java Using Eclipse Lincoln Land Community College Capital City Training Center 130 West Mason Springfield, IL 62702 217-782-7436 www.llcc.edu/cctc WA1278 Introduction to Java Using Eclipse This course introduces the Java

More information

Java TM Introduction. Renaud Florquin Isabelle Leclercq. FloConsult SPRL.

Java TM Introduction. Renaud Florquin Isabelle Leclercq. FloConsult SPRL. Java TM Introduction Renaud Florquin Isabelle Leclercq FloConsult SPRL http://www.floconsult.be mailto:info@floconsult.be Java Technical Virtues Write once, run anywhere Get started quickly Write less

More information

Plan for Today. Safe Programming Languages. What is a secure programming language?

Plan for Today. Safe Programming Languages. What is a secure programming language? cs2220: Engineering Software Class 19: Java Security Java Security Plan for Today Java Byte s () and Verification Fall 2010 UVa David Evans Reminder: Project Team Requests are due before midnight tomorrow

More information

Copyright 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 16

Copyright 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 16 1 Copyright 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 16 Towards JVM Dynamic Languages Toolchain Insert Picture Here Attila

More information

COP 3330 Final Exam Review

COP 3330 Final Exam Review COP 3330 Final Exam Review I. The Basics (Chapters 2, 5, 6) a. comments b. identifiers, reserved words c. white space d. compilers vs. interpreters e. syntax, semantics f. errors i. syntax ii. run-time

More information

Applying Aspect Oriented Programming on Security

Applying Aspect Oriented Programming on Security Original Article Applying Aspect Oriented Programming on Security Mohammad Khalid Pandit* 1, Azra Nazir 1 and Arutselvan M 2 1 Department of computer Science and engineering, National institute of technology

More information

Contents. Figures. Tables. Examples. Foreword. Preface. 1 Basics of Java Programming 1. xix. xxi. xxiii. xxvii. xxix

Contents. Figures. Tables. Examples. Foreword. Preface. 1 Basics of Java Programming 1. xix. xxi. xxiii. xxvii. xxix PGJC4_JSE8_OCA.book Page ix Monday, June 20, 2016 2:31 PM Contents Figures Tables Examples Foreword Preface xix xxi xxiii xxvii xxix 1 Basics of Java Programming 1 1.1 Introduction 2 1.2 Classes 2 Declaring

More information

Lecture 5: Methods CS2301

Lecture 5: Methods CS2301 Lecture 5: Methods NADA ALZAHRANI CS2301 1 Opening Problem Find the sum of integers from 1 to 10, from 20 to 30, and from 35 to 45, respectively. 2 Solution public static int sum(int i1, int i2) { int

More information

Sort-based Refactoring of Crosscutting Concerns to Aspects

Sort-based Refactoring of Crosscutting Concerns to Aspects Sort-based Refactoring of Crosscutting Concerns to Aspects Robin van der Rijst Delft University of Technology rvdrijst@gmail.com Marius Marin Accenture Marius.Marin@accenture.com Arie van Deursen Delft

More information

Name :. Roll No. :... Invigilator s Signature : INTRODUCTION TO PROGRAMMING. Time Allotted : 3 Hours Full Marks : 70

Name :. Roll No. :... Invigilator s Signature : INTRODUCTION TO PROGRAMMING. Time Allotted : 3 Hours Full Marks : 70 Name :. Roll No. :..... Invigilator s Signature :.. 2011 INTRODUCTION TO PROGRAMMING Time Allotted : 3 Hours Full Marks : 70 The figures in the margin indicate full marks. Candidates are required to give

More information

A Theory of Aspects for Aspect-Oriented Software Development

A Theory of Aspects for Aspect-Oriented Software Development A Theory of Aspects for Aspect-Oriented Software Development Christina von Flach G. Chavez 1,2 Carlos J. P. de Lucena 2 1 UFBA, Computer Science Department Av. Adhemar de Barros, s/n 40170-110, Salvador,

More information

SERG. Sort-based Refactoring of Crosscutting Concerns to Aspects

SERG. Sort-based Refactoring of Crosscutting Concerns to Aspects Delft University of Technology Software Engineering Research Group Technical Report Series Sort-based Refactoring of Crosscutting Concerns to Aspects Robin van der Rijst, Marius Marin, and Arie van Deursen

More information

Zhifu Pei CSCI5448 Spring 2011 Prof. Kenneth M. Anderson

Zhifu Pei CSCI5448 Spring 2011 Prof. Kenneth M. Anderson Zhifu Pei CSCI5448 Spring 2011 Prof. Kenneth M. Anderson Introduction History, Characteristics of Java language Java Language Basics Data types, Variables, Operators and Expressions Anatomy of a Java Program

More information

AspectC2C: a Symmetric Aspect Extension to the C Language

AspectC2C: a Symmetric Aspect Extension to the C Language AspectC2C: a Symmetric Aspect Extension to the C Language Danfeng Zhang, Yao Guo, Xiangqun Chen Key laboratory of High Confidence Software Technologies, Ministry of Education Institute of Software, School

More information

CS11 Java. Fall Lecture 1

CS11 Java. Fall Lecture 1 CS11 Java Fall 2006-2007 Lecture 1 Welcome! 8 Lectures Slides posted on CS11 website http://www.cs.caltech.edu/courses/cs11 7-8 Lab Assignments Made available on Mondays Due one week later Monday, 12 noon

More information

Graphical Interface and Application (I3305) Semester: 1 Academic Year: 2017/2018 Dr Antoun Yaacoub

Graphical Interface and Application (I3305) Semester: 1 Academic Year: 2017/2018 Dr Antoun Yaacoub Lebanese University Faculty of Science Computer Science BS Degree Graphical Interface and Application (I3305) Semester: 1 Academic Year: 2017/2018 Dr Antoun Yaacoub 2 Crash Course in JAVA Classes A Java

More information

CSC Java Programming, Fall Java Data Types and Control Constructs

CSC Java Programming, Fall Java Data Types and Control Constructs CSC 243 - Java Programming, Fall 2016 Java Data Types and Control Constructs Java Types In general, a type is collection of possible values Main categories of Java types: Primitive/built-in Object/Reference

More information

Java Bytecode (binary file)

Java Bytecode (binary file) Java is Compiled Unlike Python, which is an interpreted langauge, Java code is compiled. In Java, a compiler reads in a Java source file (the code that we write), and it translates that code into bytecode.

More information

Assertion with Aspect

Assertion with Aspect Assertion with Aspect Takashi Ishio, Toshihiro Kamiya, Shinji Kusumoto, Katsuro Inoue Graduate School of Engineering Science, PRESTO, Japan Science and Technology Agency Osaka University 1-3 Machikaneyama-cho,

More information

Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model

Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model Computer Science Technical Reports Computer Science 2007 Nu: Towards a Flexible and Dynamic Aspect- Oriented Intermediate Language Model Robert Dyer Iowa State University, rdyer@iastate.edu Rakesh Bangalore

More information

CSE P 501 Compilers. Java Implementation JVMs, JITs &c Hal Perkins Winter /11/ Hal Perkins & UW CSE V-1

CSE P 501 Compilers. Java Implementation JVMs, JITs &c Hal Perkins Winter /11/ Hal Perkins & UW CSE V-1 CSE P 501 Compilers Java Implementation JVMs, JITs &c Hal Perkins Winter 2008 3/11/2008 2002-08 Hal Perkins & UW CSE V-1 Agenda Java virtual machine architecture.class files Class loading Execution engines

More information

CHAPTER 7 OBJECTS AND CLASSES

CHAPTER 7 OBJECTS AND CLASSES CHAPTER 7 OBJECTS AND CLASSES OBJECTIVES After completing Objects and Classes, you will be able to: Explain the use of classes in Java for representing structured data. Distinguish between objects and

More information