master's thesis defense
DESCRIPTION
Presentation slides used for my master's thesis defense on the topic of OCLInt, a static code analysis tool for Objective-C and related languages.TRANSCRIPT
![Page 1: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/1.jpg)
A Static Code Analysis Tool ForObjective-C and Related Languages
Longyi Qi
April 2012
1
Advisor: Dr. Venkat Subramaniam
![Page 2: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/2.jpg)
2
* Image in this slide: Spinellis, D. Code Quality: The Open Source Perspective. (2006). Indianapolis, IN: Addison-Wesley Professional
![Page 3: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/3.jpg)
Outline
• Motivation
• Related Work
• Open Problems• OCLint and What’s Good
• How OCLint Can Help
• Conclusion and Future Work
3
![Page 4: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/4.jpg)
Motivation
4* Image in this slide: Copyright © 2010 Apple Inc.
![Page 5: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/5.jpg)
Related Work
5
![Page 6: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/6.jpg)
Open Problems
• The Objective-C programming language
• Care about code quality
• Continuous Integration
6
![Page 7: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/7.jpg)
Theory Study
• Static Code Analysis Process
• Abstract Syntax Tree (AST)
• Analysis Techniques– Control Flow Analysis– Data Flow Analysis– Dependence Analysis
• Code Smells
7
![Page 8: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/8.jpg)
OCLint
8
![Page 9: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/9.jpg)
Workflow
9
![Page 10: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/10.jpg)
Good Architecture
10
![Page 11: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/11.jpg)
Dynamically Loading Rules
• Dynamic libraries
• Rule search path
11
![Page 12: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/12.jpg)
Configuring & Extending Rules
• Alter thresholds
• Custom rules
12
![Page 13: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/13.jpg)
Smart AST Traversing
• AST is traversed only once and dispatch each node to registered rules
• Intelligent traverse policy
13
![Page 14: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/14.jpg)
High Accuracy and Low False Positive Rate
14
![Page 15: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/15.jpg)
Report
• Support multiple output format
• Meaningful violation message
• As continuous integration artifacts
15
![Page 16: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/16.jpg)
OCLint
• Good architecture
• Dynamically loading rules
• Configuring and extending rules• Smart AST traversing
• High accuracy and low false positive rate
• Report
16
![Page 17: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/17.jpg)
OCLint helps
• Find code smells
• Refactor the code
• Find problems early• Add customer rules if needed
• Integrate into developers’ workflow
17
![Page 18: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/18.jpg)
Conclusion
• A static code analysis tool for Objective-C
• Focus on code quality
• Involve many analysis techniques• Good design
• Positive case study feedback
• Research infrastructure
18
![Page 19: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/19.jpg)
Future Work
• Accuracy and False Positives
• Better Code Quality
• Extended Rules• Compatibility
• Performance
• User Experiences
19
![Page 20: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/20.jpg)
Acknowledgements
20
![Page 21: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/21.jpg)
Questions?
21
![Page 22: Master's Thesis Defense](https://reader033.vdocuments.us/reader033/viewer/2022052508/5594cae61a28abe23c8b4728/html5/thumbnails/22.jpg)
Thank you!
Contact Information:•OCLint Project: http://oclint.org @oclint_project•Longyi Qi: http://longyiqi.com @longyiqi
22