View this PageEdit this PageAttachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Cases Final Project Summer 2007

Sum00 Final Exam Review: Soccer Moms Communication System

Edit Sum00 Final Exam Review: Soccer Moms Communication System here.

a.- I'd use MVC for the UI because, to kepp the soccer mom device small enough to be easy to tote around, I want to make the demand on hardware as light as possible. Also, there is no need for any fany multimedia functions, but if the soccer momms were more concerned w/ fancy graphics, I could always use Morphic instead, so that I could take advantage of the wonderful multimedia toolkit.

b.- Test the UI ideas to see if it lives up to it's claim. Ask the moms what they would find useful in such a device or if they would even find the device useful. Observe the soccer moms in their everyday lives giving them a beeper, a garage door opener, a cell phone, and a web browser, to see how they use each, how often they use each, and how useful each are to the soccer moms. Design a prototype and poll soccer moms for their opinions. Notice, our target audience is soccer moms, so we are focussing on them in our tests, observations, polls, etc..

c.- (a) First find what's time critical, which parts of the device are slow, according to the users. If they think the cellphone is too slow, we've got problems because use of a phone is usually a non-time critical process. In such a case, we have to do intensive redesign of our system in order to improve the speed.

In order to pin-point problems, we should do test on the individual classes in the system to see which bottleneck the device or parts of the device.

(b) Then trace through the slower parts and find out how they are interating w/ the device in order to slow down the system. Are the slow parts using loops? What's the Big O of the loops? Is there a way to redesign the code so that it uses fewer intructions/loops to process information? Is there a way to split up parts of the code into seperate classes/methods that can run concurrently (basically take code that's running sequentially but that's not dependant upon the each other, and split it into two or more portions that could run concurrently.)

Also, if a VM is being used, do we really need to stick with a VM if the device's hardware is always the same? If the hardware is constant, compiling the code to native byte code would probably increase the overall performance of the applications running on the device.

For part a of c, I believe Mark is probably looking for more specifics than just the how you described to test if it was slow or not since he mentioned Squeak specifically.

To see what the slow parts are in the program, I would recommend using a TimeProfileBrowser. Much like MessageTally, it spies on the code and outputs a tree that lets you see how much time is being spent on certain operations, but also allows you to look at the exact piece of the offending code in which the program is slowing down. Of course, using this just once inaccurate, so you would need to run it through several times, possibly 100 or so, and then take the average to determine what code is slowing down the program.

Adam Blaiss

I disagree as far as describing Squeak specific code for the answer as we didn't learn how to use any specific testing devices such as the TimeProfileBrowser, and we're not going to have an image open while taking the final. I don't see why he'd want us to know something that we didn't use for the projects, labs, or wasn't in the slides/book. Then again.. I'm not Mark, so maybe it'd be cool if he'd shed some light :)

Actually, we did talk about MessageTally and TimeProfileBrowser in class. They were part of the slides that talked about Squeak optimiziation and reviewing when to use different collections for what purposes. Just thought I'd give a heads up so you can be ready for the final.

Adam Blaiss

Ah.. that must have been talked about during one of the 2 classes I missed. Whoops...

Both Chris and Adam's answer to (c) are acceptable in terms of level – either tell me the tools, or tell me what you'd do. There are lots of other acceptable answers, e.g., about primitives. But Chris' answer to (c) has a big hole in it: Are VM's just for portability? (a) is good. (b) is okay, but there are more specific, better answers for (b). Mark Guzdial

No.. VM's have many other benefits/drawbacks as well. VM's handle memory managment more efficiently by using garbage collection and keeping the memory used by the program compact. VM's start up quicker since there's no compile time to worry about, but they run slower than compiled code. I also see something in my notes about VM's being more secure, but right now, I can't think of a reason why.
VMs memory management may not be more efficient, but it's part of the reason why they're more secure. Mark Guzdial

Because the memory uses a stack instead of registers, so all the data is kept internal to the VM?

Both the Squeak and Java VMs disallow all memory access by address, and only allow access by Object: "Give me the object with this OOPS" or "Put this in the third instance variable of this object." That's a pretty secure access to memory, since the VM is the only place that object->memory-address conversions take place. That's one of the ways that a VM limits access to the raw machine, so it's more secure. Mark Guzdial

Links to this Page