

Three lessons I learnt from porting Diablo - petewarden
http://petewarden.typepad.com/searchbrowser/2009/12/three-lessons-i-learnt-from-porting-diablo.html

======
ghshephard
Has anyone ever seen this before?

"There were hundreds of pieces of x86 assembler scattered throughout the code
base, which was a problem since we were porting to the Playstation's MIPS
processor. Usually just a couple of instructions long, and in the middle of
functions, these snippets were pretty puzzling. Finally one of the team
figured it out; somebody had struggled with C's signed/unsigned casting rules,
and so they'd fallen back on the assembler instructions they understood! The
whole team had a good laugh at that"

~~~
ghshephard
I'm sorry - I should have been more clear - I _get_ that you inline assembly
when you need to do something your Compiler won't let you do (or makes
difficult), and that clearly people sometimes will tweak some inline assembly
to get a bit more performance - But has anyone ever seen a developer "Struggle
with C's casting rules" - and switch to Assembler to over come that challenge?
That just seems like an unexpected approach to that problem of understanding a
kind of fundamental C concept...

~~~
gvb
No, I've never seen someone drop to assy due to something as simple as not
understanding typecasting. Historically it has been for speed (used to be
common, a lot less common now) or to do something the compiler/language
doesn't support. The anecdote falls into the latter class, but only because
the original code author didn't understand C well enough.

When I started programming, the running joke was "you can write FORTRAN in any
language, some are just more difficult."

------
dazzawazza
Unfortunately this is a very common introduction to the Video games industry.
At least in the UK.

The industry trades on how 'cool' it is to work on games knowing that there
are hundreds of talented kids who will do anything to get in to it. They often
end up doing poorly paid difficult work under tight deadlines with bosses that
make The Office seems like heaven.

Unfortunately people like Liddon are few and far between within the industry.

------
elblanco
My lessons from his writeup seem to be completely different:

1) Get a paycheck I can live on.

2) Get a mentor.

3) You don't have to finish a job before moving on if things aren't working
out.

(not that I'd agree with #3, that just seems to be my takeaway from the
story).

~~~
Flankk
My takeaway was this:

"The third lesson I learnt was that you don't need great code to make a great
product."

I really believe this to be true. Coders are far too analytical for their own
good. If a product works great, then the poor code can be fixed later.

~~~
elblanco
You know, this is really true. My company has recently been making the slow
switch from "over-designed and implemented, resulting in a very slow release
cycle" to "minimally designed, quickly (but smartly) implemented, fast release
cycles".

This comes from two lessons to us:

1) No matter how long you spend designing a feature, it'll probably not be
100% of what the user wants. Do a quicker "draft" of the feature, solicit
feedback, and release fast to fulfill customer needs.

2) No matter how long you spend trying to write elegant code, the software
will have bugs, and other kinds of problems. Do it quick, observe it in the
field, take notes and do bug patches.

Getting the team on-board for these was hard due to the resistance of this
being the perceived Microsoft way of doing things, but it has resulted in much
higher customer satisfaction because they see continuous progress and feel
like their feedback is turning into product (they feel part of the process)
rather than tens of months of no progress followed by something they probably
didn't want to begin with.

------
joss82
"sometimes the worst projects are the best teachers."

That's so true. At least for me.

~~~
pgebhard
I agree, but you definitely wouldn't want to keep jumping from bad project to
bad project. The end goal should be to take that very useful experience and
turn it into a very successful project.

