CSE 7343/5343, Spring 2003
Topic 2-4: OS/Process Testing
Prof. Jeff Tian, CSE/SoE/SMU, Dallas, TX 75275
tian@engr.smu.edu; www.engr.smu.edu/~tian/class/7343.03s
- Dates: 3/25.
- Reading: This notes.
Testing Concepts
- testing as an important part of quality assurance
- basic steps:
- prepare test (test cases + procedure)
- run program against test and take measurement (trace)
- determine success vs failure
- if failure => locate/fix fault => re-test
- repeat until some stopping criteria met (coverage or reliability)
- basic testing techniques:
- black box: test external functions
- white box: test internal implementation
- coverage-based: cover function/implementation
specific: control/data/transaction/domain testing
- usage-based: scenarios and frequencies by users
list/tree/Markov-chain models
- most applicable to OS/process testing
transaction flow testing (TFT)
TFT Concepts
- basic concept
- system level suite of operations
- abstracted as transaction
- transactions carried by tokens
- dynamically serviced by system over time
- elements of
CFT (control-flow testing),
DFT (data-flow testing)
and beyond
- what is transaction?
- suite/units of processing
(typically user oriented)
- represented in graphs as transaction tokens
- tokens processed/handled by system
system services and structure
routing through the system
depend on sys. arch. & token type
- examples of transactions:
- bank transaction/service
- database transaction/operation
- processes in operating systems
- workload in queuing networks
- TFT system = architecture + tokens
TFT: Queuing Testing
- transaction/token handling and queuing
- multiple tokens to a single link
- service decisions = queuing discipline
(scheduling or contention resolution)
- information carried by tokens:
time-stamp/history/priority/etc.
- queuing principles at single server:
- priority: time vs. other:
- time: FIFO/FCFS, LIFO/stack, etc.
- other/explicit: SJF, priority#, etc.
- Pre-emption allowed?
- (buffer) bounded or unbounded?
- mixture/combination of queues
- batch and synchronization
- Testing a single queue
- test case design/selection:
- conformance to queuing discipline.
- boundary test: similar to loop test.
- test cases: input + expected output.
- combined cases of the above.
- testing specific boundary conditions:
- bounded queue with bound B
- lower bound: 0, 1, 2 (always)
- server busy/idle at lower bound
- upper bounds: B, B+1, B-1 (bounded Q)
- other test cases:
- typical case: usage-based testing idea.
- unbounded Q: capacity testing still needed
- mixed queues: test case combinations
- multiple queues: queuing network testing.
TFT: Synchronization Testing
- Basic synchronization types:
- merger of two incoming tokens:
a new outgoing token generated
similar to DFT in "A = B + C"
both B and C present to generate A
- absorption} of one token by another:
only one incoming token survives
similar to DFT in "S = S + X"
both S (orig) and X present
=> S (updated)
- other synchronization possible
- multi-way synchronization:
- N-M synchronization:
- N-way incoming
- M-way outgoing
- treat as multiple N-1 synchronization
- may involve queuing as well
- if not possible, ad hoc logic
- key: relating incoming and outgoing tokens
- more common in OS synchronization
- Synchronization testing}
- correct tokens input/produced
- synchronization of arrivals (timing)
- correct tokens input/produced:
- input tokens and expected output
- merger or absorption => output tokens
- synchronization of arrivals (timing):
- input tokens in different arriving orders
- example with two way synchronization
- nothing arrives => no output
- one arrives => no output
- two arrive (3 cases: A-B, B-A, AB) => correct token generated
- combination with correct tokens
- Multi-way synchronization testing:
- similar: correct token and timing
- more cases: combinatorial explosion
- solution: simplify via stages
- M-N synchronization: earlier discussion
- Multi-stage synchronization:
- solves combinatorial explosion problem
- token grouping possibilities
- in-group synchronization and then cross-group synchronization
- example: 5-way synchronization
- shares idea of hierarchical testing
Review for Exam #2
- material covered:
- deadlocks: Ch 8
- memory management: Ch. 9
- virtual memory: Ch. 10
- OS/process testing: class notes.
- type of questions:
- multiple choice: all
- definition/discussion: basic concepts and technique/solution comparisons
- problem solving: techniques/models/algorithms
RAG, avoidance/detection algorithms, memory mapping schemes,
allocation and replacement algorithms.
Prepared by Jeff Tian
(tian@engr.smu.edu).
Last update March 25, 2003.