1. Problems
Tao He
elfinhe@gmail.com
@SELAB, SYSU
2010,May
About 90 minutes
1/20
2. Themes
Hackerdom
Programming Languages
2/49
3. Fascinating Problems
“The world is full of fascinating
problems waiting to be solved.”
Eric Raymond, How to become a hacker
Eric Raymond. How To Become A Hacker. http://catb.org/~esr/faqs/hacker-howto.html
Eric Raymond. The Cathedral and the Bazaar. http://catb.org/esr/writings/homesteading/
3/49
4. Hacker
Not Cracker, But Creator
Eager to Communicate
4/49
5. FLOSS community
Not only Free Source
But an Efficiency Way
to Communicate, Study and Work
Tashi
“Talk is cheap. Show me the code.” Linus
FLOSS: Free-Libre and Open Source Software
5/49
6. IF NOT OPEN?
Information Inequality
Esoterica
Design Patterns
No Feedback
Herbert Schiller. Information Inequality: The Deepening Social Crisis in America, Routledge 1995, ISBN 0415907659
6/49
7. KISS: Keep It Simple and Stupid
“Perfection (in design) is achieved not when
there is nothing more to add, but rather when
there is nothing more to take away.”
Linux
Fid
Process
Memory
Design Patterns
7/49
13. Themes
Hackerdom
Programming Languages
13/49
14. Why we use Programming
Languages?
For customers
To meet their requirements. ( For example , OA
systems)
For machine ( Von Neumann Architecture )
Instruction flow
Data
Strange, isn’t it ?
14/49
15. Other Problems
Common Elements in High-Level
Languages?
Dynamic ?
Syntax, Semantics and Pragmatics ?
Semantics and Logic?
15/49
17. Assembler Language
Macro of Machine Code
While Programming
Registers
Data Seg
Code Seg
Stack Seg
Von Neumann Architecture
Instruction fetch
Instruction execute
17/49
18. We have Data Seg already.
Why we need Stack Seg ?
Modules
But Stack is manual
18/49
19. Why we need Modules ?
Recursion
Reusability
Scope Encapsulation
19/49
22. What’s NEW in C
Expressions (Formal Languages,
Automaton )
For Instruction
Arithmetic Expressions ( 3+2-5*3 )
Control Flow Expressions ( for, if…else…, )
Function Expressions
For Data
Type System
Atom
Structure
We have a Compiler now
22/49
23. Advantages from Expressions
Human
For Instruction
Arithmetic Expressions ( 3+2-5*3 )
Control Flow Expressions ( for, if…else…, )
Function Expressions
For Data
Type System
Atom
Structure
23/49
31. C++ want to be as Efficiency as C
It’s all right for Procedural and ADT
But not for OO with Virtual
No Run-time Hierarchies Meta-data for
Polymorphism
31/49
35. Compile-time vs. Run-time in C++
Compile-time
Inheritance Hierarchies Information
Function Information
Run-time ( Dynamic )
Virtual Function Table
Virtual Base Table
35/49
36. Cross-Platform in C++?
Source-Level: Yes
Cross-Platform is Manual for different OS API
Execution-Level : No
36/49
37. What is not Efficiency C++?
Run-time
Virtual Function
Virtual Inheritance
Virtual Base Class without Virtual Function and
Data will be optimized.
Java can Multiple Implement Interfaces.
Compile-time
Inheritance Hierarchies
37/49
38. The Java Programming Language
Mark Stoodley. Issues in static and dynamic native Java code compilation.
http://www.ibm.com/developerworks/java/library/j-rtj2/index.html
38/49
39. What’s NEW in Java?
JVM
Dynamic Compilation
39/49