CIS 2750 EXAM STUDY GUIDE
Web App Architecture - ANSWER Parser builds data model for every file, sends those
values to web server, web server stores info from that data model in DB server, Web UI
requests info from web server, web server either pulls that from DB or requests a data
model from parser
Linux Tool Chain - ANSWER sequence of software tools that convert src code to binary
GCC - ANSWER GNU Compiler Collection
CPP - ANSWER C Preprocessor
- interprets all # in .h .and .c files before compiler sees source code
C Compiler - ANSWER compile src into assembly language (.i into .s)
[G]AS - ANSWER Assembler
takes assembly code into object code (.s to .o)
LD - ANSWER Linker
- stitches .o and referenced system libs into bin exe
- static libs are linked here (dynamic are at run time)
LD.SO - ANSWER Loader
- tells OS to execute a program
- OS opens new program and copies segments into virtual memory process
DLOPEN - ANSWER Loader
- Program using dynamically linked libs loaded by ld.so when program starts
Macros in Makefiles - ANSWER $(THING) = flags/files/commands
CC = gcc - ANSWER select GCC compiler as front end
CPPFLAGS - ANSWER -Iinclude_file_dir (absolute)
-I~/myproj/include (relative and takes all system and own)
-Dsymbol (#define but in cmd line)
-DNDEBUG (disable assertions)
,CFLAGS - ANSWER Compiler Flags
-g (save symbols for debugger)
-Wall -std=c11
-fpic
-c
LDFLAGS - ANSWER Linker Flags
-Llib_dir
-L~/myproj/lib
-llibrary
-lfoo
Static lib - ANSWER linked at compile time, inflexible, contents copied into exe
Dynamic lib - ANSWER linked at run time
shared libs
flexible
default irl
Creating shared lib - ANSWER gcc -c prog.c -o prog.o
gcc -shared -o libprog.so prog.o
Creating static lib - ANSWER gcc prog.c prog.o -c
ar prog.o -o prog -lprog
XML - ANSWER Extensible Markup Language
XML Design goals - ANSWER - straightforward to use over internet
- supports lots of apps
- easy to write programs to process XML docs
- human legible, clear
- easy to create docs
- formal and concise
- compatible w/ SGML
, XML strong points - ANSWER - explicit structure for data manipulation
- decouples presentation from data
- can be used to glue together apps
- modular
- text that's not meant to be read
XML Elements - ANSWER If contain other elements, those are child elements
<start tag>content</end tag>
<empty element/>
XML Attributes - ANSWER Must not appear outside of start tags or empty element tags
<example name1="val1" name2="val2">content</example>
<example name="val"/>
XSD - ANSWER XML Schema Definition (came after DTDs)
DTD - ANSWER Document Type Definition
Valgrind - ANSWER memory debugging tool, checks leaks, diagnoses memory errors
Valgrind definitely lost - ANSWER leaking memory --> allocated and never freed
Valgrind indirectly lost - ANSWER leaking memory in pointer based structure (should go
away with definitely lost errors)
Valgrind possibly lost - ANSWER weird stuff w/ pointers. probably won't see
Still reachable - ANSWER memory wasn't freed but still reachable and program is ok
Program scope - ANSWER accessible by all source files that make up exe
File Scope - ANSWER accessible from declaration to end of file
static in C means public to file
Function scope - ANSWER accessible through a function
block scope - ANSWER accessible w/in {} it was declared in
Automatic storage - ANSWER fresh temp copy create on stack each time function is
called
Static storage - ANSWER only one instance of the var in the exe
Dynamic storage - ANSWER created temporarily on the heap
Web App Architecture - ANSWER Parser builds data model for every file, sends those
values to web server, web server stores info from that data model in DB server, Web UI
requests info from web server, web server either pulls that from DB or requests a data
model from parser
Linux Tool Chain - ANSWER sequence of software tools that convert src code to binary
GCC - ANSWER GNU Compiler Collection
CPP - ANSWER C Preprocessor
- interprets all # in .h .and .c files before compiler sees source code
C Compiler - ANSWER compile src into assembly language (.i into .s)
[G]AS - ANSWER Assembler
takes assembly code into object code (.s to .o)
LD - ANSWER Linker
- stitches .o and referenced system libs into bin exe
- static libs are linked here (dynamic are at run time)
LD.SO - ANSWER Loader
- tells OS to execute a program
- OS opens new program and copies segments into virtual memory process
DLOPEN - ANSWER Loader
- Program using dynamically linked libs loaded by ld.so when program starts
Macros in Makefiles - ANSWER $(THING) = flags/files/commands
CC = gcc - ANSWER select GCC compiler as front end
CPPFLAGS - ANSWER -Iinclude_file_dir (absolute)
-I~/myproj/include (relative and takes all system and own)
-Dsymbol (#define but in cmd line)
-DNDEBUG (disable assertions)
,CFLAGS - ANSWER Compiler Flags
-g (save symbols for debugger)
-Wall -std=c11
-fpic
-c
LDFLAGS - ANSWER Linker Flags
-Llib_dir
-L~/myproj/lib
-llibrary
-lfoo
Static lib - ANSWER linked at compile time, inflexible, contents copied into exe
Dynamic lib - ANSWER linked at run time
shared libs
flexible
default irl
Creating shared lib - ANSWER gcc -c prog.c -o prog.o
gcc -shared -o libprog.so prog.o
Creating static lib - ANSWER gcc prog.c prog.o -c
ar prog.o -o prog -lprog
XML - ANSWER Extensible Markup Language
XML Design goals - ANSWER - straightforward to use over internet
- supports lots of apps
- easy to write programs to process XML docs
- human legible, clear
- easy to create docs
- formal and concise
- compatible w/ SGML
, XML strong points - ANSWER - explicit structure for data manipulation
- decouples presentation from data
- can be used to glue together apps
- modular
- text that's not meant to be read
XML Elements - ANSWER If contain other elements, those are child elements
<start tag>content</end tag>
<empty element/>
XML Attributes - ANSWER Must not appear outside of start tags or empty element tags
<example name1="val1" name2="val2">content</example>
<example name="val"/>
XSD - ANSWER XML Schema Definition (came after DTDs)
DTD - ANSWER Document Type Definition
Valgrind - ANSWER memory debugging tool, checks leaks, diagnoses memory errors
Valgrind definitely lost - ANSWER leaking memory --> allocated and never freed
Valgrind indirectly lost - ANSWER leaking memory in pointer based structure (should go
away with definitely lost errors)
Valgrind possibly lost - ANSWER weird stuff w/ pointers. probably won't see
Still reachable - ANSWER memory wasn't freed but still reachable and program is ok
Program scope - ANSWER accessible by all source files that make up exe
File Scope - ANSWER accessible from declaration to end of file
static in C means public to file
Function scope - ANSWER accessible through a function
block scope - ANSWER accessible w/in {} it was declared in
Automatic storage - ANSWER fresh temp copy create on stack each time function is
called
Static storage - ANSWER only one instance of the var in the exe
Dynamic storage - ANSWER created temporarily on the heap