Project Citadel: Methods, Data, and Moving Forward Behram Mistree - - PowerPoint PPT Presentation

project citadel methods data and moving forward
SMART_READER_LITE
LIVE PREVIEW

Project Citadel: Methods, Data, and Moving Forward Behram Mistree - - PowerPoint PPT Presentation

Project Citadel: Methods, Data, and Moving Forward Behram Mistree Project Citadel: Goal Goal: to discover patterns in code and coding behavior that motivate features in a new virtual world scripting language Outline Citadel Methods


slide-1
SLIDE 1

Project Citadel: Methods, Data, and Moving Forward

Behram Mistree

slide-2
SLIDE 2

Project Citadel: Goal

Goal: to discover patterns in code and coding behavior that motivate features in a new virtual world scripting language

slide-3
SLIDE 3

Outline

  • Citadel Methods
  • Preliminary Data
  • Moving Forward
  • Lessons Learning
slide-4
SLIDE 4

Methodology: Keylogger

  • Cross-platform addons to Emacs (E-Lisp) and

Eclipse (Java)

  • Logs:

1.Any change to a document 2.(Most) Causes of changes (paste/yank, undo, keypress, auto-complete (eclipse), etc.) 3.When change occurred

slide-5
SLIDE 5

Methodology: Subjects

  • Logging running on multiple subjects
slide-6
SLIDE 6

Methodology: Subjects

  • Logging running on multiple subjects
slide-7
SLIDE 7

Ewen's Data

  • Spans 1.5 Weeks:
  • 451 files opened/modified
  • .html, .h, .hpp, .txt, .cpp, .py, .sh, .tex, etc.
slide-8
SLIDE 8
slide-9
SLIDE 9

File Focus

  • /home/ewencp/libprox.git/proxsim/src/Simulator.cpp

19,736 opens/modifies

  • /home/ewencp/sirikata.sirikata/space/src/Proximity.cpp

17,739 opens/modifies

slide-10
SLIDE 10

Methodology: Function Finding

  • To get beginning of function, lex for function

definition*

  • Count number of open and closed braces until

all braces match or see beginning of new function.

slide-11
SLIDE 11

Methodology: Function Finding (ctd)

  • Works for a subset of languages (curly brace

dependent).

  • Currently only works for class definitions
  • Includes commented/stringed code
  • Ignores macros
  • May have a function definition inside a string
  • Unterminated/incorrectly terminated functions

incorrectly padded

  • Loses if changes happen to function signature
slide-12
SLIDE 12

Function Finding: How Well Did it Do?

"void Proximity::handleCheckObjectClass(constUUID) {" "void Proximity::handleCheckObjectClass(con) {" "void Proximity::proxSubstreamCallback(int x, ProxStreamPtr streaProxStreamPtr substream, ProxStreamInfo* prox_stream_info) {" "void Proximity::tickQueryHandler(ProxQueryHandler* qh[NUM_OBJECT_CLASSES) {" "void Proximity::proxSubstreamCallback(int x, ProxStreamPtr stream, ProxStreamPtr substream, ProxStreamInfo* prox_stream_info) {" "void Proximity::handleCheckObjectClass(bool is_) {" "std::string Proximity::migrationClientTag() {" "void Proximity::proxSubstreamCallback(int x, ProxStrProxStreamPtr substream, ProxStreamInfo* prox_stream_info) {" "void Proximity::proxSubstreamCallback(int x, ProxStreamPtr stream,ProxStreamPtr substream, ProxStreamInfo* prox_stream_info) {" "void Proximity::proxSubstreamCallback(int x, ProxStreamProxStreamPtr substream, ProxStreamInfo* prox_stream_info) {" "void Proximity::removeQuery(UUID obj) {" …

Caught them all.

slide-13
SLIDE 13

Hotspots

slide-14
SLIDE 14

Why Not Static Analysis?

Selected functions from Proximity.cpp and Simulator.cpp: ID # characters of code # “edits” to function body 1 315 7632 2 82 8149 3 793 7397 4 359 4708 1: Proximity.cpp: "void Proximity::initialize(CoordinateSegmentation* cseg) {" 2: Simulator.cpp: "Simulator::QueryIterator Simulator::queriesBegin() {" 3: Simulator.cpp "void Simulator::shutdown() {" 4: Simulator.cpp "void Simulator::createMotionCSVObjects(const std::string csvfile, int nobjects) {"

slide-15
SLIDE 15

Write and Return

<Thinking of a way of presenting data> Ewen Subject often writes and returns

  • Writes/modifies function, A, once
  • Performs task in other section of code base
  • Returns to A, and modifies it.

Studies often do not consider this behavior when analyzing programming.

slide-16
SLIDE 16

Moving Forward: Deployment

  • 4 emacs keyloggers deployed and ~10 subjects

in introductory CS Courses.

  • Another round of deployment in Winter Quarter.
slide-17
SLIDE 17

Moving Forward: Visualization

slide-18
SLIDE 18

Moving Forward: Visualization

slide-19
SLIDE 19

Moving Forward: Analysis

  • What features/type of code is in the “difficult”

functions? (Eg. asynchronous/recursive/?)

  • Sub-function resolution?
  • What features/type of code is in the “easy”

functions?

  • What type of feedback could we give in real-

time to programmer?

  • What type of feedback could we give in non-

real time to programmer?

slide-20
SLIDE 20

Lessons Learning: Subject Recruitment

  • Have something potential subjects can do there
  • Signup sheet >> “You should visit this website, and

sign up there!”

slide-21
SLIDE 21

Lessons Learning: Subject Recruitment

  • Have something potential subjects can do there
  • Signup sheet >> “You should visit this website, and

sign up there!”

  • Have a shill
slide-22
SLIDE 22

Lessons Learning: Subject Recruitment

  • Have something potential subjects can do there
  • Signup sheet >> “You should visit this website, and

sign up there!”

  • Have a shill
  • More potential subjects will approach you if they

see someone else at your table

  • More potential subjects sign up if there are already

names on signup sheet

slide-23
SLIDE 23

Lessons Learning: Subject Recruitment

  • Have something potential subjects can do there
  • Signup sheet >> “You should visit this website, and

sign up there!”

  • Have a shill
  • More potential subjects will approach you if they

see someone else at your table (it's okay to give away candy to non-subjects)

  • More potential subjects sign up if there are already

names on signup sheet

slide-24
SLIDE 24

Lessons Learning: Subject Recruitment

  • Make them come to you
  • Too easy to ignore if directly on path
slide-25
SLIDE 25

Lessons Learning: Subject Recruitment

  • Make them come to you
  • Too easy to ignore if directly on path
  • Don't get discouraged