Towards information-flow aware automatic memory management

Size: px
Start display at page:

Download "Towards information-flow aware automatic memory management"

Transcription

1 Towards information-flow aware automatic memory management Aslan Askarov Aarhus University joint work w/ Mathias Pedersen INRIA Rennes

2 2

3 2 I want to compute my taxes!

4 I want to compute my taxes! 3

5 I want to compute my taxes! I can do that for you! Just run this code! 3

6 I want to compute my taxes! I can do that for you! Just run this code! tax_computation_automator.exe 3

7 I want to compute my taxes! I can do that for you! Just run this code! Okay! tax_computation_automator.exe 3

8 I want to compute my taxes! I can do that for you! Just run this code! Okay! aliceserver.send(bobsalary) 4

9 Bob could have been smart Let me check it first! I can do that for you! Just run this code! aliceserver.send(bobsalary) 5

10 Bob could have been smart Program analysis tax_computation_a utomator.exe 6

11 Bob could have been smart Aha! Program analysis tax_computation_a utomator.exe 6

12 But is Bob smart enough? Do you have anything better? Try this program instead! tax_computation_automa torv2.exe 7

13 But is Bob smart enough? Program analysis tax_computation_automator v2.exe 8

14 But is Bob smart enough? Program analysis tax_computation_automator v2.exe 8

15 But is Bob smart enough? Program analysis x := gettime() if bobsalary > 500k then long computation else skip y := gettime() aliceserver.send(y - x) 9

16 But is Bob smart enough? Program analysis x := gettime() if bobsalary > 500k then long computation else skip y := gettime() aliceserver.send(y - x) 10

17 But is Bob smart enough? Program analysis x := gettime() if bobsalary > 500k then long computation else skip y := gettime() aliceserver.send(y - x) 11

18 But is Bob smart enough? Ensures secret branches consume equal time Program analysis x := gettime() if bobsalary > 500k then long computation else skip y := gettime() aliceserver.send(y - x) 11

19 Alice goes to work Hmm The code is running in a managed language 12

20 Alice goes to work Hmm The code is running in a managed language So I can construct another attack via the garbage collector! 12

21 Example GC: Cheney s algorithm [1] Heap 13

22 Example GC: Cheney s algorithm [1] Heap 14

23 Example GC: Cheney s algorithm [1] Heap From-space 15

24 Example GC: Cheney s algorithm [1] Heap From-space To-space 15

25 Example GC: Cheney s algorithm [1] Heap From-space To-space 16

26 Example GC: Cheney s algorithm [1] Heap From-space To-space 16

27 Example GC: Cheney s algorithm [1] Heap From-space To-space 16

28 Example GC: Cheney s algorithm [1] Heap From-space Copy these To-space 16

29 Example GC: Cheney s algorithm [1] Heap From-space Copy these To-space 17

30 Example GC: Cheney s algorithm [1] Heap Erase that From-space To-space 17

31 Example GC: Cheney s algorithm [1] Heap From-space To-space 18

32 Example GC: Cheney s algorithm [1] Heap To-space From-space 19

33 Example GC: Cheney s algorithm [1] Heap To-space From-space 19

34 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); 20

35 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); We allocate size1 ints and store ref in a 20

36 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); We allocate size1 ints and store ref in b 20

37 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); Assume GC happens here 20

38 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); a and b are both live and point to different arrays. 2*size1 integers need to be copied from from-space to to-space 20

39 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); Printed value is large 20

40 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); 21

41 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); b is a reference pointing to the same array as a 21

42 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); Assume GC happens here 21

43 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); a and b are both live but point to the same array! Only size1 integers need to be copied from from-space to to-space. 21

44 Attack: Leak via GC int[] a = new int[size1]; int[] b = null; int[] c = null; int[] d = null; if (bobsalary > ) { b = new int[size1]; d = a; } else { c = new int[size1]; b = a; } c = null; long before = System.nanoTime(); int[] x = new int[size2]; long after = System.nanoTime(); System.out.println(after - before); Printed value is small 21

45 Demo java Leak1Bit java Leak1Bit

46 What is small and large? bobsalary bobsallary > Nanoseconds XX:+UseParallelGC -Xms Xmx java version "1.8.0_77" 0 Number of trials 23

47 Bob is not impressed That s only 1 bit of information! 24

48 Bob is not impressed That s only 1 bit of information! Oh I m not done yet 24

49 Amplification to N bits long[] times = new long[n]; for(int bit = 31; bit >= 0; --bit) { for(int i = 0; i < N; ++i) { int[][] a = new int[k][size]; if(((secret >> bit) & 1) > 0) { b = new int[k][size]; } else { b = a; } long before = System.nanoTime(); int[] c = new int[size2]; long after = System.nanoTime(); if(after - before > threshold) { times[i] = after - before; } else { times[i] = 0; } } This code leaks 32 bits in a single run } long sum = 0; long gcs = 0; for(int i = 0; i < N; ++i) { long t = times[i]; t += times[i]; if(t!= 0) ++gcs; } if(gcs == 0) { ++bit; continue; } System.out.println(sum / gcs); 25

50 Amplification to N bits long[] times = new long[n]; for(int bit = 31; bit >= 0; --bit) { for(int i = 0; i < N; ++i) { int[][] a = new int[k][size]; if(((secret >> bit) & 1) > 0) { b = new int[k][size]; } else { b = a; } long before = System.nanoTime(); int[] c = new int[size2]; long after = System.nanoTime(); if(after - before > threshold) { times[i] = after - before; } else { times[i] = 0; } } This code leaks 32 bits in a single run In fact I can leak any number of bits this way! } long sum = 0; long gcs = 0; for(int i = 0; i < N; ++i) { long t = times[i]; t += times[i]; if(t!= 0) ++gcs; } if(gcs == 0) { ++bit; continue; } System.out.println(sum / gcs); 25

51 Amplification to N bits long[] times = new long[n]; for(int bit = 31; bit >= 0; --bit) { for(int i = 0; i < N; ++i) { int[][] a = new int[k][size]; if(((secret >> bit) & 1) > 0) { b = new int[k][size]; } else { b = a; } long before = System.nanoTime(); int[] c = new int[size2]; long after = System.nanoTime(); if(after - before > threshold) { times[i] = after - before; } else { times[i] = 0; } } This code leaks 32 bits in a single run In fact I can leak any number of bits this way! } long sum = 0; long gcs = 0; for(int i = 0; i < N; ++i) { long t = times[i]; t += times[i]; if(t!= 0) ++gcs; } if(gcs == 0) { ++bit; continue; } System.out.println(sum / gcs); Rate: 0.98 byte/s 25

52 Result for JVM Nanoseconds XX:+UseSerialGC -Xms Xmx java version "1.8.0_77" 0 Bits 0 to 31 of

53 Result for V8 via Node.js Nanoseconds node v6.2.0 V8 version Bits 0 to 31 of

54 Summary of experiments Java serial generational garbage collector -XX:+UseSerialGC Java parallel generational garbage collector -XX:+UseParallelGC JavaScript (V8 via Node.js) Generational + Incremental mark-sweep Delays are significant enough to mount a network attack in a datacenter with ping 0.5 ms. 28

55 Yikes! How can we fix this? 29

56 Yikes! How can we fix this? I have some ideas 29

57 The problem is that the GC can be invoked at any point in the program 30

58 The problem is that the GC can be invoked at any point in the program Idea: restrict when GC can be invoked 30

59 Formalization Standard WHILE language Heap allocation of arrays Explicit access to system clock Runtime program counter level Runtime security levels for values on the heap Isolated study of GC timing leaks Enforce control flow timing channels Assume no leaks via cache 31

60 Restricting GC: Exploring the design space I wonder if we can GC public values in a secret context? 32

61 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1

62 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 y is now garbage

63 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 Assume GC here

64 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 No need to GC here

65 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 Result: public is small

66 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1

67 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 No GC happens now

68 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 GC now happens here

69 Observation 1 GC ing public values in a secret context is insecure y := new (L, size1, 0) y := null if secret > 0 then x := new (H, size2, 0) else skip t1 := gettime() y := new (L, size1, 0) t2 := gettime () public := t2 - t1 Result: public is large

70 Restricting GC: Exploring the design space So we cannot GC low values in high contexts. What about the other direction? 35

71 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1

72 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 No longer need to move x from from-space to to-space

73 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 Assume GC here

74 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 Result: public is small

75 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1

76 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 x is still live

77 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 Assume GC here

78 Observation 2 GC ing secret values in a public context is insecure x := new (H, size1, 0) if secret > 0 then x := null else skip t1 := gettime() y := new (L, size2, 0) t2 := gettime () public := t2 - t1 Result: public is large

79 Restricting GC: Summary of exploration Observation 1: Cannot GC public parts of the heap when program context is secret. So GC ing high values in low contexts is also insecure Observation 2: Cannot GC secrets parts of the heap when program context is public. 38

80 Runtime requirements for GC (1/2) L H L L L v H L H H L H L H L 39

81 Runtime requirements for GC (1/2) Assume pc = L L H L L L v H L H H L H L H L 39

82 Runtime requirements for GC (1/2) Assume pc = L L H L L L v H L H H L H L H L 39

83 Runtime requirements for secure GC Assume pc = L L H L L L v H L H H L H L H L 40

84 Runtime requirements for secure GC Assume pc = L L H L L v H H H H L H L 40

85 Our solution Runtime control over GC + Static analysis Noninterference 41

86 Our solution Denning-style enforcement Runtime control over GC + Static analysis Noninterference 41

87 Our solution Denning-style enforcement Runtime control over GC + Static analysis Termination-insensitive Noninterference 41

88 Our solution Denning-style enforcement Runtime control over GC + Static analysis Termination-insensitive Noninterference Ongoing formalization of the proofs in Coq 41

89 Formalization quick tour Language syntax Semantics for at command Abstract semantics for GC

90 Formalization quick tour Language syntax Semantics for at command Abstract semantics for GC

91 Conclusion & future work First attack on garbage collection: systems providing high confidentiality cannot rely on standard runtime support. Constraints on runtime to prevent GC leaks is sufficient. Future work: Efficient implementation of our restricted GC in practice. 43

92 Interested in this stuff? We have several PhD and postdoc positions in Language- Based Security at Aarhus University Ask me today in-person or In world happiness surveys, Denmark often comes out on top, with Aarhus, the nation's second-largest city, as the happiest of the country. In other words, Aarhus may just be the most pleasant city on earth. [KLM In-Flight Entertainment Magazine, January 2017]

JVM Memory Model and GC

JVM Memory Model and GC JVM Memory Model and GC Developer Community Support Fairoz Matte Principle Member Of Technical Staff Java Platform Sustaining Engineering, Copyright 2015, Oracle and/or its affiliates. All rights reserved.

More information

Memory Management: The Details

Memory Management: The Details Lecture 10 Memory Management: The Details Sizing Up Memory Primitive Data Types Complex Data Types byte: char: short: basic value (8 bits) 1 byte 2 bytes Pointer: platform dependent 4 bytes on 32 bit machine

More information

Run-Time Environments/Garbage Collection

Run-Time Environments/Garbage Collection Run-Time Environments/Garbage Collection Department of Computer Science, Faculty of ICT January 5, 2014 Introduction Compilers need to be aware of the run-time environment in which their compiled programs

More information

Sustainable Memory Use Allocation & (Implicit) Deallocation (mostly in Java)

Sustainable Memory Use Allocation & (Implicit) Deallocation (mostly in Java) COMP 412 FALL 2017 Sustainable Memory Use Allocation & (Implicit) Deallocation (mostly in Java) Copyright 2017, Keith D. Cooper & Zoran Budimlić, all rights reserved. Students enrolled in Comp 412 at Rice

More information

the gamedesigninitiative at cornell university Lecture 9 Memory Management

the gamedesigninitiative at cornell university Lecture 9 Memory Management Lecture 9 Gaming Memory Constraints Redux Wii-U Playstation 4 2GB of RAM 1GB dedicated to OS Shared with GPGPU 8GB of RAM Shared GPU, 8-core CPU OS footprint unknown 2 Two Main Concerns with Memory Getting

More information

Designing experiments Performing experiments in Java Intel s Manycore Testing Lab

Designing experiments Performing experiments in Java Intel s Manycore Testing Lab Designing experiments Performing experiments in Java Intel s Manycore Testing Lab High quality results that capture, e.g., How an algorithm scales Which of several algorithms performs best Pretty graphs

More information

1. Mark-and-Sweep Garbage Collection

1. Mark-and-Sweep Garbage Collection Due: Tuesday, April 21, 2015. 11:59pm (no extensions). What to submit: A tar ball containing the files: Slide.java, slide.png or slide.pdf with your slide, benchmark.template, and any file(s) containing

More information

Reference Counting. Reference counting: a way to know whether a record has other users

Reference Counting. Reference counting: a way to know whether a record has other users Garbage Collection Today: various garbage collection strategies; basic ideas: Allocate until we run out of space; then try to free stuff Invariant: only the PL implementation (runtime system) knows about

More information

CS 345. Garbage Collection. Vitaly Shmatikov. slide 1

CS 345. Garbage Collection. Vitaly Shmatikov. slide 1 CS 345 Garbage Collection Vitaly Shmatikov slide 1 Major Areas of Memory Static area Fixed size, fixed content, allocated at compile time Run-time stack Variable size, variable content (activation records)

More information

Reference Counting. Reference counting: a way to know whether a record has other users

Reference Counting. Reference counting: a way to know whether a record has other users Garbage Collection Today: various garbage collection strategies; basic ideas: Allocate until we run out of space; then try to free stuff Invariant: only the PL implementation (runtime system) knows about

More information

Compilers. 8. Run-time Support. Laszlo Böszörmenyi Compilers Run-time - 1

Compilers. 8. Run-time Support. Laszlo Böszörmenyi Compilers Run-time - 1 Compilers 8. Run-time Support Laszlo Böszörmenyi Compilers Run-time - 1 Run-Time Environment A compiler needs an abstract model of the runtime environment of the compiled code It must generate code for

More information

DD2460 Software Safety and Security: Part III Exercises session 2: Type + Jif

DD2460 Software Safety and Security: Part III Exercises session 2: Type + Jif DD2460 Software Safety and Security: Part III Exercises session 2: Type + Jif Gurvan Le Guernic adapted from Aslan Askarov DD2460 (III, E2) February 22 st, 2012 1 Noninterference type systems challenge

More information

Garbage Collection. Hwansoo Han

Garbage Collection. Hwansoo Han Garbage Collection Hwansoo Han Heap Memory Garbage collection Automatically reclaim the space that the running program can never access again Performed by the runtime system Two parts of a garbage collector

More information

MEMORY MANAGEMENT HEAP, STACK AND GARBAGE COLLECTION

MEMORY MANAGEMENT HEAP, STACK AND GARBAGE COLLECTION MEMORY MANAGEMENT HEAP, STACK AND GARBAGE COLLECTION 2 1. What is the Heap Size: 2 2. What is Garbage Collection: 3 3. How are Java objects stored in memory? 3 4. What is the difference between stack and

More information

Lecture Notes on Garbage Collection

Lecture Notes on Garbage Collection Lecture Notes on Garbage Collection 15-411: Compiler Design André Platzer Lecture 20 1 Introduction In the previous lectures we have considered a programming language C0 with pointers and memory and array

More information

A Certified Non-Interference Java Bytecode Verifier

A Certified Non-Interference Java Bytecode Verifier 1 A Certified Non-Interference Java Bytecode Verifier G. Barthe, D. Pichardie and T. Rezk, A Certified ightweight Non-Interference Java Bytecode Verifier, ESOP'07 2 Motivations 1: bytecode verification

More information

Compiler Construction

Compiler Construction Compiler Construction Thomas Noll Software Modeling and Verification Group RWTH Aachen University https://moves.rwth-aachen.de/teaching/ss-16/cc/ Recap: Static Data Structures Outline of Lecture 18 Recap:

More information

SECOMP Efficient Formally Secure Compilers to a Tagged Architecture. Cătălin Hrițcu INRIA Paris

SECOMP Efficient Formally Secure Compilers to a Tagged Architecture. Cătălin Hrițcu INRIA Paris SECOMP Efficient Formally Secure Compilers to a Tagged Architecture Cătălin Hrițcu INRIA Paris 1 SECOMP Efficient Formally Secure Compilers to a Tagged Architecture Cătălin Hrițcu INRIA Paris 5 year vision

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

Acknowledgements These slides are based on Kathryn McKinley s slides on garbage collection as well as E Christopher Lewis s slides

Acknowledgements These slides are based on Kathryn McKinley s slides on garbage collection as well as E Christopher Lewis s slides Garbage Collection Last time Compiling Object-Oriented Languages Today Motivation behind garbage collection Garbage collection basics Garbage collection performance Specific example of using GC in C++

More information

2. Introducing Classes

2. Introducing Classes 1 2. Introducing Classes Class is a basis of OOP languages. It is a logical construct which defines shape and nature of an object. Entire Java is built upon classes. 2.1 Class Fundamentals Class can be

More information

Formal methods for software security

Formal methods for software security Formal methods for software security Thomas Jensen, INRIA Forum "Méthodes formelles" Toulouse, 31 January 2017 Formal methods for software security Formal methods for software security Confidentiality

More information

Configuring the Heap and Garbage Collector for Real- Time Programming.

Configuring the Heap and Garbage Collector for Real- Time Programming. Configuring the Heap and Garbage Collector for Real- Time Programming.... A user s perspective to garbage collection Fridtjof Siebert, IPD, University of Karlsruhe 1 Jamaica Systems Structure What is the

More information

Java Performance Tuning

Java Performance Tuning 443 North Clark St, Suite 350 Chicago, IL 60654 Phone: (312) 229-1727 Java Performance Tuning This white paper presents the basics of Java Performance Tuning and its preferred values for large deployments

More information

CONTENTS: Array Usage Multi-Dimensional Arrays Reference Types. COMP-202 Unit 6: Arrays

CONTENTS: Array Usage Multi-Dimensional Arrays Reference Types. COMP-202 Unit 6: Arrays CONTENTS: Array Usage Multi-Dimensional Arrays Reference Types COMP-202 Unit 6: Arrays Introduction (1) Suppose you want to write a program that asks the user to enter the numeric final grades of 350 COMP-202

More information

Compiler Construction

Compiler Construction Compiler Construction Lecture 18: Code Generation V (Implementation of Dynamic Data Structures) Thomas Noll Lehrstuhl für Informatik 2 (Software Modeling and Verification) noll@cs.rwth-aachen.de http://moves.rwth-aachen.de/teaching/ss-14/cc14/

More information

CA341 - Comparative Programming Languages

CA341 - Comparative Programming Languages CA341 - Comparative Programming Languages David Sinclair Dynamic Data Structures Generally we do not know how much data a program will have to process. There are 2 ways to handle this: Create a fixed data

More information

CSE 307: Principles of Programming Languages

CSE 307: Principles of Programming Languages CSE 307: Principles of Programming Languages Variables and Constants R. Sekar 1 / 22 Topics 2 / 22 Variables and Constants Variables are stored in memory, whereas constants need not be. Value of variables

More information

Security for Multithreaded Programs under Cooperative Scheduling

Security for Multithreaded Programs under Cooperative Scheduling Security for Multithreaded Programs under Cooperative Scheduling Alejandro Russo and Andrei Sabelfeld Dept. of Computer Science and Engineering, Chalmers University of Technology 412 96 Göteborg, Sweden,

More information

A Side-channel Attack on HotSpot Heap Management. Xiaofeng Wu, Kun Suo, Yong Zhao, Jia Rao The University of Texas at Arlington

A Side-channel Attack on HotSpot Heap Management. Xiaofeng Wu, Kun Suo, Yong Zhao, Jia Rao The University of Texas at Arlington A Side-channel Attack on HotSpot Heap Management Xiaofeng Wu, Kun Suo, Yong Zhao, Jia Rao The University of Texas at Arlington HotCloud 18 July 9, 2018 1 Side-Channel Attack Attack based on information

More information

JVM Troubleshooting MOOC: Troubleshooting Memory Issues in Java Applications

JVM Troubleshooting MOOC: Troubleshooting Memory Issues in Java Applications JVM Troubleshooting MOOC: Troubleshooting Memory Issues in Java Applications Poonam Parhar JVM Sustaining Engineer Oracle Lesson 1 HotSpot JVM Memory Management Poonam Parhar JVM Sustaining Engineer Oracle

More information

Qualifying Exam in Programming Languages and Compilers

Qualifying Exam in Programming Languages and Compilers Qualifying Exam in Programming Languages and Compilers University of Wisconsin Fall 1991 Instructions This exam contains nine questions, divided into two parts. All students taking the exam should answer

More information

Arrays. Returning arrays Pointers Dynamic arrays Smart pointers Vectors

Arrays. Returning arrays Pointers Dynamic arrays Smart pointers Vectors Arrays Returning arrays Pointers Dynamic arrays Smart pointers Vectors To declare an array specify the type, its name, and its size in []s int arr1[10]; //or int arr2[] = {1,2,3,4,5,6,7,8}; arr2 has 8

More information

Managed runtimes & garbage collection. CSE 6341 Some slides by Kathryn McKinley

Managed runtimes & garbage collection. CSE 6341 Some slides by Kathryn McKinley Managed runtimes & garbage collection CSE 6341 Some slides by Kathryn McKinley 1 Managed runtimes Advantages? Disadvantages? 2 Managed runtimes Advantages? Reliability Security Portability Performance?

More information

Programming II (CS300)

Programming II (CS300) 1 Programming II (CS300) Chapter 02: Using Objects MOUNA KACEM mouna@cs.wisc.edu Fall 2018 Using Objects 2 Introduction to Object Oriented Programming Paradigm Objects and References Memory Management

More information

What goes inside when you declare a variable?

What goes inside when you declare a variable? Stack, heap, value types, reference types, boxing, and unboxing Introduction This article will explain six important concepts: stack, heap, value types, reference types, boxing, and unboxing. This article

More information

CS111: PROGRAMMING LANGUAGE II

CS111: PROGRAMMING LANGUAGE II CS111: PROGRAMMING LANGUAGE II Computer Science Department Lecture 1(c): Java Basics (II) Lecture Contents Java basics (part II) Conditions Loops Methods Conditions & Branching Conditional Statements A

More information

CS 415 Midterm Exam Fall 2003

CS 415 Midterm Exam Fall 2003 CS 415 Midterm Exam Fall 2003 Name KEY Email Address Student ID # Pledge: This exam is closed note, closed book. Questions will be graded on quality of answer. Please supply the best answer you can to

More information

Hard Real-Time Garbage Collection in Java Virtual Machines

Hard Real-Time Garbage Collection in Java Virtual Machines Hard Real-Time Garbage Collection in Java Virtual Machines... towards unrestricted real-time programming in Java Fridtjof Siebert, IPD, University of Karlsruhe 1 Jamaica Systems Structure Exisiting GC

More information

Java Internals. Frank Yellin Tim Lindholm JavaSoft

Java Internals. Frank Yellin Tim Lindholm JavaSoft Java Internals Frank Yellin Tim Lindholm JavaSoft About This Talk The JavaSoft implementation of the Java Virtual Machine (JDK 1.0.2) Some companies have tweaked our implementation Alternative implementations

More information

Project. there are a couple of 3 person teams. a new drop with new type checking is coming. regroup or see me or forever hold your peace

Project. there are a couple of 3 person teams. a new drop with new type checking is coming. regroup or see me or forever hold your peace Project there are a couple of 3 person teams regroup or see me or forever hold your peace a new drop with new type checking is coming using it is optional 1 Compiler Architecture source code Now we jump

More information

Structure of Programming Languages Lecture 10

Structure of Programming Languages Lecture 10 Structure of Programming Languages Lecture 10 CS 6636 4536 Spring 2017 CS 6636 4536 Lecture 10: Classes... 1/23 Spring 2017 1 / 23 Outline 1 1. Types Type Coercion and Conversion Type Classes, Generics,

More information

Profiling & Optimization

Profiling & Optimization Lecture 18 Sources of Game Performance Issues? 2 Avoid Premature Optimization Novice developers rely on ad hoc optimization Make private data public Force function inlining Decrease code modularity removes

More information

High-Level Language VMs

High-Level Language VMs High-Level Language VMs Outline Motivation What is the need for HLL VMs? How are these different from System or Process VMs? Approach to HLL VMs Evolutionary history Pascal P-code Object oriented HLL VMs

More information

Managed runtimes & garbage collection

Managed runtimes & garbage collection Managed runtimes Advantages? Managed runtimes & garbage collection CSE 631 Some slides by Kathryn McKinley Disadvantages? 1 2 Managed runtimes Portability (& performance) Advantages? Reliability Security

More information

Habanero Extreme Scale Software Research Project

Habanero Extreme Scale Software Research Project Habanero Extreme Scale Software Research Project Comp215: Garbage Collection Zoran Budimlić (Rice University) Adapted from Keith Cooper s 2014 lecture in COMP 215. Garbage Collection In Beverly Hills...

More information

Lecture 14. No in-class files today. Homework 7 (due on Wednesday) and Project 3 (due in 10 days) posted. Questions?

Lecture 14. No in-class files today. Homework 7 (due on Wednesday) and Project 3 (due in 10 days) posted. Questions? Lecture 14 No in-class files today. Homework 7 (due on Wednesday) and Project 3 (due in 10 days) posted. Questions? Friday, February 11 CS 215 Fundamentals of Programming II - Lecture 14 1 Outline Static

More information

G Programming Languages - Fall 2012

G Programming Languages - Fall 2012 G22.2110-003 Programming Languages - Fall 2012 Lecture 2 Thomas Wies New York University Review Last week Programming Languages Overview Syntax and Semantics Grammars and Regular Expressions High-level

More information

1.3 Conditionals and Loops

1.3 Conditionals and Loops 1 1.3 Conditionals and Loops any program you might want to write objects functions and modules graphics, sound, and image I/O arrays conditionals and loops to infinity and beyond Math primitive data types

More information

Other conditional and loop constructs. Fundamentals of Computer Science Keith Vertanen

Other conditional and loop constructs. Fundamentals of Computer Science Keith Vertanen Other conditional and loop constructs Fundamentals of Computer Science Keith Vertanen Overview Current loop constructs: for, while, do-while New loop constructs Get out of loop early: break Skip rest of

More information

20 Most Important Java Programming Interview Questions. Powered by

20 Most Important Java Programming Interview Questions. Powered by 20 Most Important Java Programming Interview Questions Powered by 1. What's the difference between an interface and an abstract class? An abstract class is a class that is only partially implemented by

More information

CS 241 Honors Memory

CS 241 Honors Memory CS 241 Honors Memory Ben Kurtovic Atul Sandur Bhuvan Venkatesh Brian Zhou Kevin Hong University of Illinois Urbana Champaign February 20, 2018 CS 241 Course Staff (UIUC) Memory February 20, 2018 1 / 35

More information

Name, Scope, and Binding. Outline [1]

Name, Scope, and Binding. Outline [1] Name, Scope, and Binding In Text: Chapter 3 Outline [1] Variable Binding Storage bindings and lifetime Type bindings Type Checking Scope Lifetime vs. Scope Referencing Environments N. Meng, S. Arthur 2

More information

CS 430 Spring Mike Lam, Professor. Data Types and Type Checking

CS 430 Spring Mike Lam, Professor. Data Types and Type Checking CS 430 Spring 2015 Mike Lam, Professor Data Types and Type Checking Type Systems Type system Rules about valid types, type compatibility, and how data values can be used Benefits of a robust type system

More information

Dynamic Dependency Monitoring to Secure Information Flow

Dynamic Dependency Monitoring to Secure Information Flow Dynamic Dependency Monitoring to Secure Information Flow Mark Thober Joint work with Paritosh Shroff and Scott F. Smith Department of Computer Science Johns Hopkins University CSF 07 1 Motivation Information

More information

Heap Compression for Memory-Constrained Java

Heap Compression for Memory-Constrained Java Heap Compression for Memory-Constrained Java CSE Department, PSU G. Chen M. Kandemir N. Vijaykrishnan M. J. Irwin Sun Microsystems B. Mathiske M. Wolczko OOPSLA 03 October 26-30 2003 Overview PROBLEM:

More information

Manual Allocation. CS 1622: Garbage Collection. Example 1. Memory Leaks. Example 3. Example 2 11/26/2012. Jonathan Misurda

Manual Allocation. CS 1622: Garbage Collection. Example 1. Memory Leaks. Example 3. Example 2 11/26/2012. Jonathan Misurda Manual llocation Dynamic memory allocation is an obvious necessity in a programming environment. S 1622: Garbage ollection Many programming languages expose some functions or keywords to manage runtime

More information

Profiling & Optimization

Profiling & Optimization Lecture 11 Sources of Game Performance Issues? 2 Avoid Premature Optimization Novice developers rely on ad hoc optimization Make private data public Force function inlining Decrease code modularity removes

More information

Java Programming Tutorial 1

Java Programming Tutorial 1 Java Programming Tutorial 1 Every programming language has two defining characteristics: Syntax Semantics Programming Writing code with good style also provides the following benefits: It improves the

More information

Agenda. CSE P 501 Compilers. Java Implementation Overview. JVM Architecture. JVM Runtime Data Areas (1) JVM Data Types. CSE P 501 Su04 T-1

Agenda. CSE P 501 Compilers. Java Implementation Overview. JVM Architecture. JVM Runtime Data Areas (1) JVM Data Types. CSE P 501 Su04 T-1 Agenda CSE P 501 Compilers Java Implementation JVMs, JITs &c Hal Perkins Summer 2004 Java virtual machine architecture.class files Class loading Execution engines Interpreters & JITs various strategies

More information

CSE 373 OCTOBER 23 RD MEMORY AND HARDWARE

CSE 373 OCTOBER 23 RD MEMORY AND HARDWARE CSE 373 OCTOBER 23 RD MEMORY AND HARDWARE MEMORY ANALYSIS Similar to runtime analysis MEMORY ANALYSIS Similar to runtime analysis Consider the worst case MEMORY ANALYSIS Similar to runtime analysis Rather

More information

Chapter 1 Getting Started

Chapter 1 Getting Started Chapter 1 Getting Started The C# class Just like all object oriented programming languages, C# supports the concept of a class. A class is a little like a data structure in that it aggregates different

More information

CSE 100: C++ TEMPLATES AND ITERATORS

CSE 100: C++ TEMPLATES AND ITERATORS CSE 100: C++ TEMPLATES AND ITERATORS Announcements iclickers: Please register at ted.ucsd.edu. Start ASAP!! For PA1 (Due next week). 10/6 grading and 10/8 regrading How is Assignment 1 going? A. I haven

More information

Learning is Change in Knowledge: Knowledge-based Security for Dynamic Policies

Learning is Change in Knowledge: Knowledge-based Security for Dynamic Policies Learning is Change in Knowledge: Knowledge-based Security for Dynamic Policies Aslan Askarov and Stephen Chong TR-02-12 Computer Science Group Harvard University Cambridge, Massachusetts Learning is Change

More information

Exploiting the Behavior of Generational Garbage Collector

Exploiting the Behavior of Generational Garbage Collector Exploiting the Behavior of Generational Garbage Collector I. Introduction Zhe Xu, Jia Zhao Garbage collection is a form of automatic memory management. The garbage collector, attempts to reclaim garbage,

More information

Garbage Collection. Akim D le, Etienne Renault, Roland Levillain. May 15, CCMP2 Garbage Collection May 15, / 35

Garbage Collection. Akim D le, Etienne Renault, Roland Levillain. May 15, CCMP2 Garbage Collection May 15, / 35 Garbage Collection Akim Demaille, Etienne Renault, Roland Levillain May 15, 2017 CCMP2 Garbage Collection May 15, 2017 1 / 35 Table of contents 1 Motivations and Definitions 2 Reference Counting Garbage

More information

Memory management COSC346

Memory management COSC346 Memory management COSC346 Life cycle of an object Create a reference pointer Allocate memory for the object Initialise internal data Do stuff Destroy the object Release memory 2 Constructors and destructors

More information

Runtime. The optimized program is ready to run What sorts of facilities are available at runtime

Runtime. The optimized program is ready to run What sorts of facilities are available at runtime Runtime The optimized program is ready to run What sorts of facilities are available at runtime Compiler Passes Analysis of input program (front-end) character stream Lexical Analysis token stream Syntactic

More information

CS313D: ADVANCED PROGRAMMING LANGUAGE

CS313D: ADVANCED PROGRAMMING LANGUAGE CS313D: ADVANCED PROGRAMMING LANGUAGE Computer Science Department Lecture 3: C# language basics Lecture Contents 2 C# basics Conditions Loops Methods Arrays Dr. Amal Khalifa, Spr 2015 3 Conditions and

More information

Introducing C++ to Java Programmers

Introducing C++ to Java Programmers Introducing C++ to Java Programmers by Kip Irvine updated 2/27/2003 1 Philosophy of C++ Bjarne Stroustrup invented C++ in the early 1980's at Bell Laboratories First called "C with classes" Design Goals:

More information

variables hold values (e.g., int, double, char) Primitive and Object Variables Primitive Types Primitive Types Summer 2010 Margaret Reid-Miller

variables hold values (e.g., int, double, char) Primitive and Object Variables Primitive Types Primitive Types Summer 2010 Margaret Reid-Miller Primitive and Object Variables 15-110 Summer 2010 Margaret Reid-Miller variables hold values (e.g., int, double, char) Summer 2009 15-100 (Reid-Miller) 2 Variables of primitive types a storage location

More information

DNWSH - Version: 2.3..NET Performance and Debugging Workshop

DNWSH - Version: 2.3..NET Performance and Debugging Workshop DNWSH - Version: 2.3.NET Performance and Debugging Workshop .NET Performance and Debugging Workshop DNWSH - Version: 2.3 8 days Course Description: The.NET Performance and Debugging Workshop is a practical

More information

1.3 Conditionals and Loops. 1.3 Conditionals and Loops. Conditionals and Loops

1.3 Conditionals and Loops. 1.3 Conditionals and Loops. Conditionals and Loops 1.3 Conditionals and Loops any program you might want to write objects functions and modules graphics, sound, and image I/O arrays conditionals and loops Math primitive data types text I/O assignment statements

More information

Runtime Application Self-Protection (RASP) Performance Metrics

Runtime Application Self-Protection (RASP) Performance Metrics Product Analysis June 2016 Runtime Application Self-Protection (RASP) Performance Metrics Virtualization Provides Improved Security Without Increased Overhead Highly accurate. Easy to install. Simple to

More information

CPSC 213. Introduction to Computer Systems. Instance Variables and Dynamic Allocation. Unit 1c

CPSC 213. Introduction to Computer Systems. Instance Variables and Dynamic Allocation. Unit 1c CPSC 213 Introduction to Computer Systems Unit 1c Instance Variables and Dynamic Allocation 1 Reading For Next 3 Lectures Companion 2.4.4-2.4.5 Textbook Structures, Dynamic Memory Allocation, Understanding

More information

Glacier: A Garbage Collection Simulation System

Glacier: A Garbage Collection Simulation System Glacier: A Garbage Collection Simulation System Bruno Dufour Sable Research Group McGill University Glacier: A Garbage Collection Simulation System p.1/19 Outline Introduction Objectives & motivation Requirements

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

Algorithms for Dynamic Memory Management (236780) Lecture 4. Lecturer: Erez Petrank

Algorithms for Dynamic Memory Management (236780) Lecture 4. Lecturer: Erez Petrank Algorithms for Dynamic Memory Management (236780) Lecture 4 Lecturer: Erez Petrank!1 March 24, 2014 Topics last week The Copying Garbage Collector algorithm: Basics Cheney s collector Additional issues:

More information

From dynamic to static and back: Riding the roller coaster of information-flow control research

From dynamic to static and back: Riding the roller coaster of information-flow control research From dynamic to static and back: Riding the roller coaster of information-flow control research Andrei Sabelfeld and Alejandro Russo Dept. of Computer Science and Engineering, Chalmers University of Technology

More information

Running class Timing on Java HotSpot VM, 1

Running class Timing on Java HotSpot VM, 1 Compiler construction 2009 Lecture 3. A first look at optimization: Peephole optimization. A simple example A Java class public class A { public static int f (int x) { int r = 3; int s = r + 5; return

More information

6.172 Performance Engineering of Software Systems Spring Lecture 9. P after. Figure 1: A diagram of the stack (Image by MIT OpenCourseWare.

6.172 Performance Engineering of Software Systems Spring Lecture 9. P after. Figure 1: A diagram of the stack (Image by MIT OpenCourseWare. 6.172 Performance Engineering of Software Systems Spring 2009 Lecture 9 MIT OpenCourseWare Dynamic Storage Allocation Stack allocation: LIFO (last-in-first-out) Array and pointer A used unused P before

More information

Hardware-Supported Pointer Detection for common Garbage Collections

Hardware-Supported Pointer Detection for common Garbage Collections 2013 First International Symposium on Computing and Networking Hardware-Supported Pointer Detection for common Garbage Collections Kei IDEUE, Yuki SATOMI, Tomoaki TSUMURA and Hiroshi MATSUO Nagoya Institute

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

1.3 Conditionals and Loops

1.3 Conditionals and Loops .3 Conditionals and Loops Introduction to Programming in Java: An Interdisciplinary Approach Robert Sedgewick and Kevin Wayne Copyright 2008 February 04, 2008 0:00 AM A Foundation for Programming A Foundation

More information

Last week. Data on the stack is allocated automatically when we do a function call, and removed when we return

Last week. Data on the stack is allocated automatically when we do a function call, and removed when we return Last week Data can be allocated on the stack or on the heap (aka dynamic memory) Data on the stack is allocated automatically when we do a function call, and removed when we return f() {... int table[len];...

More information

CS558 Programming Languages

CS558 Programming Languages CS558 Programming Languages Winter 2017 Lecture 4a Andrew Tolmach Portland State University 1994-2017 Semantics and Erroneous Programs Important part of language specification is distinguishing valid from

More information

C#.Net. Course Contents. Course contents VT BizTalk. No exam, but laborations

C#.Net. Course Contents. Course contents VT BizTalk. No exam, but laborations , 1 C#.Net VT 2009 Course Contents C# 6 hp approx. BizTalk 1,5 hp approx. No exam, but laborations Course contents Architecture Visual Studio Syntax Classes Forms Class Libraries Inheritance Other C# essentials

More information

CS 31: Intro to Systems Pointers and Memory. Kevin Webb Swarthmore College October 2, 2018

CS 31: Intro to Systems Pointers and Memory. Kevin Webb Swarthmore College October 2, 2018 CS 31: Intro to Systems Pointers and Memory Kevin Webb Swarthmore College October 2, 2018 Overview How to reference the location of a variable in memory Where variables are placed in memory How to make

More information

INITIALISING POINTER VARIABLES; DYNAMIC VARIABLES; OPERATIONS ON POINTERS

INITIALISING POINTER VARIABLES; DYNAMIC VARIABLES; OPERATIONS ON POINTERS INITIALISING POINTER VARIABLES; DYNAMIC VARIABLES; OPERATIONS ON POINTERS Pages 792 to 800 Anna Rakitianskaia, University of Pretoria INITIALISING POINTER VARIABLES Pointer variables are declared by putting

More information

CPSC 319. Week 2 Java Basics. Xiaoyang Liu & Sorting Algorithms

CPSC 319. Week 2 Java Basics. Xiaoyang Liu & Sorting Algorithms CPSC 319 Week 2 Java Basics Xiaoyang Liu xiaoyali@ucalgary.ca & Sorting Algorithms Java Basics Variable Declarations Type Size Range boolean 1 bit true, false char 16 bits Unicode characters byte 8 bits

More information

Announcements. My office hours are today in Gates 160 from 1PM-3PM. Programming Project 3 checkpoint due tomorrow night at 11:59PM.

Announcements. My office hours are today in Gates 160 from 1PM-3PM. Programming Project 3 checkpoint due tomorrow night at 11:59PM. IR Generation Announcements My office hours are today in Gates 160 from 1PM-3PM. Programming Project 3 checkpoint due tomorrow night at 11:59PM. This is a hard deadline and no late submissions will be

More information

Garbage Collection Algorithms. Ganesh Bikshandi

Garbage Collection Algorithms. Ganesh Bikshandi Garbage Collection Algorithms Ganesh Bikshandi Announcement MP4 posted Term paper posted Introduction Garbage : discarded or useless material Collection : the act or process of collecting Garbage collection

More information

Introduction. C provides two styles of flow control:

Introduction. C provides two styles of flow control: Introduction C provides two styles of flow control: Branching Looping Branching is deciding what actions to take and looping is deciding how many times to take a certain action. Branching constructs: if

More information

CMSC 330: Organization of Programming Languages

CMSC 330: Organization of Programming Languages CMSC 330: Organization of Programming Languages Memory Management and Garbage Collection CMSC 330 - Spring 2013 1 Memory Attributes! Memory to store data in programming languages has the following lifecycle

More information

CSCI-1200 Data Structures Fall 2011 Lecture 24 Garbage Collection & Smart Pointers

CSCI-1200 Data Structures Fall 2011 Lecture 24 Garbage Collection & Smart Pointers CSCI-1200 Data Structures Fall 2011 Lecture 24 Garbage Collection & Smart Pointers Review from Lecture 23 Basic exception mechanisms: try/throw/catch Functions & exceptions, constructors & exceptions Today

More information

2. Reachability in garbage collection is just an approximation of garbage.

2. Reachability in garbage collection is just an approximation of garbage. symbol tables were on the first exam of this particular year's exam. We did not discuss register allocation in this This exam has questions from previous CISC 471/672. particular year. Not all questions

More information

Lecture Conservative Garbage Collection. 3.2 Precise Garbage Collectors. 3.3 Other Garbage Collection Techniques

Lecture Conservative Garbage Collection. 3.2 Precise Garbage Collectors. 3.3 Other Garbage Collection Techniques CMPSCI 691ST Systems Fall 2011 Lecture 3 Lecturer: Emery Berger Scribe: Nicolas Scarrci 3.1 Conservative Garbage Collection The Boehm collector is the first example of conservative garbage collection.

More information

INF 212 ANALYSIS OF PROG. LANGS FUNCTION COMPOSITION. Instructors: Crista Lopes Copyright Instructors.

INF 212 ANALYSIS OF PROG. LANGS FUNCTION COMPOSITION. Instructors: Crista Lopes Copyright Instructors. INF 212 ANALYSIS OF PROG. LANGS FUNCTION COMPOSITION Instructors: Crista Lopes Copyright Instructors. Topics Recursion Higher-order functions Continuation-Passing Style Monads (take 1) Identity Monad Maybe

More information

NUMA in High-Level Languages. Patrick Siegler Non-Uniform Memory Architectures Hasso-Plattner-Institut

NUMA in High-Level Languages. Patrick Siegler Non-Uniform Memory Architectures Hasso-Plattner-Institut NUMA in High-Level Languages Non-Uniform Memory Architectures Hasso-Plattner-Institut Agenda. Definition of High-Level Language 2. C# 3. Java 4. Summary High-Level Language Interpreter, no directly machine

More information

CMSC 330: Organization of Programming Languages. Operational Semantics

CMSC 330: Organization of Programming Languages. Operational Semantics CMSC 330: Organization of Programming Languages Operational Semantics Notes about Project 4, Parts 1 & 2 Still due today (7/2) Will not be graded until 7/11 (along with Part 3) You are strongly encouraged

More information