Discussion:
Intro to Programming w/ Machine Language
(too old to reply)
Jonathan Bartlett
2005-02-07 16:43:20 UTC
Permalink
I'm teaching at our local community college as an adjunct. They have an
"intro to programming" class which teaches flow charting, logic, and
design principles for new programmers, using mostly pseudo-code rather
than actual programs.

Anyway, being a believer in knowing assembly language, I decided to put
together a computer simulation. I "designed" a simplified computer (25
instructions - add, subtract, load, store, divide, jump, and jump
conditional, with a few different addressing modes for each of them). I
had them simulate being the computer. I had a memory address space as a
grid of 255 boxes on posterboard. I had a person act as the data bus
who wrote down the instructions and brought them to the instruction
decoder, and I had the instruction decoder look up how each instruction
is processed based on the number. I had the ALU perform arithmetic
operations, and the "screen" watch a section of memory and display
letters on the screen based on what ASCII character was supposed to be
there. The registers (I had 5 general-purpose registers, an instruction
pointer, and a status register) were listed on the board. Each memory
cell and register held a number between 0 and 255, and the memory range
was between 0 and 255. Sticky Notes were used to put values into the
memory cells.

I believed in the project, but I was really surprised at how effective
it was. I had some people who were actually in the wrong class (they
were supposed to be in the "computer concepts" class -- you know, the
one where they teach you to use Word and Excel), who decided to stay
after playing the simulation. They felt they had a much better handle
on how the machine actually worked than if they had fixed their schedule
and gone to the "concepts" class (these were not teenagers, but
40-year-old women).

Anyway, we ran two programs -- find the maximum value and display a
value. It took about two hours to explain and run the simulation, and I
even had to cut the "maximum value" one short, but it was quite an
experience, and it showed that everyone can learn how computers work.

Anyway, I thought you all might be interested. I think this is a really
effective way of teaching programming (or computers, for that matter),
because it gives people an appreciation for how computers actually work.

I think we do a lot of people an injustice by assuming that they can't
learn how things work, when really if we just told them how it functions
they would be able to figure out the rest on their own.

Jon
----
Learn to program using Linux assembly language
http://www.cafeshops.com/bartlettpublish.8640017
Eric Mutta
2005-02-07 18:20:15 UTC
Permalink
Jonathan Bartlett wrote:

<snip>
Post by Jonathan Bartlett
Anyway, I thought you all might be interested. I think this is a really
effective way of teaching programming (or computers, for that
matter)...

...or anything for that matter! Your technique was effective because it
really exploited the fact that humans learn by association. I can bet
you if five years from now one of the ladies is reading up on more
advanced things they'll always recall how much fun they had running
around putting Post-it's in boxes. It may not explain the workings of
an inter-privilege-level context switch through a task gate, but it'll
remind them that it isn't as hard as it seems :-)

<snip>
Post by Jonathan Bartlett
Jon
----
Learn to program using Linux assembly language
http://www.cafeshops.com/bartlettpublish.8640017
Cheers,
Eric Mutta :-)
dreamteam
2005-02-07 18:50:47 UTC
Permalink
I shall say your concept is good
Randall Hyde
2005-02-08 04:01:24 UTC
Permalink
Post by Jonathan Bartlett
I'm teaching at our local community college as an adjunct. They have an
"intro to programming" class which teaches flow charting, logic, and
design principles for new programmers, using mostly pseudo-code rather
than actual programs.
Yep, it works fairly well. Definitely a technique I've used in past courses.
When "machine organization" (i.e., "Baby Architecture") is the main
focus of the course, then this works well. Back in the 16-bit/DOS
days, I actually wrote a little machine interpreter in assembly. For
32-bits/Windows, I wrote the simulator with Delphi so the students
got a nice GUI showing how all the hardware worked. This was
great because under Windows you can have them directly program
things like interrupt service routines, DMA, and so on. But all these
subjects are very easy to emulate.
See
http://webster.cs.ucr.edu/AoA/Windows/HTML/ISA.html
for more details.

Those who are interested can download the AoA examples file,
which includes the "Y86" emulator here:
http://webster.cs.ucr.edu/AsmTools/HLA/dnld.html
(download the sample code for AoA from this page).

The 16-bit edition code can be found here:
http://webster.cs.ucr.edu/AoA/DOS/0_Software.html

Cheers,
Randy Hyde
John Dahlman
2005-02-11 16:38:13 UTC
Permalink
This teaching method of simulating a computer reminded me of an old
educational program from years ago that actually did this. (I found
it as I'm slowly re-reading my 20-year-old BYTE collection out of
storage.)

In the March 1984 issue of BYTE was a review of "Simulated Computer II"
for the Atari 800 and Commodore 64 computers. On the screen you would
see a little terminal (complete with "hands" that typed as you typed)
for input, a little "printer" for output, the exposed CPU, and about 15
boxes with numbers in them as the "memory locations." All numbers were
in decimal, but just like a real CPU, those numbers could represent
data or CPU instructions.

Every time you stored a number into a memory location, a sparkling
"electron" would "bzzzzt!" down the wire from the terminal into the
CPU, and then to the memory, where the number would appear--a very
graphic view of a memory fetch. The simulated CPU had a very simple
instruction set. When a program was running, numbers (instructions)
would zap back and forth between memory and the CPU. (Though reviewer
said that the constant "bzzzting" sound could get to you after awhile.)

Although the reviewer thought that the instruction set was too limited
(no calling subroutines), it was fun to play with and a wonderfully
clear demonstration of what a CPU really does. There were even turtle
graphics memory mapped to three of the "bytes", so you could write
simple drawing programs with it. The review ended with, "I wish I had
this program when I was learning machine language!"

It sounds like the kind of program that everyone thinks is really neat
when it comes out, only to disappear forever soon afterwards. I've
never seen a simulation like this nowadays--certainly not simple enough
for older children. Maybe there's a ROM-dump of it somewhere on an
Atari emulation site, but if I hadn't re-read it again in BYTE I would
never have heard of it.

John Dahlman
Ben Pfaff
2005-02-11 17:27:46 UTC
Permalink
[...] Anyway, being a believer in knowing assembly language, I
decided to put together a computer simulation. I "designed" a
simplified computer (25 instructions - add, subtract, load,
store, divide, jump, and jump conditional, with a few different
addressing modes for each of them). I had them simulate being
the computer. I had a memory address space as a grid of 255
boxes on posterboard. [...]
I've actually seen this kind of simulation done with relatively
young children--6th graders if I recall correctly. It worked out
really well. I think this is a great way to introduce people to
how computers work internally.
--
"In the PARTIES partition there is a small section called the BEER.
Prior to turning control over to the PARTIES partition,
the BIOS must measure the BEER area into PCR[5]."
--TCPA PC Specific Implementation Specification
Randy Howard
2005-02-11 23:13:42 UTC
Permalink
Post by Ben Pfaff
[...] Anyway, being a believer in knowing assembly language, I
decided to put together a computer simulation. I "designed" a
simplified computer (25 instructions - add, subtract, load,
store, divide, jump, and jump conditional, with a few different
addressing modes for each of them). I had them simulate being
the computer. I had a memory address space as a grid of 255
boxes on posterboard. [...]
I've actually seen this kind of simulation done with relatively
young children--6th graders if I recall correctly. It worked out
really well. I think this is a great way to introduce people to
how computers work internally.
I can think of a large number of college graduates that dearly
need such a program right now.
--
Randy Howard (2reply remove FOOBAR)
"Making it hard to do stupid things often makes it hard
to do smart ones too." -- Andrew Koenig
George Weisz
2005-02-12 19:12:41 UTC
Permalink
Post by Randy Howard
I can think of a large number of college graduates that dearly
need such a program right now.
Long long time ago there was a text book by Knuth that had something
like that in the inside of the cover page.....
It may still be in existence....
Good luck
George
b***@aol.com
2005-02-14 03:58:01 UTC
Permalink
Post by Jonathan Bartlett
I'm teaching at our local community college as an adjunct. They have an
"intro to programming" class which teaches flow charting, logic, and
design principles for new programmers, using mostly pseudo-code rather
than actual programs.
Why not use real code in a readable, high-level language such as
Python? I think that is a better way to intoduce newbies to programming
than pseudo-code or machine language.
j***@eskimo.com
2005-02-14 06:05:51 UTC
Permalink
Post by b***@aol.com
Why not use real code in a readable, high-level language such as
Python? I think that is a better way to intoduce newbies to
programming
Post by b***@aol.com
than pseudo-code or machine language.
Because then you still have no conception about what the computer is or
does. So many constructs in high-level languages are impacted by the
low-level design. Understanding how a computer works requires thinking
about the programming from the perspective of the computer. Python
doesn't give you that.
Brian Harvey
2005-02-14 21:29:35 UTC
Permalink
Post by Jonathan Bartlett
Post by b***@aol.com
Why not use real code in a readable, high-level language such as
Python? I think that is a better way to intoduce newbies to
programming
Post by b***@aol.com
than pseudo-code or machine language.
Because then you still have no conception about what the computer is or
does. So many constructs in high-level languages are impacted by the
low-level design. Understanding how a computer works requires thinking
about the programming from the perspective of the computer. Python
doesn't give you that.
This battle has been fought many times before.

It's true, I agree, that a programmer is not fully educated until
s/he understands how the computer actually carries out a program.

That doesn't imply that the lowest level is the right place to *start*.
Here are two arguments for starting at a higher level of abstraction:

1. Most programmers spend most of their time trying to get a large
system to work; in that context, what counts is the ability to
express the desired behavior using modularity, data abstraction, etc.
Fine-tuning for performance comes later. "It's easier to make a
working program run fast than to make a fast program run correctly."

2. Obsessive attention to small details is a turn-off to many
beginners (perhaps especially women) whose learning style isn't a
good match for that approach, but who might really enjoy computer
science if it is presented, in the beginning, in terms of the
goals an application programmer wants to achieve.

At Berkeley our curriculum is organized on this principle. Our
first course is the (Scheme-based) Abelson and Sussman _Structure
and Interpretation of Computer Programs_, a high-level introduction
to programming paradigms such as functional programming and
object-oriented programming. Our second course, data structures,
is taught in Java, a medium-level language (it's high level in that
it has automatic memory allocation, but low level in that the
programmer is supposed to know things like how many bits in an
integer). And our third course, machine organization, is taught
in C and (MIPS) assembly language, and even an introduction to
hardware (in Verilog), providing the low-level view you favor.

I acknowledge that there are also plausible arguments for moving
in the other direction. But let's not waste time on straw-man
hypothetical curricula that leave out either the high-level or
the low-level view.
pH
2005-02-15 03:38:57 UTC
Permalink
On Mon, 14 Feb 2005 21:29:35 +0000 (UTC), ***@abbenay.CS.Berkeley.EDU (Brian
Harvey) wrote:

[...]
Post by Brian Harvey
At Berkeley our curriculum is organized on this principle. Our
first course is the (Scheme-based) Abelson and Sussman _Structure
and Interpretation of Computer Programs_, a high-level introduction
to programming paradigms such as functional programming and
object-oriented programming. Our second course, data structures,
is taught in Java, a medium-level language (it's high level in that
it has automatic memory allocation, but low level in that the
programmer is supposed to know things like how many bits in an
integer). And our third course, machine organization, is taught
in C and (MIPS) assembly language, and even an introduction to
hardware (in Verilog), providing the low-level view you favor.
Actually, that doesn't sound too bad.
Post by Brian Harvey
I acknowledge that there are also plausible arguments for moving
in the other direction.
Something which *may* depend on the individual in question, but...
as long as the end result is the same...
Post by Brian Harvey
But let's not waste time on straw-man
hypothetical curricula that leave out either the high-level or
the low-level view.
I've held the opinion that digital electronics (even at the "conceptual"
level) is a... proper foundation for someone interested in being an
honest to goodness programmer. I can't tell you how many people
I've encountered--people who've been schooled in programming,
people whose very *occupation* is programming--who don't know
why we have hexa-decimal numbering (nor, of course, how it relates
to binary).

I was into digital electronics for quite some time before I got into
programming, so... the computer presented no mystery, Plus, when
approaching a task (problem, whatever) from a "binary perspective",
a solution which is *much* more direct, clean, elegant (etc), can quite
often be realized.

So... if it were my job to teach someone programming, I would most
definitely start with digital electronics (at the gate level). Although...
I can appreciate the potential for... different "best foundations", and again,
something which very likely varies per individual.

The curriculum you mention, above, impresses me, and I'd imagine the
use of Verilog is rather effective (sure wish *I* had it, so many years ago).

Jeff

http://www.jefftturner.com
Programmer Dude
2005-02-17 21:10:44 UTC
Permalink
Post by pH
I've held the opinion that digital electronics (even at the "conceptual"
level) is a... proper foundation for someone interested in being an
honest to goodness programmer.
It certainly helped me. I don't know if I think it's required or
necessary, but I definitely agree it's helpful for many things we
encounter in this business. A lot depends on the type of programming
one does, too. Embedded programmers almost do require hardware
training as well. It may not be very helpful for high-level apps.
Post by pH
I was into digital electronics for quite some time before I got into
programming, so... the computer presented no mystery,...
First I taught myself tubes...only to learn the world now used transistors.
Then I taught myself transistors...only to learn that now it was "IC"s.
So I taught myself NANDS and NORs...except the world moved on to micros.

Long journey, but enjoyable and--far as I'm concerned--very worthwhile.
Post by pH
So... if it were my job to teach someone programming, I would most
definitely start with digital electronics (at the gate level).
Despite the above, I very doubt I would.

I had the experience of putting together and giving a one-day training
class for field technicians--guys trained in working on electronic
devices. This training was explicitly for the purpose of bringing
the field techs up to a fuller level of knowledge.

As a life-long bit-head, my original course provided a lot of foundation
knowledge about binary, hex and serial transmission. Stuff I knew had
been beneficial to me in the field.

Problem was it was too much. Minds not used to wrestling with those sorts
of concepts need a slow introduction that progressively builds the required
knowledge.
Randall Hyde
2005-02-15 05:37:32 UTC
Permalink
Post by Brian Harvey
That doesn't imply that the lowest level is the right place to *start*.
1. Most programmers spend most of their time trying to get a large
system to work; in that context, what counts is the ability to
express the desired behavior using modularity, data abstraction, etc.
Fine-tuning for performance comes later. "It's easier to make a
working program run fast than to make a fast program run correctly."
Not that I'm disagreeing with your basic premise, but keep in mind
that "working on large systems" is something that comes *long* after
their beginning class. Whether they learn low-level first or high-level
first is irrelevant for this aspect. By the time they start working on
large scale systems, one would hope they've mastered both.
Post by Brian Harvey
2. Obsessive attention to small details is a turn-off to many
beginners (perhaps especially women) whose learning style isn't a
good match for that approach, but who might really enjoy computer
science if it is presented, in the beginning, in terms of the
goals an application programmer wants to achieve.
OTOH, I have also found that most beginners like to understand
the underlying principles. Things make more sense to them at that
point. This isn't an argument for teaching low-level stuff first,
but it is certainly an argument for teaching it very early (e.g., by the
third or fourth course taught in the CS program).
Post by Brian Harvey
At Berkeley our curriculum is organized on this principle. Our
first course is the (Scheme-based) Abelson and Sussman _Structure
and Interpretation of Computer Programs_, a high-level introduction
to programming paradigms such as functional programming and
object-oriented programming. Our second course, data structures,
is taught in Java, a medium-level language (it's high level in that
it has automatic memory allocation, but low level in that the
programmer is supposed to know things like how many bits in an
integer). And our third course, machine organization, is taught
in C and (MIPS) assembly language, and even an introduction to
hardware (in Verilog), providing the low-level view you favor.
Third class is typical for CS programs.
But do keep *one* little thing in mind: Berkeley attracts (actually,
only allows in) very qualified undergraduate students. Trying to
use experiences at Berkeley as a "standard" for everywhere else
is dangerous. Most students are Berkeley are going to be sufficiently
brilliant that they can figure out this stuff on their own (or probably
already know it before even showing up for school. What works
at Berkeley is not, for example, guaranteed to work at Cal Poly
San Luis Obispo or, say, Rio Hondo Community College.
Again, I'm not suggesting that Berkeley's approach won't work
elsewhere, but you won't find too many schools jumping around
in three different languages in the first three classes their students
take.
Post by Brian Harvey
I acknowledge that there are also plausible arguments for moving
in the other direction. But let's not waste time on straw-man
hypothetical curricula that leave out either the high-level or
the low-level view.
Do keep in mind that a relatively well-known guy just across
the bay from Berkeley, one "Donald Knuth", is a big fan of
teaching advanced courses using low-level programming.
He seems to feel that it's the only way for a programmer
to really learn the material. Maybe you've heard of his works?
(The Art of Computer Programming?)
Cheers,
Randy Hyde
Brian Harvey
2005-02-15 06:21:07 UTC
Permalink
Post by Randall Hyde
But do keep *one* little thing in mind: Berkeley attracts (actually,
only allows in) very qualified undergraduate students. Trying to
use experiences at Berkeley as a "standard" for everywhere else
is dangerous.
I did say, in the next paragraph, that I acknowledge that there are
plausible arguments for doing it the other way around. I didn't
mention our curriculum to imply that everyone has to do it our way!
I was just giving an example, the example I know best.

But I'm not sure how to apply the idea that other students might
need something else; it doesn't tell us *which* something else.
For instance, someone might argue that only the most sophisticated
programmers have to understand how the computer works, whereas the
average programmer will end up writing a GUI in Java Beans or some
such fairly-high-level thing.
Post by Randall Hyde
Again, I'm not suggesting that Berkeley's approach won't work
elsewhere, but you won't find too many schools jumping around
in three different languages in the first three classes their students
take.
It's true that many schools don't do that, but I think any school does
its students a disservice if it leaves them with the attitude that
learning a new programming language is a big deal. That's the way to
ensure that their students will be unemployed five years after they
graduate.
Post by Randall Hyde
Do keep in mind that a relatively well-known guy just across
the bay from Berkeley, one "Donald Knuth", is a big fan of
teaching advanced courses using low-level programming.
He seems to feel that it's the only way for a programmer
to really learn the material. Maybe you've heard of his works?
(The Art of Computer Programming?)
Have you asked Don about this lately? Last I heard, he was allowing
as how maybe inventing the MIX pseudo-machine language was a mistake.
Certainly being coy about whether the machine represents numbers in
binary or decimal was pretty near obsolete by the time the books
reached print. In any case, I think the reason he did it wasn't that he
thought it was needed for programming; he thought it was useful because
he wanted to do a detailed analysis of the algorithms, and to do that in
detail (rather than in order-of-growth terms) you have to pin down the
exact timing of the primitive operations.

Anyway, we aren't talking about advanced courses. We're talking about
what comes first. Again, it's pointless to throw up and shoot down
hypothetical straw-man curriculua that leave out either high or low
levels of abstraction.
Randall Hyde
2005-02-15 14:05:27 UTC
Permalink
Post by Brian Harvey
I did say, in the next paragraph, that I acknowledge that there are
plausible arguments for doing it the other way around. I didn't
mention our curriculum to imply that everyone has to do it our way!
I was just giving an example, the example I know best.
Therein lies a problem, demonstrated in many of the threads
in this newsgroup: "the example I know best." Again, I'm
not suggesting that the way Berkeley does it is wrong, just
that the statistical sample isn't a good one for determining a
great way to teach typical students.

Actually, from an assembly perspective, teaching LISP (scheme)
as a first programming language isn't bad. The paradigm is
closer to assembly than, say, Java.
Post by Brian Harvey
But I'm not sure how to apply the idea that other students might
need something else; it doesn't tell us *which* something else.
For instance, someone might argue that only the most sophisticated
programmers have to understand how the computer works, whereas the
average programmer will end up writing a GUI in Java Beans or some
such fairly-high-level thing.
Regardless of what they do, programmers need an appreciation
of the underlying machine. This doesn't imply that they need to learn
assembly or machine architecture first, but they do have to learn
it.
Post by Brian Harvey
Post by Randall Hyde
Again, I'm not suggesting that Berkeley's approach won't work
elsewhere, but you won't find too many schools jumping around
in three different languages in the first three classes their students
take.
It's true that many schools don't do that, but I think any school does
its students a disservice if it leaves them with the attitude that
learning a new programming language is a big deal. That's the way to
ensure that their students will be unemployed five years after they
graduate.
I've taught at schools where they jumped around a bit early on
in the curriculum. Most students were confused by the approach
because the 10-week quarter was insufficient to get a handle
on the language (Berkeley has 15-week semesters, IIRC?)
Post by Brian Harvey
Post by Randall Hyde
Do keep in mind that a relatively well-known guy just across
the bay from Berkeley, one "Donald Knuth", is a big fan of
teaching advanced courses using low-level programming.
He seems to feel that it's the only way for a programmer
to really learn the material. Maybe you've heard of his works?
(The Art of Computer Programming?)
Have you asked Don about this lately? Last I heard, he was allowing
as how maybe inventing the MIX pseudo-machine language was a mistake.
And that would be why Volume IV, which is now appearing, uses an
updated version of MIX? It is an urban legend that Knuth disavowed
this approach. He still believes, strongly, in it. Else his new book
wouldn't
use that approach.
Post by Brian Harvey
Certainly being coy about whether the machine represents numbers in
binary or decimal was pretty near obsolete by the time the books
reached print. In any case, I think the reason he did it wasn't that he
thought it was needed for programming; he thought it was useful because
he wanted to do a detailed analysis of the algorithms, and to do that in
detail (rather than in order-of-growth terms) you have to pin down the
exact timing of the primitive operations.
You might try reading the first section of Volume I.

cheers,
Randy Hyde
Jonathan Bartlett
2005-02-15 19:04:07 UTC
Permalink
Post by Brian Harvey
That doesn't imply that the lowest level is the right place to *start*.
Here's why I think it's a great place to start:

* Machine language is very concrete. This makes it easy to
_understand_, even if it is hard to _use_ it to solve large problems with.
* People who have never messed with programming often have MAJOR
problems thinking sequentially and exactly. Assembly language breaks
you out of that habit real fast. You can see why the computer needs
instructions so exactly and in sequential order.
* When you learn concepts of other languages, you can see immediately
_why_ they are needed. This promotes curiosity, because you can see as
you learn how everything developed, which will make you curious how
other things develop. If you are just given Java or something "as is",
it tends to limit your question-asking, not extend it.
* Another issue that new programmers have is figuring out how to tie
small operations together to do larger ones. Nothing teaches you that
better than assembly language.
Post by Brian Harvey
1. Most programmers spend most of their time trying to get a large
system to work; in that context, what counts is the ability to
express the desired behavior using modularity, data abstraction, etc.
Fine-tuning for performance comes later. "It's easier to make a
working program run fast than to make a fast program run correctly."
The reasons for teaching assembly language having nothing to do with
speed and everything to do with understanding. In fact, you can
theoretically get better speeds with higher-level languages, because the
type systems can perform optimizations that you won't think of.
Post by Brian Harvey
2. Obsessive attention to small details is a turn-off to many
beginners (perhaps especially women) whose learning style isn't a
good match for that approach, but who might really enjoy computer
science if it is presented, in the beginning, in terms of the
goals an application programmer wants to achieve.
Actually, I've found that the women in my class liked it better than the
men. But that was a pretty small sample. On another note, while I
wouldn't specifically want to turn anyone off to computer science, I do
think we've done WAY too much to coddle students, and it's turned out
lots of bad programmers.

Jon
----
Learn to program using Linux assembly language
http://www.cafeshops.com/bartlettpublish.8640017
Jim Clarke
2005-02-15 21:40:13 UTC
Permalink
Post by Brian Harvey
That doesn't imply that the lowest level is the right place to *start*.
* Machine language is very concrete....
Here's why I don't think the lowest level is a great place to start:

* Quantum mechanics takes a good deal of preparation, and even then
you're only just starting to get ready for solid-state physics.

Sarcasm aside, my point is that you have to choose *somewhere* in a
continuum of abstractions and levels; choosing to start at a low
level in programming means choosing to neglect something, and part
of what you're choosing to neglect is mathematical. Students have
considerable difficulty understanding how to abstract, and perhaps
we should start with that, and add implementation details later.
--
Jim Clarke -- Dept. of Computer Science, University of Toronto
http://www.cs.utoronto.ca/~clarke
Robert Redelmeier
2005-02-15 22:09:01 UTC
Permalink
Post by Jim Clarke
Sarcasm aside, my point is that you have to choose *somewhere*
in a continuum of abstractions and levels; choosing to start at a
low level in programming means choosing to neglect something, and
part of what you're choosing to neglect is mathematical. Students
have considerable difficulty understanding how to abstract,
and perhaps we should start with that, and add implementation
details later.
First, you _do_ notice that ALA is on the group list, and
you ought to expect very strong opinions from this bunch.
The whole topic approaches a troll for ALA.

I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.

OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.

The difference between ASM & HLLs is nothing compared to the
chasm between quantum & Newtonian physics.

-- Robert
Jim Clarke
2005-02-15 22:20:13 UTC
Permalink
Post by Robert Redelmeier
Post by Jim Clarke
Sarcasm aside, my point is that you have to choose *somewhere*
in a continuum of abstractions and levels; choosing to start at a
low level in programming means choosing to neglect something, and
part of what you're choosing to neglect is mathematical. Students
have considerable difficulty understanding how to abstract,
and perhaps we should start with that, and add implementation
details later.
First, you _do_ notice that ALA is on the group list, and
you ought to expect very strong opinions from this bunch.
The whole topic approaches a troll for ALA.
I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.
OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.
The difference between ASM & HLLs is nothing compared to the
chasm between quantum & Newtonian physics.
My apologies; I was being careless, and had no intention of
offending assembly-language programmers. I was one myself for
a few years, and strongly recommend KDF9 assembler (it's a
lovely stack-based machine) as an instructive way of spending
your time -- especially since luxuries such as choosing your
own variable names aren't (or weren't) provided.

But in comp.edu, describing assembler as "fundamental" misses
some fundamentals.
--
Jim Clarke -- Dept. of Computer Science, University of Toronto
http://www.cs.utoronto.ca/~clarke
Robert Redelmeier
2005-02-15 22:39:52 UTC
Permalink
Post by Jim Clarke
My apologies; I was being careless, and had no intention of
offending assembly-language programmers. I was one myself for
No offense taken, I assure you. ALA is pretty much a
rowdy free-for-all. If you want civility, you have to
go to comp.lang.asm.x86 which is moderated.

-- Robert
"-\\\\o//-annabee" @
2005-02-15 23:05:19 UTC
Permalink
PÃ¥ Tue, 15 Feb 2005 22:39:52 GMT, skrev Robert Redelmeier
Post by Robert Redelmeier
Post by Jim Clarke
My apologies; I was being careless, and had no intention of
offending assembly-language programmers. I was one myself for
No offense taken, I assure you. ALA is pretty much a
rowdy free-for-all. If you want civility, you have to
go to comp.lang.asm.x86 which is moderated.
if you ask me, x86 is where you go to tell people to fudge off in a polite
manner :)
Post by Robert Redelmeier
-- Robert
--
http://demo.ffii.org/demo0502/
NoDot
2005-02-16 02:45:20 UTC
Permalink
Post by "-\\\\o//-annabee" @
if you ask me, x86 is where you go to tell people to fudge off in a
polite manner :)
Ah, meet The Wannabee, one of the colorful people here in ALA.
--
The above was written by NoDot.

Visit the Website of NoDot:
<www.geocities.com/nodot1989/>
"-\\\\o//-annabee" @
2005-02-16 03:09:38 UTC
Permalink
PÃ¥ Tue, 15 Feb 2005 21:45:20 -0500, skrev NoDot
Post by NoDot
Post by "-\\\\o//-annabee" @
if you ask me, x86 is where you go to tell people to fudge off in a
polite manner :)
Ah, meet The Wannabee, one of the colorful people here in ALA.
:-))
Am I really colorful ? How wonderbar :)

You are colorful too Nodot :))

What are the world without color ? Like music on a pc speaker ? :))
Like Beth without posts that makes my monitor shake when I load them ?

This whole NG is colorful.

In this ng, I find noone who is perfect. Thats why I love it.
I never met such a bunch of relentlessly energic, crazy, angry,
knowledgeable, frustrating & frustrated, humoristic, and stuckup bunch of
pedantic, loving & forgiving people in my entire life. Like pieces of a
slighly broken diamond.

I find that each of you to probably mirror some bits of my own personality.
Love ya. No doubt.

Byegonze.
--
http://demo.ffii.org/demo0502/
Willem
2005-02-15 22:35:16 UTC
Permalink
Robert wrote:
) First, you _do_ notice that ALA is on the group list, and
) you ought to expect very strong opinions from this bunch.
) The whole topic approaches a troll for ALA.
)
) I think learning ASM first gives a very solid foundation upon
) which to learn HLLs and other constructs. Especially with
) the prdominance of x86. Everything eventually gests reduced
) to machine code, and ASM is the closes human-readable form.
)
) OTOH, teaching transistor arrangements is probably unnecessary
) except to electrical engineers.
)
) The difference between ASM & HLLs is nothing compared to the
) chasm between quantum & Newtonian physics.

There is the issue that learning ASM usually includes learning a number
of bad habits, that you have to break to be able to effectively program
in a suitably high level language. For example, it teaches you to think
sequentially, and to approach programming as a sequence of tasks that a
computer has to do one after another. For example, with a background in
iteratvie languages, functional languages tend to become more difficult
and often such people will try to force iterative programs. I did too.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Robert Redelmeier
2005-02-15 23:03:07 UTC
Permalink
Post by Willem
There is the issue that learning ASM usually includes learning
a number of bad habits, that you have to break to be able to
effectively program in a suitably high level language. For
"bad habits" is a inflammatory term. What is bad in one
circumstance may not be bad in another.
Post by Willem
example, it teaches you to think sequentially, and
to approach programming as a sequence of tasks that a
computer has to do one after another.
And this is exactly how the computer works. So long as
cycles are scarce (people clamor for faster machines),
then this may be best for most problems. Particularly
when user.time >> pgmr.time .
Post by Willem
For example, with a background in iteratvie languages,
functional languages tend to become more difficult and often
such people will try to force iterative programs. I did too.
Certainly. Haskell, SML & Scheme take a very different mindset.
Or did you mean APL by "functional languages? :)

But any imperative HLL suffers the same drawback as ASM.
Perhaps worse for the function abstractions they teach.

-- Robert
Willem
2005-02-15 23:36:52 UTC
Permalink
Robert wrote:
) In alt.lang.asm Willem <***@stack.nl> wrote:
)> There is the issue that learning ASM usually includes learning
)> a number of bad habits, that you have to break to be able to
)> effectively program in a suitably high level language. For
)
) "bad habits" is a inflammatory term. What is bad in one
) circumstance may not be bad in another.

I think one can state that's true for every single bad habit in existence.
Otherwise, why would one have gotten the habit in the first place ?
And of course it's an inflamatory term. This is usenet after all. :-)

)> example, it teaches you to think sequentially, and
)> to approach programming as a sequence of tasks that a
)> computer has to do one after another.
)
) And this is exactly how the computer works. So long as
) cycles are scarce (people clamor for faster machines),
) then this may be best for most problems. Particularly
) when user.time >> pgmr.time .

There's a whole discussion in this, stemming from the standpoint that
programmer time is actually bloody expensive, and cycles aren't quite
as scarce as people believe. Besides which, the bottleneck these days
is accessing internal and external memory.

)> For example, with a background in iteratvie languages,
)> functional languages tend to become more difficult and often
)> such people will try to force iterative programs. I did too.
)
) Certainly. Haskell, SML & Scheme take a very different mindset.
) Or did you mean APL by "functional languages? :)

Haven't tried APL yet, to be honest. And I think you mithed lithp.

) But any imperative HLL suffers the same drawback as ASM.
) Perhaps worse for the function abstractions they teach.

Very true. And I agree that learning ASM is a very solid foundation
on which you can build the learning of any _imperative_ HLL.
Just that I'm not quite so sure anymore that imperative is the way
to go in computer programming. I wonder what whizkids would be like
if we nurtured them on something like lithp.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Robert Redelmeier
2005-02-16 00:14:36 UTC
Permalink
Post by Willem
I think one can state that's true for every single bad habit
in existence. Otherwise, why would one have gotten the habit
in the first place ?
Therefore, like all prejoratives, it says more about
the speaker than the target.
Post by Willem
There's a whole discussion in this, stemming from the standpoint
that programmer time is actually bloody expensive, and cycles
aren't quite as scarce as people believe. Besides which, the
bottleneck these days is accessing internal and external memory.
This is too narrow a view. If MS-InternetExplorer takes 0.50s
extra to render a pageview, and it renders ~1 Gviews/day,
then that bloat costs the world 5.4 lifetimes each day.
Probably more than the programmer time it took to write IE.
At some point, fast software becomes a social responsibility.
Post by Willem
Haven't tried APL yet, to be honest.
You are missing a treat .... NOT!
Post by Willem
And I think you mithed lithp.
Isn't Scheme an offshoot?
Post by Willem
Just that I'm not quite so sure anymore that imperative is
the way to go in computer programming.
I'm fairly certain it is not, at least not for near-user
programming like spreadsheets and word processing documents.
Here, stacks of cycles are available and user(pgmr) convenience
is paramount.
Post by Willem
I wonder what whizkids would be like if we nurtured them
on something like lithp.
Then raise some.

-- Robert
Programmer Dude
2005-02-17 21:13:15 UTC
Permalink
Post by Robert Redelmeier
Post by Willem
There's a whole discussion in this, stemming from the standpoint
that programmer time is actually bloody expensive, and cycles
aren't quite as scarce as people believe. Besides which, the
bottleneck these days is accessing internal and external memory.
This is too narrow a view. If MS-InternetExplorer takes 0.50s
extra to render a pageview, and it renders ~1 Gviews/day,
then that bloat costs the world 5.4 lifetimes each day.
Probably more than the programmer time it took to write IE.
At some point, fast software becomes a social responsibility.
A social responsibility to provide faster browsing??

I'd think a higher social responsibility would be to get people to
get their noses OUT of the 'net and outside for some human interaction.
"-\\\\o//-annabee" @
2005-02-17 21:49:49 UTC
Permalink
PÃ¥ Thu, 17 Feb 2005 15:13:15 -0600, skrev Programmer Dude
Post by Programmer Dude
Post by Robert Redelmeier
Post by Willem
There's a whole discussion in this, stemming from the standpoint
that programmer time is actually bloody expensive, and cycles
aren't quite as scarce as people believe. Besides which, the
bottleneck these days is accessing internal and external memory.
This is too narrow a view. If MS-InternetExplorer takes 0.50s
extra to render a pageview, and it renders ~1 Gviews/day,
then that bloat costs the world 5.4 lifetimes each day.
Probably more than the programmer time it took to write IE.
At some point, fast software becomes a social responsibility.
A social responsibility to provide faster browsing??
I'd think a higher social responsibility would be to get people to
get their noses OUT of the 'net and outside for some human interaction.
:))) Very good answer. May I be allowed to ask ......

What is it with either "human interaction" or "net", that makes people
choose the "net" ?
I think that is the first thing you need to figure out.

If the "net" is more applealing to people, then there must be a reason for
that ?

Actually, are most browsers simply nicer to spend time with than most
people ?

:))))

Do this really need an answer ?
--
http://demo.ffii.org/demo0502/
Programmer Dude
2005-02-17 22:58:57 UTC
Permalink
Post by "-\\\\o//-annabee" @
Post by Programmer Dude
A social responsibility to provide faster browsing??
I'd think a higher social responsibility would be to get people to
get their noses OUT of the 'net and outside for some human interaction.
:))) Very good answer. May I be allowed to ask ......
What is it with either "human interaction" or "net", that makes people
choose the "net" ?
In a word: Alienation.
"-\\\\o//-annabee" @
2005-02-17 23:49:57 UTC
Permalink
PÃ¥ Thu, 17 Feb 2005 16:58:57 -0600, skrev Programmer Dude
Post by Programmer Dude
Post by "-\\\\o//-annabee" @
What is it with either "human interaction" or "net", that makes people
choose the "net" ?
In a word: Alienation.
Maybe. I think you would need to expand on this. Because alienation is
sort of an "umbrella" word, it covers a lot of diffrent things.

But, I think there's a major winning about virtuality as well. For
instance, people of diffrent ages and cultures can interact, in games for
instance. Also, if you are allready sitting home and alone, as many old /
sick people do in my country, espesially in the long winter, then having
the possibility of meeting people online is nothing short of wonderful.

I also think its of major importance that on the net, one can find peers,
nomatter what is once interessts.

There are ups and downs to most everything. I have a few friends who plays
games and stuff, and read mail and chats etc, that are not programmers.
They all carry out the rest of their life at no problem. The net is an
extention to them, a useful source of information, impulses, relieving of
bordom, etc, but it doesnt absorb them, or make them less interessted in
having a night out on the town, or comming for visit.
--
http://TheWannabee.org
Programmer Dude
2005-02-19 00:53:36 UTC
Permalink
Post by "-\\\\o//-annabee" @
Post by Programmer Dude
Post by "-\\\\o//-annabee" @
What is it with either "human interaction" or "net", that makes people
choose the "net" ?
In a word: Alienation.
Maybe. I think you would need to expand on this. Because alienation is
sort of an "umbrella" word, it covers a lot of diffrent things.
I'm taking your "choose" to imply "prefer". People who prefer the 'net
over human interaction are usually alienated (from other people). Which
is not to say the alienation is *necessarily* a bad thing--there's a lot
to be alienated from these days.
Post by "-\\\\o//-annabee" @
But, I think there's a major winning about virtuality as well. For
instance, people of diffrent ages and cultures can interact, in games for
instance. Also, if you are allready sitting home and alone, as many old /
sick people do in my country, espesially in the long winter, then having
the possibility of meeting people online is nothing short of wonderful.
No denying that at all! I assume that if they had better options, they
might prefer them, but absolutely the 'net can be a connector of people.
Heck, I have "friends" all over the world because of the 'net.
NoDot
2005-02-17 22:23:25 UTC
Permalink
Post by Programmer Dude
I'd think a higher social responsibility would be to get people to
get their noses OUT of the 'net and outside for some human interaction.
IMO, human interaction is slightly (pah, majorly) overrated.
--
The above was written by NoDot.

Visit the Website of NoDot:
<www.geocities.com/nodot1989/>
Programmer Dude
2005-02-17 23:04:15 UTC
Permalink
Post by NoDot
Post by Programmer Dude
I'd think a higher social responsibility would be to get people to
get their noses OUT of the 'net and outside for some human interaction.
IMO, human interaction is slightly (pah, majorly) overrated.
You're doing it wrong, then. :-)


And I can't resist this....

"one dot, that's on or off, defines what is and what is not, one dot.
two dot, a pair of eyes, a voice, a touch, complete surprise, two dot.
[...]
three dot, a trinity, a way to map the universe, three dot.
four dot is what will make a square, a bed to build on, it's all there."

-Peter Gabriel, "Growing Up" from the "Up" album.
Robert Redelmeier
2005-02-17 22:57:01 UTC
Permalink
Post by Programmer Dude
Post by Robert Redelmeier
This is too narrow a view. If MS-InternetExplorer takes 0.50s
extra to render a pageview, and it renders ~1 Gviews/day,
then that bloat costs the world 5.4 lifetimes each day.
Probably more than the programmer time it took to write IE.
At some point, fast software becomes a social responsibility.
A social responsibility to provide faster browsing??
Yes. I consider a programmer's social responsibility is
to help their users do what they desire quickly and easily.
Post by Programmer Dude
I'd think a higher social responsibility would be to get
people to get their noses OUT of the 'net and outside for
some human interaction.
No. Influencing peoples' desires & actions is politics,
not social responsibility. If you don't like browsing,
then don't work on a browser.

-- Robert
Programmer Dude
2005-02-19 01:05:59 UTC
Permalink
Post by Robert Redelmeier
Post by Programmer Dude
Post by Robert Redelmeier
At some point, fast software becomes a social responsibility.
A social responsibility to provide faster browsing??
Yes. I consider a programmer's social responsibility is
to help their users do what they desire quickly and easily.
Wrong emphasis, I think. If there is any moral or social obligation,
it's for the worker to do the work--what ever it is--in a way that is
moral or socially responsible.

We have established that "I was paid" or "I was ordered" is not an
acceptable defense for an immoral or irresponsible act. The employee
has a moral/social obligation regardless of pay or orders.

I don't see any moral/social connection to a specific requirement
(faster browsing). History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.

Thus it is one thing to say, "My customer has asked for a faster browser,
and my obligation is to meet the request," and another to suggest that
faster browsers are a social responsibility.
Post by Robert Redelmeier
Post by Programmer Dude
I'd think a higher social responsibility would be to get
people to get their noses OUT of the 'net and outside for
some human interaction.
No. Influencing peoples' desires & actions is politics,
not social responsibility.
You don't think that influencing people with regard to the dangers
of AIDS, hard drugs and teen pregnancy is a social responsibility?
Post by Robert Redelmeier
If you don't like browsing, then don't work on a browser.
But if it's true that a faster browser is a social responsibility,
then I *ought* to be working on one.
Randall Hyde
2005-02-19 18:03:03 UTC
Permalink
Post by Programmer Dude
Wrong emphasis, I think. If there is any moral or social obligation,
it's for the worker to do the work--what ever it is--in a way that is
moral or socially responsible.
And the worker that produces the software for other workers should
do so in a way that makes their work more efficient. Wouldn't you
say?
Post by Programmer Dude
We have established that "I was paid" or "I was ordered" is not an
acceptable defense for an immoral or irresponsible act. The employee
has a moral/social obligation regardless of pay or orders.
Yes, they can quit. And forgo their moral/social contract to provide
for their families, etc. Philosophers have argued about this since
the dawn of the wage. Do you really think that you can condense it
down to two sentences and encapsulate some profound meaning
in your statements? Is is particularly pathetic that you use this as
an excuse for writing sloppy code.

Now, granted, there are some morally/socially responsible reasons
for writing sloppy, bloated, and inefficient code. But most of the
time this is due to laziness (or because "I was ordered to do so").
That's hardly a moral or socially responsible reason. Try to push
the responsibility of this onto the worker is a bit much.
Post by Programmer Dude
I don't see any moral/social connection to a specific requirement
(faster browsing). History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.
So wasting the user's time by making them spend *more* time doing
these activities, leaving less free time for other lifestyle activities, is
the socially responsible thing to do, eh?
Post by Programmer Dude
Thus it is one thing to say, "My customer has asked for a faster browser,
and my obligation is to meet the request," and another to suggest that
faster browsers are a social responsibility.
When given a choice, customers always pick:

1. the "cooler" product
2. the product with more features
3. the product that costs less
4. the product that performs better

Pretty much in that order. Seems to me that most of the choices are
economic ones, not social ones (though #1 certainly stands out).
Of course, making a product more cost-effective (more features for
less money and more efficient to use) can certainly be considered a
social responsibility. So yes, providing a faster browser is one example
of being socially responsible.
Post by Programmer Dude
You don't think that influencing people with regard to the dangers
of AIDS, hard drugs and teen pregnancy is a social responsibility?
Sure. And a faster browser allows them to explore more things on
the Internet dealing with the dangers of these things :-)
Post by Programmer Dude
Post by Robert Redelmeier
If you don't like browsing, then don't work on a browser.
But if it's true that a faster browser is a social responsibility,
then I *ought* to be working on one.
Faster software, in general, is a social responsibility.
If you're not working on a faster browser, you should be
working on a faster version of whatever software you *are*
working on.

Of course, you should also be working on a cheaper, more
robust, etc., etc., version of the software too. Performance
isn't the only "socially responsible" attribute. That why the
field is an *engineering* field -- you've got to balance all
the compromises in order to produce a good (and socially
responsible) product. The problem with performance is that
software engineers have *far too long* relied upon the
effects of Moore's Law to cover the performance aspects
of their projects. Some of us just happen to believe that those
who take the attitude "There is no need to write efficient code"
are being socially irresponsible.

Cheers,
Randy Hyde

Cheers,
Randy Hyde
Programmer Dude
2005-02-22 23:27:23 UTC
Permalink
Post by Randall Hyde
Post by Programmer Dude
Wrong emphasis, I think. If there is any moral or social obligation,
it's for the worker to do the work--what ever it is--in a way that is
moral or socially responsible.
And the worker that produces the software for other workers should
do so in a way that makes their work more efficient. Wouldn't you
say?
I won't say so unless that were within the scope of the task. If the
task was to produce entertainment software, my goals might be different.

Taking this back to the point, writing faster browswers may be many
things, but it is NOT a social responsibility.
Post by Randall Hyde
Post by Programmer Dude
We have established that "I was paid" or "I was ordered" is not an
acceptable defense for an immoral or irresponsible act. The employee
has a moral/social obligation regardless of pay or orders.
Yes, they can quit. And forgo their moral/social contract to provide
for their families, etc. Philosophers have argued about this since
the dawn of the wage. Do you really think that you can condense it
down to two sentences and encapsulate some profound meaning in your
statements?
Eh? This is some sad attempt at a strawman argument. I have not made
any attempt to "encapsulate some profound meaning" in anything, so you'll
have to find another target.
Post by Randall Hyde
Is is particularly pathetic that you use this as an excuse for writing
sloppy code.
Now you've *really* missed the target. I take my work very seriously and
never produce sloppy code.
Post by Randall Hyde
Now, granted, there are some morally/socially responsible reasons
for writing sloppy, bloated, and inefficient code. But most of the
time this is due to laziness (or because "I was ordered to do so").
That's hardly a moral or socially responsible reason. Try to push
the responsibility of this onto the worker is a bit much.
You've gone off on some strange trip to left field.
Let me know when you return.
Post by Randall Hyde
Post by Programmer Dude
I don't see any moral/social connection to a specific requirement
(faster browsing). History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.
So wasting the user's time by making them spend *more* time doing
these activities, leaving less free time for other lifestyle activities,
is the socially responsible thing to do, eh?
Free clue: the world is a complicated place. That one thing isn't true
doesn't automagically make some made-up opposite true. It just means
that one thing isn't true.
Post by Randall Hyde
1. the "cooler" product
2. the product with more features
3. the product that costs less
4. the product that performs better
The Roman Blood Circus and public hangings were huge crowd pleasers,
and BAYWATCH was the most watched tv show worldwide at one point.

Public taste is usually taste-less.
Post by Randall Hyde
Pretty much in that order. Seems to me that most of the choices are
economic ones, not social ones (though #1 certainly stands out).
Of course, making a product more cost-effective (more features for
less money and more efficient to use) can certainly be considered a
social responsibility.
No, it can be considered a social *gift* or social charity, but I don't
see it as a *responsibility*. You've made no case supporting such an
idea.
Post by Randall Hyde
So yes, providing a faster browser is one example of being socially
responsible.
And even less of a case for this. [shrug]
Post by Randall Hyde
Post by Programmer Dude
But if it's true that a faster browser is a social responsibility,
then I *ought* to be working on one.
Faster software, in general, is a social responsibility.
Nonsense.
Post by Randall Hyde
If you're not working on a faster browser, you should be
working on a faster version of whatever software you *are*
working on.
The last part of that is probably true to some extent, but the *reason*
it's true is that it's the job I'm paid for. It has nothing to do with
social responsibility, per se, but with *job* responsibility.

Furthermore, making the software work faster is a bit down the list of
higher responsibilities.

For example, insuring software works *correctly* CAN be argued as a social
responsibility, because harm can come from your direct actions if your
software works incorrectly (and make no mistake, software errors have cost
lives).
Post by Randall Hyde
Of course, you should also be working on a cheaper, more
robust, etc., etc., version of the software too. Performance
isn't the only "socially responsible" attribute.
Performance isn't a "socially responsible" attribute At All.
Post by Randall Hyde
The problem with performance is that software engineers have *far too
long* relied upon the effects of Moore's Law to cover the performance
aspects of their projects. Some of us just happen to believe that those
who take the attitude "There is no need to write efficient code"
are being socially irresponsible.
Pity. I was 100% with you up to the last two words.

It's NOT a social responsibility. It's a lot of things, but not that.
"-\\\\o//-annabee" @
2005-02-23 03:56:43 UTC
Permalink
PÃ¥ Tue, 22 Feb 2005 17:27:23 -0600, skrev Programmer Dude
Post by Programmer Dude
Performance isn't a "socially responsible" attribute At All.
Gives me smileys that you, a "speed guru", are having this conversation
with the author of the slowest textconverter (HLA) in known universe :)))
And He is the one arguing for the importance of speed. :))

My input ? - A fast browers will allow us to faster see that it is
sosially irresponsible to use it. :)) (I hate the webbrowsers. They seem
to push stationary software out of view of the public. Soon we are all
going to use java or net based tools, or just dont be seen at all ? ) And
to be playing our game via the net only ? Browsers are slowly turning the
PC into NCs ?

Maybe, its even good they are slow, since this will make it happen slower
?
Post by Programmer Dude
It's NOT a social responsibility. It's a lot of things, but not that.
My view would be that sosial responsibility comes into EVERYTHING we do.
So in this sense, I am somewhat in agreement with Randy, on theoretical
basis.
--
"my life insists on standing still at a tremendous speed". - Freely after
Thomas Hylland Eriksen
http://TheWannabee.org
Programmer Dude
2005-02-25 00:29:58 UTC
Permalink
Post by "-\\\\o//-annabee" @
Post by Programmer Dude
It's NOT a social responsibility. It's a lot of things, but not that.
My view would be that sosial responsibility comes into EVERYTHING we do.
So in this sense, I am somewhat in agreement with Randy, on theoretical
basis.
Agreed. My point was that the specific action of creating faster browsers
is not a social responsibility in any way that stands out from "ordinary"
social responsibilities.

And it's not impossible that dedicating yourself to making the fastest
browser in existance could be socially *ir*responsible (although I'll
grant that's probably a bit of a stretch :-).
Randall Hyde
2005-02-23 04:22:24 UTC
Permalink
Post by Programmer Dude
Eh? This is some sad attempt at a strawman argument. I have not made
any attempt to "encapsulate some profound meaning" in anything, so you'll
have to find another target.
"Wrong emphasis, I think. If there is any moral or social obligation,
it's for the worker to do the work--what ever it is--in a way that is
moral or socially responsible."

Did you not say that?
Post by Programmer Dude
Now you've *really* missed the target. I take my work very seriously and
never produce sloppy code.
You *never* produce sloppy code?
Hmm.... Either you have a lax definition of sloppy, you don't write
much code, or you're exaggerating a bit :-) If you've written any
reasonable quantity of code, chances are pretty good we can find
a little bit of slop here and there. And that's going to be true no
matter *how* serious you are about your work. But, as you say,
the point is irrelevant. Whether your code is sloppy or not isn't
the issue. The issue is that programmers in general write sloppy code
and their sloppiness impacts users of software, in general.
Post by Programmer Dude
Post by Randall Hyde
Now, granted, there are some morally/socially responsible reasons
for writing sloppy, bloated, and inefficient code. But most of the
time this is due to laziness (or because "I was ordered to do so").
That's hardly a moral or socially responsible reason. Try to push
the responsibility of this onto the worker is a bit much.
You've gone off on some strange trip to left field.
Let me know when you return.
Other than a personal attack, you've said absolutely nothing
to counter the assertion that most of the bloated, inefficient,
code is due to laziness on the programmers' part. Let me know
when you've got proof that this isn't true.
Post by Programmer Dude
Post by Randall Hyde
Pretty much in that order. Seems to me that most of the choices are
economic ones, not social ones (though #1 certainly stands out).
Of course, making a product more cost-effective (more features for
less money and more efficient to use) can certainly be considered a
social responsibility.
No, it can be considered a social *gift* or social charity, but I don't
see it as a *responsibility*. You've made no case supporting such an
idea.
Suppose one person has control over the productivity of 1000s or
hundreds of thousands of people. With a little more *one-time* effort
on the part of this one person the productivity of all those others can
be improved. You consider it *charity* on the part of this person to
improve the productivity of the others? Hmmm.... Please list the
software products you've worked on. Those of us who care about
our productivity would like to know so we can avoid them. :-)
You claim to take your work very seriously. But if you miss this
fundamental fact about how your actions affect other people, or
if you take the attitude that you're being "generous" or "offering
charity" when you improve things for your users, you might want
to rethink your ethics a bit.
Post by Programmer Dude
Post by Randall Hyde
Faster software, in general, is a social responsibility.
Nonsense.
Sense.
Post by Programmer Dude
Post by Randall Hyde
If you're not working on a faster browser, you should be
working on a faster version of whatever software you *are*
working on.
The last part of that is probably true to some extent, but the *reason*
it's true is that it's the job I'm paid for. It has nothing to do with
social responsibility, per se, but with *job* responsibility.
You have the social responsibility even if the *job* responsibility
isn't there. The two are not mutually exclusive, nor are they
always in step with one other (your boss, for example, may
insist on your cutting corners in your code to get some demo done
faster; is that the moral thing to do? It's certainly the right thing
to do as a *job* responsibility.)
Post by Programmer Dude
Furthermore, making the software work faster is a bit down the list of
higher responsibilities.
Now you're the one making things up.
No one said that faster software was the most important thing.
Indeed, in the list I gave that you blew off, it was fourth on the list.
Post by Programmer Dude
For example, insuring software works *correctly* CAN be argued as a social
responsibility, because harm can come from your direct actions if your
software works incorrectly (and make no mistake, software errors have cost
lives).
And you talk about me coming out of left field?
Again, you're talking like "fast" is the only priority.
Don't expect any arguments that writing correct software is a social
responsbility. Same argument applies to speed and several other
attributes associated with software development. The mere fact that
you claim "correct software" is a social responsibility pretty much means
that "efficient" belongs in that same group. Both are typical attributes
that good software should possess.
Post by Programmer Dude
Post by Randall Hyde
Of course, you should also be working on a cheaper, more
robust, etc., etc., version of the software too. Performance
isn't the only "socially responsible" attribute.
Performance isn't a "socially responsible" attribute At All.
:-)
Again, please list the software products you've worked on.
Some of us would like to avoid them like the plague.
Post by Programmer Dude
Post by Randall Hyde
The problem with performance is that software engineers have *far too
long* relied upon the effects of Moore's Law to cover the performance
aspects of their projects. Some of us just happen to believe that those
who take the attitude "There is no need to write efficient code"
are being socially irresponsible.
Pity. I was 100% with you up to the last two words.
It's NOT a social responsibility. It's a lot of things, but not that.
Whatever you say. Please provide a list of projects you've worked on.
Some of us have a social responsibility to avoid the use of such software
:-)
Cheers,
Randy Hyde
Programmer Dude
2005-02-25 01:10:16 UTC
Permalink
Post by Randall Hyde
Post by Programmer Dude
Post by Randall Hyde
Post by Programmer Dude
We have established that "I was paid" or "I was ordered" is not an
acceptable defense for an immoral or irresponsible act. The employee
has a moral/social obligation regardless of pay or orders.
Yes, they can quit. And forgo their moral/social contract to provide
for their families, etc. Philosophers have argued about this since
the dawn of the wage. Do you really think that you can condense it
down to two sentences and encapsulate some profound meaning in your
statements?
Eh? This is some sad attempt at a strawman argument. I have not made
any attempt to "encapsulate some profound meaning" in anything, so you'll
have to find another target.
"Wrong emphasis, I think. If there is any moral or social obligation,
it's for the worker to do the work--what ever it is--in a way that is
moral or socially responsible."
Did you not say that?
Obviously. If you think there's profundity therein, you need to get out
more! :-) It seems self-evident to me, not profound. [shrug]
Post by Randall Hyde
Post by Programmer Dude
Now you've *really* missed the target. I take my work very seriously
and never produce sloppy code.
You *never* produce sloppy code?
Never willingly. Never intentionally.
Post by Randall Hyde
Hmm.... Either you have a lax definition of sloppy, you don't write
much code, or you're exaggerating a bit :-)
If we are talking about what I put into production, then the answer is
as close to "never" as *humanly* possible. Yeah, sure, I've probably
had a bad day now and again, but if I have any say in the matter, then
no, I do not produce sloppy code.

Ever.
Post by Randall Hyde
If you've written any reasonable quantity of code, chances are pretty
good we can find a little bit of slop here and there. And that's
going to be true no matter *how* serious you are about your work.
Certainly. I assumed we were talking about programmers who allow slop
due to thinking "it doesn't matter" or whatever excuse is handy. That
is territory I never visit.
Post by Randall Hyde
The issue is that programmers in general write sloppy code
and their sloppiness impacts users of software, in general.
Huge agreement! I just spent a couple hours re-writing some code the
local "genius" had cranked out. Ugh, blech, Yuck.
Post by Randall Hyde
Post by Programmer Dude
No, it can be considered a social *gift* or social charity, but I don't
see it as a *responsibility*. You've made no case supporting such an
idea.
Suppose one person has control over the productivity of 1000s or
hundreds of thousands of people. With a little more *one-time* effort
on the part of this one person the productivity of all those others can
be improved. You consider it *charity* on the part of this person to
improve the productivity of the others?
Actually, unless it's that person's job, it IS charity. Nothing wrong
with that, either. I've volunteered to various mentoring organizations
for years.
Post by Randall Hyde
Hmmm.... Please list the software products you've worked on. Those of
us who care about our productivity would like to know so we can avoid
them. :-)
Don't worry, most of my work is internal to the corporation, so you are
in no danger. You may very well, however, have used a product that my
work had some connection to.
Post by Randall Hyde
You claim to take your work very seriously. But if you miss this
fundamental fact about how your actions affect other people, or
if you take the attitude that you're being "generous" or "offering
charity" when you improve things for your users, you might want
to rethink your ethics a bit.
You're assuming you know about my ethics. You *clearly* do not, since
you've missed the target by, as they say, a country mile.

Let's try to stay focused, eh? This is about the suggestion that
faster browsers--in and of themselves--might be a social responsibility.
I continue to find the suggestion absurd.
Post by Randall Hyde
Post by Programmer Dude
Post by Randall Hyde
If you're not working on a faster browser, you should be
working on a faster version of whatever software you *are*
working on.
The last part of that is probably true to some extent, but the *reason*
it's true is that it's the job I'm paid for. It has nothing to do with
social responsibility, per se, but with *job* responsibility.
You have the social responsibility even if the *job* responsibility
isn't there.
I don't agree. You're assuming faster software is necessarily a morally
good thing. There's no evidence that supports that. It's just what
people think they need and providing people with what they think they
need is not necessarily a morally good thing.

For an extreme and ugly example, some people think they need to have
sex with children. NOT a good need to meet!!
Post by Randall Hyde
The two are not mutually exclusive, nor are they always in step with
one other (your boss, for example, may insist on your cutting corners
in your code to get some demo done faster; is that the moral thing
to do? It's certainly the right thing to do as a *job* responsibility.)
You seemed to react negatively when I said much the same.
Post by Randall Hyde
Post by Programmer Dude
Furthermore, making the software work faster is a bit down the list
of higher responsibilities.
Now you're the one making things up.
How so?
Post by Randall Hyde
No one said that faster software was the most important thing.
No one said it wasn't. (You have a real problem with straw targets.)
Post by Randall Hyde
Indeed, in the list I gave that you blew off, it was fourth on the list.
List that I "blew off"? Sheeze. Are you 12?
Post by Randall Hyde
Post by Programmer Dude
For example, insuring software works *correctly* CAN be argued as a social
responsibility, because harm can come from your direct actions if your
software works incorrectly (and make no mistake, software errors have cost
lives).
And you talk about me coming out of left field?
Are you not aware of the rather infamous software-caused deaths?
Go Oogle for [software death radiation]. First hit.
Post by Randall Hyde
Again, you're talking like "fast" is the only priority.
No, that's just you stuffing a straw target in my mouth. [spits]

This is *strictly* about this single line:
} At some point, fast software becomes a social responsibility.

No. I don't agree.
Post by Randall Hyde
Don't expect any arguments that writing correct software is a social
responsbility. Same argument applies to speed and several other
attributes associated with software development. The mere fact that
you claim "correct software" is a social responsibility pretty much means
that "efficient" belongs in that same group. Both are typical attributes
that good software should possess.
True that good software should possess, but false that "correct" is in
the same league as "efficient". Incorrect software is unacceptable in
any situation I can think of. Inefficient software may well be acceptable
in some situations.

Recall the old adage:
Make it work.
Make it work right.
Make it work fast.
Post by Randall Hyde
Post by Programmer Dude
Performance isn't a "socially responsible" attribute At All.
:-)
Again, please list the software products you've worked on.
Some of us would like to avoid them like the plague.
As I said, you're safe.

Just for the record, some recent projects include a test system for
quality testing respirators, several manufacturing process monitors,
numerous database-related projects and a heart/lung machine test
system.

One business unit went on to win an award (assisted by my software),
and another uses my software as a show piece for visiters. Much more
meaningful to me, a programmer I did some work for (the respirators
monitor) called me last week just to tell me he'd needed to modify
my code to add a new feature and was delighted at how easy it was to
work with. THAT made my day, since as a corporate programmer, a big
part of my work is devoted to making it easier for the next guy.

Meanwhile some guy in amUSENET who's never met me, never seen a line
of my code, and who clearly doesn't have clue one who I am, wants to
avoid my software?

Heh. Whaaddevah.
NoDot
2005-02-26 13:50:15 UTC
Permalink
Post by Programmer Dude
Meanwhile some guy in amUSENET who's never met me, never seen a line
of my code, and who clearly doesn't have clue one who I am, wants to
avoid my software?
Just to point out that person, it's Randall Hyde, author of the book
_Art of Assembly_, creator of HLA, and a former University teacher.
Post by Programmer Dude
Heh. Whaaddevah.
--
The above was written by NoDot.

Visit the Website of NoDot:
<www.geocities.com/nodot1989/>
Randall Hyde
2005-02-26 18:40:17 UTC
Permalink
Post by NoDot
Post by Programmer Dude
Meanwhile some guy in amUSENET who's never met me, never seen a line
of my code, and who clearly doesn't have clue one who I am, wants to
avoid my software?
Just to point out that person, it's Randall Hyde, author of the book
_Art of Assembly_, creator of HLA, and a former University teacher.
Who I am and what my accomplishments are, well, they are nearly
irrelevant here. If these posts were the first computer-related things
I'd said in my life they would still be just as true.

Mr Programmer Dude seems to feel that there is no moral , social, or
ethical responsibility for writing code that doesn't wastes the end-user's
time and reduce their productivity (unless, of course, the job requirements
absolutely specify it).

As for reasons for avoiding his software, the fact that he *virulently*
argues
that it is *not* an obligation for programmers to write fast code (as
opposed
to simply ignoring the whole argument) raises grave concerns about the
type of code he writes. One doesn't need to look at a line of his code to
be *gravely* concerned about the type of code he writes if this is his
attitude ("I don't owe users anything..."). Yes, I would want to avoid his
software like the plague. I'd prefer to use software written by people who
take an active interest in ensuring that their software has the end-users'
best interests in mind (including being as fast as reasonably possible in
order to avoid wasting their time).
Cheers,
Randy Hyde
infobahn
2005-02-26 19:01:25 UTC
Permalink
[mild text reflowing]

Randall Hyde wrote:
<snip>
Post by Randall Hyde
As for reasons for avoiding his software, the fact that he
*virulently* argues that it is *not* an obligation for
programmers to write fast code (as opposed to simply ignoring
the whole argument) raises grave concerns about the type of
code he writes. One doesn't need to look at a line of his code
to be *gravely* concerned about the type of code he writes if
this is his attitude ("I don't owe users anything..."). Yes,
I would want to avoid his software like the plague. I'd prefer
to use software written by people who take an active interest
in ensuring that their software has the end-users' best
interests in mind (including being as fast as reasonably
possible in order to avoid wasting their time).
I'm not entirely sure that I agree with you. I *would* agree that
it is incumbent on the programmer not to write sloppy programs,
but I think there are more important considerations than raw speed.
For example, robustness, code clarity, maintainability, and of
course correctness.

The overwhelming priority should be to choose sensible, high
performance algorithms, and implement them intelligently. If
you do that, the chances are that the code will be "fast
enough" anyway.

This isn't to minimise the importance of speed in speed-critical
applications. But for most applications, a millisecond here or
there is not even remotely as important as other, often conflicting,
requirements.
Randall Hyde
2005-02-26 20:26:14 UTC
Permalink
Post by infobahn
I'm not entirely sure that I agree with you. I *would* agree that
it is incumbent on the programmer not to write sloppy programs,
but I think there are more important considerations than raw speed.
For example, robustness, code clarity, maintainability, and of
course correctness.
No one is claiming that there aren't other attributes a program should
have. No one is even claiming that speed should be the number one
attribute. But when someone claims that a programmer doesn't have
a responsibility to provide efficient code, that's a problem. When
someone argues that performance shouldn't be considered part
of a programmer's responsibility to society, that attitude is problematic.
Post by infobahn
The overwhelming priority should be to choose sensible, high
performance algorithms, and implement them intelligently. If
you do that, the chances are that the code will be "fast
enough" anyway.
Yes, but then the programmer has taken the imperative to
produce high-performance code that doesn't waste the end-user's
time, haven't they? Don't get me wrong, I'm not claiming that
it is a programmer's moral imperative to write the fastest possible
code. What we're talking about here is *not* wasting the user's
time.
Post by infobahn
This isn't to minimise the importance of speed in speed-critical
applications. But for most applications, a millisecond here or
there is not even remotely as important as other, often conflicting,
requirements.
We're not talking about milliseconds. The original discussion was
about slow updates on browsers. Clearly, wasting a few milliseconds
here and there is irrelevant. Nor are we discussion slow software
in general. Some algorithms, even if they are the best we can come
up with, are going to be slow.

But if a programmer takes the attitude that "I am more important
that the peon end users, my time is more valuable than their's, so
I will take short cuts in my code so that I am more productive
(even at the expense of the end users)" then I have a big problem
with that attitude. Given the ubquitessnous of browser software
(and remembering that this topic started when the exclamation
that writing a fast performing browser is a social responsibility),
I find it hard to believe that someone would argue it is *not*
a social responsibility to create a fast browser. The same
holds true for other popular software.

Does this argument apply in all cases? Of course not.
You have to balance the programmer's time against the
users' time. If you have very few users, then the programmer
has less of a "social obligation" to provide fast software.
If your software has thousands and thousands, or millions,
of users, then any shortcuts taken have a big impact on
society. Trying to argue for the validity of not taking the
time and effort to improve the performance by claiming
that "society is too fast-paced anyway" is not a valid
argument.

Cheers,
Randy Hyde
Randy Howard
2005-02-26 23:16:14 UTC
Permalink
Post by Randall Hyde
Yes, but then the programmer has taken the imperative to
produce high-performance code that doesn't waste the end-user's
time, haven't they?
And watching the load average on my system, they seems to be
doing it fairly well. I wish the hard drive manufacturers
felt the same moral imperative not to waste my time.

:-(
Post by Randall Hyde
I find it hard to believe that someone would argue it is *not*
a social responsibility to create a fast browser. The same
holds true for other popular software.
The whole reason browsers are slow is because of the web
admins turning their websites into saturday morning cartoons.
Any web browser you pick is smoking fast on a well-designed
web page. It's bandwidth, not CPU use that is slowing down
those page loads on reasonable modern client systems.
Post by Randall Hyde
You have to balance the programmer's time against the
users' time. If you have very few users, then the programmer
has less of a "social obligation" to provide fast software.
How does a programmer have the "social obligation" when his
boss sets the schedule and the feature list? :-)
--
Randy Howard (2reply remove FOOBAR)
"Making it hard to do stupid things often makes it hard
to do smart ones too." -- Andrew Koenig
Randall Hyde
2005-02-27 00:33:07 UTC
Permalink
Post by Randy Howard
Post by Randall Hyde
Yes, but then the programmer has taken the imperative to
produce high-performance code that doesn't waste the end-user's
time, haven't they?
And watching the load average on my system, they seems to be
doing it fairly well. I wish the hard drive manufacturers
felt the same moral imperative not to waste my time.
:-(
The argument isn't about bypassing the laws of physics.
If software is as fast as it can be (or reasonably close), and it's
still slow, the time "wasted" by the end-user isn't the programmer's
responsibility. Likewise, if your disk driver manufacturer has
produced disk drives that are as fast as current technology allows
(at a given price point, of course), then you can't hold them
responsible.

Of course, if you are using IDE/ATA drives rather than
high-performance SCSI drives, then *you've* made the
choice, not the drive manufacturer :-).
Post by Randy Howard
Post by Randall Hyde
I find it hard to believe that someone would argue it is *not*
a social responsibility to create a fast browser. The same
holds true for other popular software.
The whole reason browsers are slow is because of the web
admins turning their websites into saturday morning cartoons.
Any web browser you pick is smoking fast on a well-designed
web page. It's bandwidth, not CPU use that is slowing down
those page loads on reasonable modern client systems.
Bandwidth is one issue. But rending speed and clever algorithms
are another source of low performance in browsers.
Post by Randy Howard
Post by Randall Hyde
You have to balance the programmer's time against the
users' time. If you have very few users, then the programmer
has less of a "social obligation" to provide fast software.
How does a programmer have the "social obligation" when his
boss sets the schedule and the feature list? :-)
Because now you have *conflicting* obligations. And how one
resolves such conflict is the stuff great philosophical discussions
are made of. However, the fact that there is a conflict in no way
suggests that the social obligation not to waste user's time doesn't
exist.

As for dealing with the boss, it is certainly a work-related
obligation to let the boss know when they haven't allowed
enough time to create a proper product. If the boss' schedule
forces you to constantly write hacked, "quick and dirty" code,
then you're definitely shirking some "social" and "job" obligations
here.

If your software project isn't going to make deadlines, the
appropriate solution is *not* to start hacking and writing
"quick and dirty" (and usually inefficient) code in order to
meet the deadlines. Instead, it's your responsibility to discuss
the scheduling problem with your boss. Don't forget, the
boss isn't expecting a hachet job when you deliver the software.
Your boss is assuming you're delivering quality stuff on
the schedule. Unless you get the boss to sign-off on a quick
and dirty approach, you're not delivering what your boss
wants.
Cheers,
Randy Hyde
Randy Howard
2005-02-27 01:21:00 UTC
Permalink
Post by Randall Hyde
Post by Randy Howard
Post by Randall Hyde
Yes, but then the programmer has taken the imperative to
produce high-performance code that doesn't waste the end-user's
time, haven't they?
And watching the load average on my system, they seems to be
doing it fairly well. I wish the hard drive manufacturers
felt the same moral imperative not to waste my time.
:-(
The argument isn't about bypassing the laws of physics.
if your disk driver manufacturer has
produced disk drives that are as fast as current technology allows
(at a given price point, of course), then you can't hold them
responsible.
Excuse me, but could you please explain why disk drive manufacturers
have a get out of jail free card on price, but software does not?

Should a free browser perform as well as a commercial one? Or
should you get world's best browser performance without having to
pay a price equivalent to that of a 14-drive RAID 0 U320 Scsi
enclosure with a big hardware cache accelerator in a PCI-express
x16 slot?
Post by Randall Hyde
Post by Randy Howard
The whole reason browsers are slow is because of the web
admins turning their websites into saturday morning cartoons.
Any web browser you pick is smoking fast on a well-designed
web page. It's bandwidth, not CPU use that is slowing down
those page loads on reasonable modern client systems.
Bandwidth is one issue. But rending speed and clever algorithms
are another source of low performance in browsers.
Bandwidth is THE issue. I can't remember ever seeing rendering
a web page shoot my CPU load off the rev limiter. There may
be some variances having to do with opening multiple connections
to a web site to load pages faster (overlapped I/O), but
again bandwidth becomes the overriding throttle on this technique.

Once everybody has a full DS3 to their house, it might be better,
but odds are even then webmasters will just have cluttered up
the sites more to take up the extra bandwidth.
Post by Randall Hyde
Post by Randy Howard
How does a programmer have the "social obligation" when his
boss sets the schedule and the feature list? :-)
Because now you have *conflicting* obligations. And how one
resolves such conflict is the stuff great philosophical discussions
are made of. However, the fact that there is a conflict in no way
suggests that the social obligation not to waste user's time doesn't
exist.
Why does the boss not have a social obligation not to waste the
user's time? Does a programmer's responsibility to his employer
have any weight at all, or is he to act independently of his
company's (and perhaps stockholder's) wishes? What color is the
sky in your world?
--
Randy Howard (2reply remove FOOBAR)
"Making it hard to do stupid things often makes it hard
to do smart ones too." -- Andrew Koenig
Randall Hyde
2005-02-27 01:53:54 UTC
Permalink
Post by Randy Howard
Post by Randall Hyde
The argument isn't about bypassing the laws of physics.
if your disk driver manufacturer has
produced disk drives that are as fast as current technology allows
(at a given price point, of course), then you can't hold them
responsible.
Excuse me, but could you please explain why disk drive manufacturers
have a get out of jail free card on price, but software does not?
Because they *do* provide alternatives that are high-performance.
And you're forgetting a crucial point here: there are manufacturing
cost differences between low-performance drives and high-performance
drives that affect the final cost. In general, the manufacturing costs for
software, high or low performance, are the same: zero (or sufficiently
close). Certainly, there isn't much of a difference in cost (download
bandwidth, space on a CD/DVD?) between the two. Indeed, it is
a paradox that the more efficient one is probably smaller, and the
manufacturing cost is actually *less*.

By the same token, programmers get a "get out of jail free" card
on the issue of *features*. That is, you pay less for a lower-featured
program (in theory) than you do for a highly-featured version.
And if programmers offered a "slow" version at a lower cost
and a "fast" version at a higher cost, that would be okay too.
Because then you're letting the consumer (end-user) make the
decision. However, if you provide only one version of the
program, then the end-user has to live with that.

In theory, competition could also provide this. Want a faster
browsing experience? Then use XXXX browser rather than
YYYY browser.
Post by Randy Howard
Should a free browser perform as well as a commercial one?
The cost of manufacturing both pieces of software is essentially
the same: zero.
Post by Randy Howard
Or
should you get world's best browser performance without having to
pay a price equivalent to that of a 14-drive RAID 0 U320 Scsi
enclosure with a big hardware cache accelerator in a PCI-express
x16 slot?
See the argument above.
Post by Randy Howard
Post by Randall Hyde
Post by Randy Howard
The whole reason browsers are slow is because of the web
admins turning their websites into saturday morning cartoons.
Any web browser you pick is smoking fast on a well-designed
web page. It's bandwidth, not CPU use that is slowing down
those page loads on reasonable modern client systems.
Bandwidth is one issue. But rending speed and clever algorithms
are another source of low performance in browsers.
Bandwidth is THE issue. I can't remember ever seeing rendering
a web page shoot my CPU load off the rev limiter. There may
be some variances having to do with opening multiple connections
to a web site to load pages faster (overlapped I/O), but
again bandwidth becomes the overriding throttle on this technique.
I have. For example, when browsing local files rather than
browsing files over the internet.
Post by Randy Howard
Once everybody has a full DS3 to their house, it might be better,
but odds are even then webmasters will just have cluttered up
the sites more to take up the extra bandwidth.
DS3 still doesn't match local file speed. And I've observed that
IE doesn't do well on a lot of stuff I look at locally.
Post by Randy Howard
Why does the boss not have a social obligation not to waste the
user's time? Does a programmer's responsibility to his employer
have any weight at all, or is he to act independently of his
company's (and perhaps stockholder's) wishes? What color is the
sky in your world?
Because the boss typically doesn't know squat about what it
takes to write efficient software. The boss doesn't make the
design desisions (or get lazy and not bother to write great code)
that lead to bloated, slow code. Now if the boss explicitly tells
the programmer to write "quick and dirty" code, then the boss
definitely takes the responsibility. But for the most part, it's the
programmers making this decision, not their bosses.

Perhaps you would feel more comfortable if we changed the
argument "programmers have a social obligation to write
fast XXXX programs" to "programmers have a social
obligation *not* to write crappy, slow, code?"
Unfortunately, both statements turn out to mean the same
thing. Because if programmers aren't diligent about writing
efficient code, they usually wind up writing crappy,
inefficient code, even if not on purpose.
Cheers,
Randy Hyde
Randy Howard
2005-02-27 02:30:52 UTC
Permalink
Post by Randall Hyde
Post by Randy Howard
Excuse me, but could you please explain why disk drive manufacturers
have a get out of jail free card on price, but software does not?
Because they *do* provide alternatives that are high-performance.
No, there are I/O bound applications for which there does not
exist a storage technology sufficiently fast to remove the
bottleneck. Therefore, disk drive designers have a social
imperative to correct the problem by providing faster storage.
You can't spend enough money currently to purchase hardware to
make this problem go away.
Post by Randall Hyde
And you're forgetting a crucial point here: there are manufacturing
cost differences between low-performance drives and high-performance
drives that affect the final cost.
I'm not forgetting it, it's simply not the point. COGS includes
both development and production costs. If you include all the
costs of bringing a piece of software or hardware to market, your
arbitrary distinction disappears in the noise.
Post by Randall Hyde
By the same token, programmers get a "get out of jail free" card
on the issue of *features*. That is, you pay less for a lower-featured
program (in theory) than you do for a highly-featured version.
Where is this shown? I can get a whole lot more features for free
in many OSS packages than I can in very expensive commercial
packages. There is no evidence that price is a determinant of
functionality or performance. OSS skews the economics, because
the development costs are performed "pro bono".

If you consider only commercial software, I still don't see any
evidence that the higher priced package between two competitors
is the most feature rich. More often than not the converse is
true.
Post by Randall Hyde
And if programmers offered a "slow" version at a lower cost
and a "fast" version at a higher cost, that would be okay too.
Because then you're letting the consumer (end-user) make the
decision. However, if you provide only one version of the
program, then the end-user has to live with that.
And the end-user has the option to buy the one version that
exists, or buy something else. If it wasn't for monopoly
behavior by Microsoft, this idea probably wouldn't have even
come up. The end-user has the credit card, there is the
decision.

Perhaps you'd like the whole world to think that if every line
of code isn't hand-tuned assembly then it's not good enough
to buy. I don't really care if vi is optimized for my AMD
64-bit processor, because I can't type fast enough for it
to matter.

I've certainly written my share of assembler, WHEN PROFILING
SHOWED THAT IT WAS IMPORTANT, but I don't do it just for
the fun of it in a bunch of functions that get called once
a week, so I can tell everybody how many imaginary clock
ticks I could save if they got called 3000 times a second
instead.

I'm not trying to be facetious, I've seen people spend
days or weeks optimizing code that would never show up
in any production performance test, no matter how
accurate your clock is. Even worse, more often than not
the optimized code would contain bugs not present in
the original. Programmers have a bigger social responsibility
to preventing bugs making it out the door than wringing
every last clock tick out of the code.
Post by Randall Hyde
In theory, competition could also provide this. Want a faster
browsing experience? Then use XXXX browser rather than
YYYY browser.
Of course. The fact that this isn't widely advertised shows
that the market doesn't care. If there was even one drop of
marketing data showing people would pay extra for spare
clock ticks, we'd have benchmarks on everything. As is,
gamer boys seems to be the only market segment that really
is willing to spend extra for such minor improvements.

On the high-end server side, the rules are different, but
the money is still mostly spent on I/O bottleneck removal
(10Gig E, big-cache RAID, jumbo memory, high-end switches,
SMP, etc.)
Post by Randall Hyde
Post by Randy Howard
Once everybody has a full DS3 to their house, it might be better,
but odds are even then webmasters will just have cluttered up
the sites more to take up the extra bandwidth.
DS3 still doesn't match local file speed.
It's actually pretty close to the expected random I/O throughput
from a conventional IDE hard drive. But, that's not really
the point. I was just saying that no matter what the bandwidth,
web designers will try to take more than their fair share of it
anyway.
Post by Randall Hyde
And I've observed that IE doesn't do well on a lot of stuff
I look at locally.
IE is a piece of crap. If that's the basis for your arguments,
we need to rewind a bit. I took it on faith that no serious
technical discussion on Usenet would involve people actively
using IE.
Post by Randall Hyde
Perhaps you would feel more comfortable if we changed the
argument "programmers have a social obligation to write
fast XXXX programs" to "programmers have a social
obligation *not* to write crappy, slow, code?"
Absolutely. You could have said that a long time ago. LOL

This does raise the issue that most programmers are not
qualified to perform the latter, with or without a boss
in the way.
Post by Randall Hyde
Unfortunately, both statements turn out to mean the same
thing. Because if programmers aren't diligent about writing
efficient code, they usually wind up writing crappy,
inefficient code, even if not on purpose.
I disagree. Well, perhaps SOME programmers have that
result, we have certainly seen some examples of it here
(comp.programming) in the last year or so, but that is
not typical amongst serious professionals.
--
Randy Howard (2reply remove FOOBAR)
"Making it hard to do stupid things often makes it hard
to do smart ones too." -- Andrew Koenig
Gerry Quinn
2005-02-27 11:22:01 UTC
Permalink
Post by Randall Hyde
Post by Randy Howard
Bandwidth is THE issue. I can't remember ever seeing rendering
a web page shoot my CPU load off the rev limiter. There may
be some variances having to do with opening multiple connections
to a web site to load pages faster (overlapped I/O), but
again bandwidth becomes the overriding throttle on this technique.
I have. For example, when browsing local files rather than
browsing files over the internet.
Mightn't programmers have a social responsibility to make browsers
render over-large files slowly, so that people will not upload pages
that work all right from hard disk but are unacceptable on a website?

- Gerry Quinn
Phil Carmody
2005-02-27 14:32:54 UTC
Permalink
Post by Randall Hyde
Post by Randy Howard
The whole reason browsers are slow is because of the web
admins turning their websites into saturday morning cartoons.
Any web browser you pick is smoking fast on a well-designed
web page. It's bandwidth, not CPU use that is slowing down
those page loads on reasonable modern client systems.
Bandwidth is one issue. But rending speed and clever algorithms
are another source of low performance in browsers.
I don't want a browser fast enough to rend anything, thank you!
:-0

Phil

Phil Carmody
2005-02-27 12:02:26 UTC
Permalink
Post by infobahn
[mild text reflowing]
Pah! What you need is more bizarro text reflowing...
Post by infobahn
<snip>
Post by Randall Hyde
As for reasons for avoiding his software, the fact that he
codes malware should be ample warning. A comment in W32.b0g0s.MM
Post by infobahn
Post by Randall Hyde
*virulently* argues that it is *not* an obligation for
users to even like his work. He did include an advert seeking new
Post by infobahn
Post by Randall Hyde
programmers to write fast code (as opposed to simply ignoring
speed concerns). Such admitted newbiedom (making a mockery of
Post by infobahn
Post by Randall Hyde
the whole argument) raises grave concerns about the type of
any variable he touches. Some might argue that it's not really
Post by infobahn
Post by Randall Hyde
code he writes. One doesn't need to look at a line of his code
unless wanting migraines and also confusion. It would be easier
Post by infobahn
Post by Randall Hyde
to be *gravely* concerned about the type of code he writes if
it compiled, since it could then be _run_. It's likely that
Post by infobahn
Post by Randall Hyde
this is his attitude ("I don't owe users anything..."). Yes,
he doesn't realise he'd have to pay users to touch his code.
Post by infobahn
Post by Randall Hyde
I would want to avoid his software like the plague. I'd prefer
the work of proper virus artisans, as it would be less horrid
Post by infobahn
Post by Randall Hyde
to use software written by people who take an active interest
in writing creative, well-built viruses, those who take pride
Post by infobahn
Post by Randall Hyde
in ensuring that their software has the end-users' best
porn pics randomised. But use his work if you have masochistic
Post by infobahn
Post by Randall Hyde
interests in mind (including being as fast as reasonably
heavily laden hippos at aviation - but let's be clear that's im-
Post by infobahn
Post by Randall Hyde
possible in order to avoid wasting their time).
Phil
Willem
2005-02-26 19:06:34 UTC
Permalink
Randall wrote:
) Who I am and what my accomplishments are, well, they are nearly
) irrelevant here. If these posts were the first computer-related things
) I'd said in my life they would still be just as true.

Agreed wholeheartedly.

) Mr Programmer Dude seems to feel that there is no moral , social, or
) ethical responsibility for writing code that doesn't wastes the end-user's
) time and reduce their productivity (unless, of course, the job requirements
) absolutely specify it).

As far as I understand his arguments, he only feels that there is no
*social* responsibility. Also, the words you put between parentheses
are a grave overexaggeration, implying that he would hold himself to the
exact specifications and not do anything beyond that.

) As for reasons for avoiding his software, the fact that he *virulently*
) argues that it is *not* an obligation for programmers to write fast code

I think you misunderstood him there. His whole argument is based upon his
belief that this obligation is not a *social* one. I've not seen him argue
that it is *not* an obligation.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randall Hyde
2005-02-26 20:33:42 UTC
Permalink
Post by Willem
As far as I understand his arguments, he only feels that there is no
*social* responsibility. Also, the words you put between parentheses
are a grave overexaggeration, implying that he would hold himself to the
exact specifications and not do anything beyond that.
It is understood that we are talking about a *social* obligation here.
Post by Willem
) As for reasons for avoiding his software, the fact that he *virulently*
) argues that it is *not* an obligation for programmers to write fast code
I think you misunderstood him there. His whole argument is based upon his
belief that this obligation is not a *social* one. I've not seen him argue
that it is *not* an obligation.
No, I don't misunderstand him at all. It is a *social* obligation.
Remember, we are talking about browsers here (and popular software
with lots of users, in general). If you save only a minute a day per user,
that equates to a tremendous amount of "found time" every day. As
pointed out earlier in this thread, one day of such savings can pay
for a tremendous amount of programmer time; even if you treat
programmers as highly-paid individuals and assume everyone else
is earning minimum wage (just to attach some economics to it).

Trying to argue that this isn't necessary, because "society is too
fast-paced
anyway" is nonsense. Programmers don't have the right to choose how
their end-users should spend their time. To put it in other terms, suppose
I said that as a condition of using my program each day, each user
would have to spend one minute doing something of *my* choosing
(perhaps, something like sitting around with their eyes closed, thinking
"this is great software, this is great software,...") Now I'm preventing
them from doing something else that might be a little more "socially
responsible". How "socially responsible" is that?

Cheers,
Randy Hyde
Willem
2005-02-26 20:49:33 UTC
Permalink
Randall wrote:
) It is understood that we are talking about a *social* obligation here.

If (part of) the argument is about the very question if it's a _social_
responsibility or not, then it is most certainly *not* 'understood'.
This kind of thinking is a frequent cause of useless arguments.

) ...
)
) No, I don't misunderstand him at all. It is a *social* obligation.

Repeating your arguments to me is unneccesary.
I am merely pointing out that you do seem to be misunderstanding his points.
The very first sentence of yours I quoted above demonstrates that perfectly.


I'll try to paraphrase (if that's the correct word) his point:

If it is your job to write a browser for end users, then the
responsibility to make it run efficiently stems from it being your *job*.
'Social' responsibility never enters into the picture.


From this, it seems clear to me that any arguing about responsibility
in general seems completely besides the point.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randall Hyde
2005-02-26 21:05:59 UTC
Permalink
Post by Willem
From this, it seems clear to me that any arguing about responsibility
in general seems completely besides the point.
Then why are you responding? :-)
Cheers,
Randy Hyde
Willem
2005-02-26 22:01:43 UTC
Permalink
Randall wrote:
) Then why are you responding? :-)

You obviously haven't taken the trouble to read what I wrote.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Robert Redelmeier
2005-02-26 21:44:24 UTC
Permalink
Post by Willem
If it is your job to write a browser for end users, then the
responsibility to make it run efficiently stems from it being your
*job*. 'Social' responsibility never enters into the picture.
As the poster who brought up "social responsibility", permit
me to belatedly explain what I mean by the term. "Social"
means pertaining to society, as distinct from ethic, moral,
family, employment, religious, legal, etc, responsibilities.

A programmer has a social responsibility to make heavily used
software fast, irrespective of the wishes of his employer.
A software project manager may well want to ship slow software
to meet some deadline. What other grounds does the pgmr have
to object? Not that the pgmr always can or should prevail.
You could also call this a professional responsibility,
but most professional responsibilities are social too.

-- Robert
Willem
2005-02-26 21:58:34 UTC
Permalink
Robert wrote:
) A programmer has a social responsibility to make heavily used
) software fast, irrespective of the wishes of his employer.
) A software project manager may well want to ship slow software
) to meet some deadline. What other grounds does the pgmr have
) to object? Not that the pgmr always can or should prevail.

'You'll have to delay the deadline by a month, so I can make it run
2% faster. After all, it will be used by billions of people everyday.'

I find that somewhat absurd. At the very least you also have a
responsibility to make your software available within a reasonable time.
I, for one, would not want to wait two months for a browser just so that
it will run a few percent faster.

Also, it seems like you think it's the programmers job to always delay
the deadline, and the managers job to always enforce the deadline.

In any case, deadlines exist for a reason, meaning you have a certain
amount of time to work on a piece of software you have to deliver.
It's your responsibility to decide on which task you spend your time.
Choices usually include trying to find and fix bugs, adding features,
and streamlining code to make it more efficient.

One could find it irresponsible to choose the streamlining.


As an aside: any 'speed improvement' that makes the code more obscure
and therefore less maintainable is in my opinion a very bad thing.


Anyway, I only jumped into this argument just now, these are my opinions.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randall Hyde
2005-02-27 00:12:31 UTC
Permalink
Post by Willem
'You'll have to delay the deadline by a month, so I can make it run
2% faster. After all, it will be used by billions of people everyday.'
I find that somewhat absurd.
Yes, the comment that it will be used by billions of people everyday
is unsupportable :-)
Post by Willem
At the very least you also have a
responsibility to make your software available within a reasonable time.
I, for one, would not want to wait two months for a browser just so that
it will run a few percent faster.
The issue isn't performance, per se, it is the total amount of wasted
end-user
time that results from the programmer's decisions about performance that
is the issue.

If two month's of work wouldn't save a significant amount of end-user
time, it clearly isn't worth the effort. However, also note that if you
get to the point where the program is completed except for "two months
of work to make it run faster)," then the programmer has already failed
in their responsibility not to waste time. As any decent software engineer
knows, trying to hack on performance after the fact, rather than designing
it in from the beginning, is rarely successful.

And if the programmer *has* done this from the beginning, and at
the point the product is ready to ship, the programmer could only
get a couple percentage boost in performance by spending a couple
of months work on the project, one could easily argue that this
programmer *has* fulfilled their social responsibility to produce
fast code. After all, if they can only gain a slight improvement,
then they probably wrote pretty good code to begin with.

The social responsibility works in the other direction, too.
Programmers should *not* waste considerable time attempting
to optimize code that doesn't waste the end-user's time.
After all, that (programming) effort could be put to better use
improving other software that *does* waste the end-user's
time.
Post by Willem
Also, it seems like you think it's the programmers job to always delay
the deadline, and the managers job to always enforce the deadline.
As you are responding to Robert, I can't really comment on what
he was thinking or not thinking. But it sure appears to me that
his claims had to do with the personal responsiblity of the
programmer and had nothing to do with management.
Post by Willem
In any case, deadlines exist for a reason, meaning you have a certain
amount of time to work on a piece of software you have to deliver.
And often, those deadlines are set by estimates given by the
programmer. Why is it that performance is the first thing people
will sacrifice when projects are late? (In reality, features are probably
the first thing that should get reduced to meet an unreasonable
deadline).
Post by Willem
It's your responsibility to decide on which task you spend your time.
Better yet, it's your responsibility to ensure that sufficient time is
allocated to do the job right.
Post by Willem
Choices usually include trying to find and fix bugs, adding features,
and streamlining code to make it more efficient.
While it's clear that correcting bugs should have the highest priority,
why would "more features" take precedence over "more efficient?"

Programmers have a responsibility to do all these things.
The presence of deadlines, economic considerations, and
so on, does not diminish their social responsibility to reduce
the amount of time wasted by the end users because of poor
choices on the programmer's part. These may be *excuses*
why the programmer didn't live up to their social responsibility,
it doesn't free them from that responsibility.
Post by Willem
One could find it irresponsible to choose the streamlining.
Over adding features? Hardly. Adding features is the
first thing to nix when a project is behind. Try reading
a few books on software engineering and see what they
have to say about this. Few books suggest writing "quick
and dirty" code that is inefficient. This is hardly a good
solution as most of the time you have to go back and
rewrite such code.
Post by Willem
As an aside: any 'speed improvement' that makes the code more obscure
and therefore less maintainable is in my opinion a very bad thing.
You are confusing "optimizing at a low level" with writing efficient
code to begin with. The problem with browsers, and most large
software projects, is not that the programmers didn't spend time
at the *end* of the project moving machine instructions around to
keep the pipelines full, the problem is that they began the project
with an attitude of "Moore's Law will take care of performance
requirements for me" or didn't even think about the performance
of their product during the design phase. Of course, with deadlines
looming they starting using linear searches instead of binary or
hash searches, and other "simple to implement but inefficient"
algorithms. No amount of "counting cycles" is going to fix
that problem. And the bottom line is this -- if a programmer
doesn't worry about the performance of their product from
day one, the probability is almost one that they will produce
code that runs *much* slower than it has to run.

One advantage of using assembly language is that you can
sometimes get away with such sloppiness. As projects get
larger, however, such sloppiness catches up with you.
Post by Willem
Anyway, I only jumped into this argument just now, these are my opinions.
Cheers,
Randy Hyde
Willem
2005-02-27 01:24:20 UTC
Permalink
Randall wrote:
) While it's clear that correcting bugs should have the highest priority,
) why would "more features" take precedence over "more efficient?"

I wouldn't know. It could go either way, I guess.

As an aside, all the comments you make for thinking of efficiency from the
beginning are equally applicable to 'more features' and 'correcting bugs'.
That is: both are easier to do when you calculate for them from the start.
Random examples include modular design (for adding features) and internal
checking (for finding bugs).

) Programmers have a responsibility to do all these things.
) The presence of deadlines, economic considerations, and
) so on, does not diminish their social responsibility to reduce
) the amount of time wasted by the end users because of poor
) choices on the programmer's part. These may be *excuses*
) why the programmer didn't live up to their social responsibility,
) it doesn't free them from that responsibility.

So basically you're saying that programmers have a social
responsibility to make smart choices ? Sounds like a no-brainer.
But you're also saying that the best choice always makes a piece of
software more efficient ? Often there's a tradeoff between efficiency
and other requirements. For example, one of the first choices is which
language to write in. Java usually isn't the most efficient language,
and still people choose to use it.

)> One could find it irresponsible to choose the streamlining.
)
) Over adding features? Hardly. Adding features is the
) first thing to nix when a project is behind. Try reading
) a few books on software engineering and see what they
) have to say about this. Few books suggest writing "quick
) and dirty" code that is inefficient. This is hardly a good
) solution as most of the time you have to go back and
) rewrite such code.

Who said that 'adding features' implies 'quick and dirty' code ?
If I've created a piece of software that is designed in such a way that
features can be added easily and robustly, I see no reason not to, and
I could imagine situations where adding features is the best choice.

) You are confusing "optimizing at a low level" with writing efficient
) code to begin with.

Not at all. Often there's a choice between two algorithms, one being the
more efficient, and the other being the more clear and maintainable.
I think you should take the more maintainable choice, unless the difference
is in big-oh time complexity.

) ..., the problem is that they began the project
) with an attitude of "Moore's Law will take care of performance
) requirements for me" or didn't even think about the performance
) of their product during the design phase. ...

I used to think programmers like that didn't exist.
But I was young back then....


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randall Hyde
2005-02-27 02:04:26 UTC
Permalink
Post by Willem
) While it's clear that correcting bugs should have the highest priority,
) why would "more features" take precedence over "more efficient?"
I wouldn't know. It could go either way, I guess.
As an aside, all the comments you make for thinking of efficiency from the
beginning are equally applicable to 'more features' and 'correcting bugs'.
That is: both are easier to do when you calculate for them from the start.
Random examples include modular design (for adding features) and internal
checking (for finding bugs).
Of course. I'm not advocating spending months on end at the
end of the product development cycle to optimize code that
was written crappy to begin with. I'm advocating that people
*consider* efficiency throughout the design and implementation.
If you go back and read my earlier posts in this thread, you'll
note that I stated that the problem is "too many programmers
assume Moore's Law will cover their performance requirements."
(That is, by the time the software appears, CPUs will have
increased in speed to cover the programmer's indiscretions.)
Alas, programmers who think this way simply don't write
efficient code and the result is not going to be good; even if
if they attempt to hack it up after the fact (i.e., they also use
the 80/20 rule to avoid writing efficient code in the first place).

Bottom line is that if they keep an eye on how they write their
code from day way, it won't have a *big* impact on the schedules,
features, and so on when you consider the product's life cycle.
Yes, writing good code often takes longer, initially, than
"quick and dirty" code. But we all know what happens in the
long run when a programmer heads down the "quick and dirty"
path.
Post by Willem
So basically you're saying that programmers have a social
responsibility to make smart choices ? Sounds like a no-brainer.
I sure thought so.
Post by Willem
But you're also saying that the best choice always makes a piece of
software more efficient ?
No. Efficiency isn't the primary concern with respect to social obligations.
Wasting end-user's time is the important criterion here.
If you can write inefficient code that *doesn't* waste the end-user's
time, then you have no social obligation to make that code any more
efficient.
Post by Willem
Often there's a tradeoff between efficiency
and other requirements. For example, one of the first choices is which
language to write in. Java usually isn't the most efficient language,
and still people choose to use it.
I won't even touch that one :-)
Post by Willem
Who said that 'adding features' implies 'quick and dirty' code ?
If I've created a piece of software that is designed in such a way that
features can be added easily and robustly, I see no reason not to, and
I could imagine situations where adding features is the best choice.
Read those software engineering books...
Gold plating is the number one problem with schedules.
Programmers think that they can "add features easily and robustly."
In practice, this rarely turns out to be true (e.g., try removing a
feature from a product at some point after that feature has been
released; good example, listen to the MASM32 crowd complain
about the fact that Microsoft wants to drop the INVOKE statement
from the 64-bit version of MASM).
Post by Willem
Not at all. Often there's a choice between two algorithms, one being the
more efficient, and the other being the more clear and maintainable.
I think you should take the more maintainable choice, unless the difference
is in big-oh time complexity.
O(x) complexity is irrelevant.
Again, the important issue for our discussion is whether you're wasting
your end user's time. If you are, and a different algorithm (even more
complex and slightly less maintainable) make the program *twice* as
fast (same big-Oh), it's probably worth it. Conversely, if you're not
wasting your end-users time at all, changing from O(n^2) to O(n) isn't
worth the effort to make the change to your code.

Cheers,
Randy Hyde
Randy Howard
2005-02-27 02:41:06 UTC
Permalink
Post by Randall Hyde
O(x) complexity is irrelevant.
Based upon your previous posts, I found this pretty surprising.
Post by Randall Hyde
Again, the important issue for our discussion is whether you're
wasting your end user's time.
If n is sufficiently large, the O(n) complexity obviously matters.
Post by Randall Hyde
If you are, and a different algorithm (even more complex and
slightly less maintainable) make the program *twice* as fast
(same big-Oh), it's probably worth it.
That's a pretty nasty constant, but ok. Anytime you can cut the
time in half, you're on the right track, provided you don't
introduce new bugs, or negatively impact portability (provided
that portability is a product requirement).

Microsoft's memcmp() implementation is so bad on large memory
blocks that I've been replacing it with one of my own for
years, and that's usually only good for about 40% best case,
and that depends greatly upon how often you use it. In data
integrity stress test software, it gets worked pretty hard.
In a typical application, nobody ever knows.
Post by Randall Hyde
Conversely, if you're not wasting your end-users time at
all, changing from O(n^2) to O(n) isn't worth the effort to
make the change to your code.
Depends again upon what the upper limit on n can be. Just
because they aren't hitting it today with their 1MB of
data doesn't mean that 3 years from now they won't be
ripping their hair out.


P.S.

BTW, if we really wanted to stop wasting end-users time,
we'd turn off all the eye candy in the GUI. :-)
--
Randy Howard (2reply remove FOOBAR)
There once was a mudpuppy from Hoover,
(in Alabama, not in Vancouver).
He found an old Rhesus
Who said "Parthenogenesis
Requires no copulating maneuver."
-- Thus spake the Oracle
Randall Hyde
2005-02-27 07:18:16 UTC
Permalink
Post by Randy Howard
Post by Randall Hyde
O(x) complexity is irrelevant.
Based upon your previous posts, I found this pretty surprising.
Post by Randall Hyde
Again, the important issue for our discussion is whether you're
wasting your end user's time.
If n is sufficiently large, the O(n) complexity obviously matters.
You missed the whole point.
When people use asymptotic performance predictions as an
excuse to not bother with optimization, the battle is already lost.
The bottom line is that, except for a few well-known algorithms,
it generally isn't *possible* to substitute an algorithm with better
asymptotic complexity for the ones found in typical programs.
For example, where's the O(n) or O( n lgn ) algorithm that's
going to make the browser run so much faster? In most real
world applications, such algorithms don't exist. Therefore, the
constant is all you've got to play with.
Post by Randy Howard
Post by Randall Hyde
If you are, and a different algorithm (even more complex and
slightly less maintainable) make the program *twice* as fast
(same big-Oh), it's probably worth it.
That's a pretty nasty constant, but ok.
Around this particular newsgroup, it's pretty easy to find
constants like 5x and 10x. Doesn't happen all the time, mind
you, but it does happen. Coming up with a factor of two isn't
all that difficult to do.
Post by Randy Howard
Anytime you can cut the
time in half, you're on the right track, provided you don't
introduce new bugs, or negatively impact portability (provided
that portability is a product requirement).
Keep in mind, the point isn't to "cut the time in half." Rather,
the point is *not* to write the code in such a manner that it
runs at *half* the speed it ought to. If you're worrying about
speeding up your code to make it run twice as fast, you've
already lost the battle.
Post by Randy Howard
Microsoft's memcmp() implementation is so bad on large memory
blocks that I've been replacing it with one of my own for
years, and that's usually only good for about 40% best case,
and that depends greatly upon how often you use it. In data
integrity stress test software, it gets worked pretty hard.
In a typical application, nobody ever knows.
You've made one of the classic mistakes of optimization metrics:
measuring a single function's performance. Attempting to improve
the performance of a system by speeding up the individual functions
is rarely successful. Or, at least, you don't get *that* much of a boost.
This is the main reason you hear so many people claiming that their
software just can't be sped up -- they've tried to speed up their
software after the fact and typically got a 10-25% boost, and
automatically assumed that they were writing good code all along
(and optimization just wasn't worth the effort). It's the same argument
people use in the good old "assembly vs. HLL" religous wars.

The problem, however, is that good performance is not achieved
at a microscopic level. It's obtained at the macroscopic level.
You get good performance by writing an entire *system* with
an eye to providing good performance, not by trying to hack in
the performance later on. This is why assembly programmers
tend to produce faster code than HLL compilers -- because they
write the entire app in assembly, thinking in assembly. If you write
the code in a HLL and "hand compile" each HLL function into
assembly after the fact, I'd be surprised to find that your code
ran any faster at all than that produced by the HLL. The trick
to writing fast code is to "grok" the whole project and design it
to be efficient from the very beginning.
Post by Randy Howard
Post by Randall Hyde
Conversely, if you're not wasting your end-users time at
all, changing from O(n^2) to O(n) isn't worth the effort to
make the change to your code.
Depends again upon what the upper limit on n can be. Just
because they aren't hitting it today with their 1MB of
data doesn't mean that 3 years from now they won't be
ripping their hair out.
Unless, of course, there is no better algorithm (in an
asymptotic case). People throw this concept around
like you can take out one algorithm and easily replace
it with a faster one when necessary. In practice, most
programs are already operating at O(n) (or even O(1))
and they are still too slow.
Post by Randy Howard
BTW, if we really wanted to stop wasting end-users time,
we'd turn off all the eye candy in the GUI. :-)
And we'd turn off all the virus protection, spam blocking,
and other modern tools that eat so much of the CPU's
resourcs.
Cheers,
Randy Hyde
unknown
2005-02-27 09:49:36 UTC
Permalink
PÃ¥ Sun, 27 Feb 2005 07:18:16 GMT, skrev Randall Hyde
Post by Randall Hyde
The trick
to writing fast code is to "grok" the whole project and design it
to be efficient from the very beginning.
Same as Betov sais......and DOES !
Post by Randall Hyde
Cheers,
Randy Hyde
--
http://TheWannabee.org
Willem
2005-02-27 11:10:21 UTC
Permalink
Randall wrote:
) "Randy Howard" <***@FOOverizonBAR.net> wrote in message
) news:***@news.verizon.net...
)> If n is sufficiently large, the O(n) complexity obviously matters.
)
) You missed the whole point.
) When people use asymptotic performance predictions as an
) excuse to not bother with optimization, the battle is already lost.

You never made that point. You only stated that big-oh complexity
didn't matter. And I never stated anything even remotely like that
you should use big-oh predictions as an excuse, so I don't know where
you got that from.

) The bottom line is that, except for a few well-known algorithms,
) it generally isn't *possible* to substitute an algorithm with better
) asymptotic complexity for the ones found in typical programs.

Not if the algorithms were carefully chosen in the first place.
But you're talking about programmers who are 'sloppy', and I see
no argument why they would not be sloppy in the big-Oh sense.

And even worse: algorithms with a worse big-oh time complexity tend to be
much faster! on a smaller scale. So it could even be that not looking at
big-oh, but looking at speed as such, a programmer could choose the worse
time complexity because he expects the datasets to remain small.

) For example, where's the O(n) or O( n lgn ) algorithm that's
) going to make the browser run so much faster?

You may have seen my example about keeping a sorted list of
directory contents. This is an actual real-world example.
Or, much more prevalent, the choice of datatypes for search lists,
such as hashing, search trees, skip lists, etcetera. Most programmers
will decide what datatype to use based on what they're most familiar with.

) In most real world applications, such algorithms don't exist. Therefore,
) the constant is all you've got to play with.

This is an unfounded assertion, and thinking like this is what brought
the world all those pieces of software that don't scale well.
Why do you think the MS registry is sooo fucking slow ?
Because of a constant factor, or because of big-oh problems ?

) Around this particular newsgroup, it's pretty easy to find
) constants like 5x and 10x. Doesn't happen all the time, mind
) you, but it does happen. Coming up with a factor of two isn't
) all that difficult to do.

Around this newsgroup, you equally easily find factors like lgn as well.
Especially in the datatype department.

) Unless, of course, there is no better algorithm (in an
) asymptotic case). People throw this concept around
) like you can take out one algorithm and easily replace
) it with a faster one when necessary. In practice, most
) programs are already operating at O(n) (or even O(1))
) and they are still too slow.

In practice, there are a lot of programs floating around that use
sub-optimal datatypes and algorithms, in the big-oh sense.
You seem to be assuming that programmers *do* know the optimal algorithms
in the big-oh sense, but *don't* know how to implement them efficiently.
This seems like an odd discrepancy in your thinking.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Willem
2005-02-27 02:52:46 UTC
Permalink
Randall wrote:
) O(x) complexity is irrelevant.
) Again, the important issue for our discussion is whether you're wasting
) your end user's time. If you are, and a different algorithm (even more
) complex and slightly less maintainable) make the program *twice* as
) fast (same big-Oh), it's probably worth it. Conversely, if you're not
) wasting your end-users time at all, changing from O(n^2) to O(n) isn't
) worth the effort to make the change to your code.

I disagree with you here.

A few points:

A mere two-fold increase in speed *will* be covered by Moore's Law.
But contrary to that, big-Oh complexity will *never* be covered by
Moore's Law.

A lot of times, the reason people write inefficient code is precisely
because they don't think they will be wasting end-users time with it.

And the big point:

Big-Oh complexity is what makes the big speed difference between test runs
and actual usage by end-users. Constant speedups are the thing that show
in benchmarks and tests, and thus are the things that programmers tend to
focus on when it turns out somethig is too slow during testing.
However, not looking at big-Oh complexity is usually what makes software
run extremely slow in real life conditions.

As an example, suppose someone uses a braindead sort algorithm for a
directory listing in a file manager. During testing, it seems a bit slow,
but some tweaking of the algorithm makes it run twice as fast and even with
hundreds of files it runs blindingly fast. The code makes it out to a real
user who has thousands of files in his directory, and lo and behold, it
slows to a crawl.


So my point would be: big-Oh complexity is a very good measure of what will
and will not impact the end-users waste of time.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Gerry Quinn
2005-02-27 11:29:42 UTC
Permalink
In article <***@toad.stack.nl>, ***@stack.nl
says...
Post by Willem
Big-Oh complexity is what makes the big speed difference between test runs
and actual usage by end-users. Constant speedups are the thing that show
in benchmarks and tests, and thus are the things that programmers tend to
focus on when it turns out somethig is too slow during testing.
However, not looking at big-Oh complexity is usually what makes software
run extremely slow in real life conditions.
As an example, suppose someone uses a braindead sort algorithm for a
directory listing in a file manager. During testing, it seems a bit slow,
but some tweaking of the algorithm makes it run twice as fast and even with
hundreds of files it runs blindingly fast. The code makes it out to a real
user who has thousands of files in his directory, and lo and behold, it
slows to a crawl.
So my point would be: big-Oh complexity is a very good measure of what will
and will not impact the end-users waste of time.
In your example of a directory listing, for a particular user.

I don't see why it should be of general application.

- Gerry Quinn
Willem
2005-02-27 11:45:11 UTC
Permalink
Gerry wrote:
) In article <***@toad.stack.nl>, ***@stack.nl
) says...
)> So my point would be: big-Oh complexity is a very good measure of what
)> will and will not impact the end-users waste of time.
)
) In your example of a directory listing, for a particular user.
)
) I don't see why it should be of general application.

Because end-user applications tend to have larger datasets than
testbed applications.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randy Howard
2005-02-27 02:33:42 UTC
Permalink
In article <***@toad.stack.nl>, ***@stack.nl
says...
Post by Willem
) ..., the problem is that they began the project
) with an attitude of "Moore's Law will take care of performance
) requirements for me" or didn't even think about the performance
) of their product during the design phase. ...
I used to think programmers like that didn't exist.
But I was young back then....
I can't find the link now, but there used to be a mpeg movie on
the web somewhere showing a Microsoft research "expert" giving a
talk to a bunch of Stanford grad students. His argument was
explicitly that Moore's law would take care of it. In fact, he
said "go on vacation for 6 months, come back, buy a new computer,
and your problem will be solved."

The students seemed to love the idea. What a shock.

Maybe somebody can remember the link, I saw it on usenet originally.
--
Randy Howard (2reply remove FOOBAR)
"Making it hard to do stupid things often makes it hard
to do smart ones too." -- Andrew Koenig
Robert Redelmeier
2005-02-27 07:43:18 UTC
Permalink
Post by Willem
) A programmer has a social responsibility to make heavily used
) software fast, irrespective of the wishes of his employer.
) A software project manager may well want to ship slow software
) to meet some deadline. What other grounds does the pgmr have
) to object? Not that the pgmr always can or should prevail.
'You'll have to delay the deadline by a month, so I can make it run
2% faster. After all, it will be used by billions of people everyday.'
I find that somewhat absurd.
Did you not read or understand my sentence "Not that the pgmr
always can or should prevail"??? That could cover the 2% case.

What social or professional responsibility does in enable
the issue to get rationally discussed, rather than dismissed
by fiat. 2% may or may not be worth a month. That will have
to be resolved in the way flexible people resolve conflicting
demands. Push comes to shove, the project will probably be
delayed by one+ month if someone else does the work.

-- Robert
Robert Redelmeier
2005-02-20 00:21:23 UTC
Permalink
Post by Programmer Dude
Wrong emphasis, I think. If there is any moral or social
obligation, it's for the worker to do the work--what ever
it is--in a way that is moral or socially responsible.
Yes, and the morality of that work is entirely up to the
worker to decide. The responsibility is to do it well.
Post by Programmer Dude
We have established that "I was paid" or "I was ordered"
is not an acceptable defense for an immoral or irresponsible
act. The employee has a moral/social obligation regardless
of pay or orders.
Precisely. The doer is responsible, not the tool-maker unless
the toolmaker has cause to believe the tool will be misused.
Post by Programmer Dude
History may well look back on the faster, Faster, FASTER
lifestyle of this age as a terrible mistake morally equal
to, say, slavery.
It might, but I doubt it. In the meantime, since speed is
apparently a good thing, those who can provide it have a
certain responsibility to do so.
Post by Programmer Dude
Thus it is one thing to say, "My customer has asked for a
faster browser, and my obligation is to meet the request,"
and another to suggest that faster browsers are a social
responsibility.
No, I didn't say faster browsers are an obligation, just a
responsibility of those who program them. A person should know
the greater effects of his labors. Responsibility spreads wide,
including to those who schedule traincars into concentration camps.
Similarly, a good programmer knows how his pgm will affect the lives
of his users. He has a social responsibility not to waste their
time. This may be in conflict with his obligations to employers &
clients, but resolving conflicting requirements is part of life.
Post by Programmer Dude
You don't think that influencing people with regard to
the dangers of AIDS, hard drugs and teen pregnancy is a
social responsibility?
Depends on to whom. For my kids, my obligations are much
stronger than for others. I think my social responsibility
towards most adults is to present my data & views as
appropriate. Not to stand on some street-corner shouting.
Post by Programmer Dude
But if it's true that a faster browser is a social
responsibility, then I *ought* to be working on one.
No, social responsibilities are situational. If you are
writing a browser, particularly working on MS-IE, I'd say
you have that responsibility. If not, not. You could write
as fast a browser as you please, it is unlikely to be used on
the scale of MS-IE and therefore not much social help.

-- Robert
Programmer Dude
2005-02-25 00:37:23 UTC
Permalink
Post by Robert Redelmeier
Post by Programmer Dude
History may well look back on the faster, Faster, FASTER
lifestyle of this age as a terrible mistake morally equal
to, say, slavery.
It might, but I doubt it.
This thread has caused me to think more about this, and the more
I do, the more I think there's a good chance history will look
back on this age as an awkward transition to a fully technological
age.
Post by Robert Redelmeier
In the meantime, since speed is apparently a good thing, those
who can provide it have a certain responsibility to do so.
As a general statement, I can't agree. There's too many places
where speed is clearly a bad thing: enjoying a cigar, a good meal
or good sex, to name just three. AIUI, Wall Street has software
"governers" in place to slow down computerized transactions--
the fast pace turns out to destabilize the market.

So, no, I don't at all agree speed--in general--is good.
Post by Robert Redelmeier
Post by Programmer Dude
Thus it is one thing to say, "My customer has asked for a
faster browser, and my obligation is to meet the request,"
and another to suggest that faster browsers are a social
responsibility.
No, I didn't say faster browsers are an obligation, just a
responsibility of those who program them.
I still feel that's not the best way to say it. If your job is
to program a browser, ALL aspects of that task should be your
absolute responsibility. Speed would be just a part of that.
Post by Robert Redelmeier
A person should know the greater effects of his labors.
I agree completely!
Post by Robert Redelmeier
Similarly, a good programmer knows how his pgm will affect the lives
of his users. He has a social responsibility not to waste their
time. This may be in conflict with his obligations to employers &
clients, but resolving conflicting requirements is part of life.
Agreed again.
Post by Robert Redelmeier
Post by Programmer Dude
You don't think that influencing people with regard to
the dangers of AIDS, hard drugs and teen pregnancy is a
social responsibility?
Depends on to whom. For my kids, my obligations are much
stronger than for others. I think my social responsibility
towards most adults is to present my data & views as
appropriate. Not to stand on some street-corner shouting.
Unless, maybe, the sky were falling or the Vogons had shown up.
:-)
Robert Redelmeier
2005-02-25 04:04:05 UTC
Permalink
Post by Programmer Dude
This thread has caused me to think more about this, and the
more I do, the more I think there's a good chance history
will look back on this age as an awkward transition to a
fully technological age.
Of course it is. All transitions are perforce awkward.
But are not improved by repression. In middle and old age,
more people regret not being more adventurous in their
youth than vice-versa.
Post by Programmer Dude
As a general statement, I can't agree. There's too many
places where speed is clearly a bad thing: enjoying a
cigar, a good meal or good sex, to name just three. AIUI,
Certainly, but those activities are enjoyable, while
waiting for a window to paint is not.
Post by Programmer Dude
Wall Street has software "governers" in place to slow down
computerized transactions-- the fast pace turns out to
destabilize the market.
Of course. Cuts oscillation. The justification for
"integral control" on industrial systems.
Post by Programmer Dude
I still feel that's not the best way to say it. If your
job is to program a browser, ALL aspects of that task
should be your absolute responsibility. Speed would be
just a part of that.
Certainly. But why you look at the global impact of
your work, speed may be a bigger part for the aggregate
of your customers than it is for your employer.

-- Robert
Programmer Dude
2005-02-25 18:32:34 UTC
Permalink
Post by Robert Redelmeier
Post by Programmer Dude
I still feel that's not the best way to say it. If your
job is to program a browser, ALL aspects of that task
should be your absolute responsibility. Speed would be
just a part of that.
Certainly. But why you look at the global impact of
your work, speed may be a bigger part for the aggregate
of your customers than it is for your employer.
Agreed.

And delivering that would be a Good Thing. I just don't
agree it's a social responsibility (moreso than anything
else would be).
"-\\\\o//-annabee" @
2005-02-20 02:02:20 UTC
Permalink
PÃ¥ Fri, 18 Feb 2005 19:05:59 -0600, skrev Programmer Dude
Post by Programmer Dude
History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.
History.... Theres allready written books taking up this issue. Its an
important issue. Or not. Lets say rather, its an interessting issue. In
norwegina, this antropologist have written a book that is called "The
tyranny of the moment" (freely translated) or in norwegina : "Øyeblikkets
tyranni", by Thomas Hylland Eriksen.

http://folk.uio.no/geirthe/Tyranni.html

English : http://folk.uio.no/geirthe/Books.html#TM

"
Subtitled "Rask og langsom tid i informasjonsalderen" ("Fast and slow time
in the information age"), I wrote this book partly to address a crisis in
my own working life -- the difficulty of getting anything done slowly and
continuously -- partly as an analysis of the effects of new information
technology on the way in which we live in time.
"

Actually I havent read it. Still this guy is a _VERY_ interessing person,
a star of his field and very intelligent.
--
http://TheWannabee.org
Programmer Dude
2005-02-22 23:42:55 UTC
Permalink
Post by "-\\\\o//-annabee" @
Post by Programmer Dude
History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.
History.... Theres allready written books taking up this issue.
Aren't they called ... history books? :-) (Sorry, couldn't resist!)
Post by "-\\\\o//-annabee" @
http://folk.uio.no/geirthe/Tyranni.html
English : http://folk.uio.no/geirthe/Books.html#TM
"
Subtitled "Rask og langsom tid i informasjonsalderen" ("Fast and slow time
in the information age"), I wrote this book partly to address a crisis in
my own working life -- the difficulty of getting anything done slowly and
continuously -- partly as an analysis of the effects of new information
technology on the way in which we live in time.
"
Actually I havent read it. Still this guy is a _VERY_ interessing person,
a star of his field and very intelligent.
Interesting, thanks! I have a strong sense in my gut that history *will*
look back on the fast pace of this age with something akin to horror.

We're still kind of in the "gee whiz" stage with technology. I doubt I'll
live long enough to see it become old hat and for us to re-evaluate our
relationship to it, but I strongly believe that day will come and that we
will recognize the value of slowing down.

(This is one reason I enjoy a good cigar now and again. A cigar takes
a good hour+ to smoke and it forces you to stop and relax for a while.)
"-\\\\o//-annabee" @
2005-02-23 04:24:51 UTC
Permalink
PÃ¥ Tue, 22 Feb 2005 17:42:55 -0600, skrev Programmer Dude
Post by Programmer Dude
Post by "-\\\\o//-annabee" @
Post by Programmer Dude
History may well look back on the faster, Faster,
FASTER lifestyle of this age as a terrible mistake morally equal to,
say, slavery.
History.... Theres allready written books taking up this issue.
Aren't they called ... history books? :-) (Sorry, couldn't resist!)
Post by "-\\\\o//-annabee" @
http://folk.uio.no/geirthe/Tyranni.html
English : http://folk.uio.no/geirthe/Books.html#TM
"
Subtitled "Rask og langsom tid i informasjonsalderen" ("Fast and slow time
in the information age"), I wrote this book partly to address a crisis in
my own working life -- the difficulty of getting anything done slowly and
continuously -- partly as an analysis of the effects of new information
technology on the way in which we live in time.
"
Actually I havent read it. Still this guy is a _VERY_ interessing person,
a star of his field and very intelligent.
Interesting, thanks! I have a strong sense in my gut that history *will*
look back on the fast pace of this age with something akin to horror.
The lotus grow out of the mud :)
Post by Programmer Dude
We're still kind of in the "gee whiz" stage with technology. I doubt
I'll live long enough to see it become old hat and for us to re-evaluate
our
relationship to it, but I strongly believe that day will come and that we
will recognize the value of slowing down.
Yes. This is already happening. You can only bend over this much, until
you break. Hopefully. The real danger today, is that religions gets a
foothold again, because of a misinterpretation of what our "values" mean.
Dont know if you understand what I am saying, but if our commersialism
fails (allready has), the danger is that we go back to idealistic values,
non.scientific crap ideas.

What is needed for people to accept to live with : Insecurity, facts,
Diversity, death, forgiveness, and to see that what one man does, reflects
on the sosiety, and that punishing or judge the man, is not to understand
and learn anything, but to showel it under a carpet.

In fact, I dont think we need to "do" anything. (Stay with me) The world
will evolve or develop on its own term nomatter what we do individually.
Theres nothing to fear. I think we are all very much clouded, by
projecting out fear of our own death onto other people and the sosiety.
But nomatter how resonable one solution is over another, theres no way to
guarantie that it will be chooosen. And in the end, theres nothing to fear
anyhow, nomatter what we do personally, as long as we act to the best of
our personal ability, which most people do. And THEN, facing that what we
do is simply windwaving, to still do what is right. And what is right, is
maybe exactly what we do, because in fact, we cannot do anything, but what
we do.....because that would defeat reality. Reality is because of
physical laws. Not because of something someone wants, or sees as a better
way. Its like running. If you run long enough you will wear out and get
tired, nomatter what you want. In the same way, the way the youth are, is
a reflection of chooses by the parents. And the choices of a person
reflects his beeing. And the state of his beeing is the result of his many
past actions. Theres no way to remove all his past choises. His next
choise will rise out of his past choises. When he suddenly makes a
diffrent choise, this is BECAUSE of his past choises, not because of his
current dessision only. The current desssion comes to him, because his
past choises.

Thats why the lotus comes from the mud, and how the Sorba become a budda.
:)))))

If you think the above was incoherent, this is by design. There simply are
no truths. They are for each of us to find, and one for each...
Post by Programmer Dude
(This is one reason I enjoy a good cigar now and again. A cigar takes
a good hour+ to smoke and it forces you to stop and relax for a while.)
Yes. And I am sure that you had to experience NOT STOPPING for a while, to
appreciate it ? But if you stopp for 2 years, like I did, then you may
also be bored from that. We are humans. and we change. We experience, and
_thats_ our purpose. To experience. Anything really, because joy comes
from relativity. You cant have one without the other. Where we fail is
when we try to make one of theese changes into a law.

"I need my pain". Captain (as it Kirk?)
--
"my life insists on standing still at a tremendous speed". - Freely after
Thomas Hylland Eriksen
http://TheWannabee.org
LGC
2005-02-23 14:30:30 UTC
Permalink
Post by "-\\\\o//-annabee" @
If you think the above was incoherent, this is by design. There simply are
no truths. They are for each of us to find, and one for each...
"There simply are no truths" - Then this statement is false!

"They are for each of us to find, and one for each" - There is only one
truth. Having contradictory 'truths' is illogical.

Psalm 25:10
John 14:6
Phlip
2005-02-23 14:43:38 UTC
Permalink
Post by LGC
Post by "-\\\\o//-annabee" @
If you think the above was incoherent, this is by design. There simply are
no truths. They are for each of us to find, and one for each...
"There simply are no truths" - Then this statement is false!
"They are for each of us to find, and one for each" - There is only one
truth. Having contradictory 'truths' is illogical.
Whether there are "truths" depends on what you put your truth to.
--
Phlip
http://industrialxp.org/community/bin/view/Main/TestFirstUserInterfaces
Gerry Quinn
2005-02-16 09:59:41 UTC
Permalink
In article <***@toad.stack.nl>, ***@stack.nl
says...
Post by Willem
There is the issue that learning ASM usually includes learning a number
of bad habits, that you have to break to be able to effectively program
in a suitably high level language. For example, it teaches you to think
sequentially, and to approach programming as a sequence of tasks that a
computer has to do one after another. For example, with a background in
iteratvie languages, functional languages tend to become more difficult
and often such people will try to force iterative programs. I did too.
But if you are going to develop habits more suited to one type of
language or another (after all, iterative thinking is a very good habit
if you are going to be writing algorithms in a C-like language)
shouldn't you develop ones that favour the more useful and popular
languages?

- Gerry Quinn
Willem
2005-02-16 10:44:39 UTC
Permalink
Gerry wrote:
) But if you are going to develop habits more suited to one type of
) language or another (after all, iterative thinking is a very good habit
) if you are going to be writing algorithms in a C-like language)
) shouldn't you develop ones that favour the more useful and popular
) languages?

No, because these languages are more useful and popular precisely
*because* people have these habits and methods of thinking.

(Popular is obvious, useful is because the usefulness of a language is
partly measured by how easy it is to make programs with it.)

An objective comparison of languages would require a whole sleet of
testing, involving people who don't know programming at all, teaching
them different languages, and seeing which people become the most
productive.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Randall Hyde
2005-02-16 14:01:16 UTC
Permalink
Post by Willem
An objective comparison of languages would require a whole sleet of
testing, involving people who don't know programming at all, teaching
them different languages, and seeing which people become the most
productive.
Unfortunately, you need to master a couple of different languages
and programming paradigms before you can realistically do
a "language survey". Furthermore, you need to understand
the low-level machine architecture in order for such a
comparison to be valid. I'm not suggesting that one has
to learn architecture/machine organization first, but you
certainly can't do a comparison of languages until well
after you've mastered some other stuff (i.e., this is usually
a Jr. or Sr. level course).
Cheers,
Randy Hyde
Willem
2005-02-16 15:05:02 UTC
Permalink
Randall wrote:
)
) "Willem" <***@stack.nl> wrote in message
) news:***@toad.stack.nl...
)>
)> An objective comparison of languages would require a whole sleet of
)> testing, involving people who don't know programming at all, teaching
)> them different languages, and seeing which people become the most
)> productive.
)
) Unfortunately, you need to master a couple of different languages
) and programming paradigms before you can realistically do
) a "language survey". Furthermore, you need to understand
) the low-level machine architecture in order for such a
) comparison to be valid. I'm not suggesting that one has
) to learn architecture/machine organization first, but you
) certainly can't do a comparison of languages until well
) after you've mastered some other stuff (i.e., this is usually
) a Jr. or Sr. level course).

Why would the test subjects have to master different languages ?
In the case I described (which will hopefully never happen), you
take a new untrained person for each language and teach him just
that language and nothing more.
The one doing the survey uses other people as guinea-pigs, so to speak.


SaSW, Willem
--
Disclaimer: I am in no way responsible for any of the statements
made in the above text. For all I know I might be
drugged or something..
No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT
Jonathan Bartlett
2005-02-16 18:26:36 UTC
Permalink
Post by Willem
There is the issue that learning ASM usually includes learning a number
of bad habits, that you have to break to be able to effectively program
in a suitably high level language. For example, it teaches you to think
sequentially, and to approach programming as a sequence of tasks that a
computer has to do one after another. For example, with a background in
iteratvie languages, functional languages tend to become more difficult
and often such people will try to force iterative programs. I did too.
This is true. I had the same thing happen to me. However, unfortunately
many curriculums only use the iterative model of programming. For those
doing imperative, assembly is probably the best teacher of that method.
For those focusing on functional, HTDP may be a better way to start.

Jon
pH
2005-02-16 03:24:36 UTC
Permalink
On Tue, 15 Feb 2005 22:09:01 GMT, Robert Redelmeier <***@ev1.net.invalid>
wrote:

[...]
Post by Robert Redelmeier
I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.
OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.
But *do* note that no one mentioned transistors. I *was* actually going
to elaborate further and state that one would *not* have to delve into
transistors, resistors, capacitors, etc., but decided that "at the gate level"
should probably suffice, as that's one of the (cool) things about digital
electronics; you can design digital circuits from now 'till doom's day
and not know how to bias a transistor (and let's just assume, shall we,
that I'm not talking about operating at GHz speeds). Knowing how a NAND
gate's inputs affect its output... (has nothing to do with "teaching transistor
arrangements", whatever that is).

Jeff

http://www.jefftturner.com
Ian Woods
2005-02-16 07:04:08 UTC
Permalink
On Tue, 15 Feb 2005 22:24:36 -0500
Post by pH
[...]
Post by Robert Redelmeier
I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.
OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.
But *do* note that no one mentioned transistors. I *was* actually going
to elaborate further and state that one would *not* have to delve into
transistors, resistors, capacitors, etc., but decided that "at the gate level"
should probably suffice, as that's one of the (cool) things about digital
electronics; you can design digital circuits from now 'till doom's day
and not know how to bias a transistor (and let's just assume, shall we,
that I'm not talking about operating at GHz speeds). Knowing how a NAND
gate's inputs affect its output... (has nothing to do with "teaching transistor
arrangements", whatever that is).
Jeff
http://www.jefftturner.com
Personally, I think the diversion into logic gates is certainly educational but not really about computation per-se, just one very cheap method of doing it. Afterall, the only reason the machine on your desk is electronic rather than mechanical is merely that the electronic version gives you several orders of magnitude of speed at several orders of magnitude less cost (and space!)

Computation is what should be taught - and not Turings "lowest common denominator" but a more realistic axiomatic machine. Assembly language for relatively simple platforms (and the computer architecture gubbins that goes with it) approaches this.

Part of the problem though is that, at least when I took these kinds of courses, they focus on either technology which is too "evolved" (possibly, mutated!) from a simple axiomatic machine into a monstrosity in search of performance over simplicity and clarity... and touches on no others. Learning only one or two semesters worth of something as large as "x86 assembly language and computer architecture" is likely to form bad habits by encouraging the "all the world's an (insert platform here)" assumption.

I think that in order for a couple of semesters of an undergrad degree that at least two differently architected abstract computers should be used: different instructions, register sizes, different devices accessable. This way at least it should be clear that computers come in all kinds of different forms with an underlying axiomatic-machine theme.

Ian Woods
pH
2005-02-17 09:22:13 UTC
Permalink
Post by Ian Woods
On Tue, 15 Feb 2005 22:24:36 -0500
Post by pH
[...]
Post by Robert Redelmeier
I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.
OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.
But *do* note that no one mentioned transistors. I *was* actually going
to elaborate further and state that one would *not* have to delve into
transistors, resistors, capacitors, etc., but decided that "at the gate level"
should probably suffice, as that's one of the (cool) things about digital
electronics; you can design digital circuits from now 'till doom's day
and not know how to bias a transistor (and let's just assume, shall we,
that I'm not talking about operating at GHz speeds). Knowing how a NAND
gate's inputs affect its output... (has nothing to do with "teaching transistor
arrangements", whatever that is).
Jeff
http://www.jefftturner.com
Personally, I think the diversion into logic gates is certainly educational but not
really about computation per-se, just one very cheap method of doing it.
Actually, my point of view is one of... "understanding the roots of the
machine"... understanding and being comfortable with binary by starting
at the beginning.

Examining binary data at both ends of "a problem" is usually quite revealing,
in terms of "how the output (of a function) relates to the input", and I would
invite *any*one needing convincing to read (even) a couple chapters of
Hacker's Delight.

Jeff

http://www.jefftturner.com
Barb Knox
2005-02-16 13:05:09 UTC
Permalink
<unsnip>
Post by Robert Redelmeier
Post by Jim Clarke
* Quantum mechanics takes a good deal of preparation, and even then
you're only just starting to get ready for solid-state physics.
</unsnip>
Post by Robert Redelmeier
Post by Jim Clarke
Sarcasm aside, my point is that you have to choose *somewhere*
in a continuum of abstractions and levels; choosing to start at a
low level in programming means choosing to neglect something, and
part of what you're choosing to neglect is mathematical. Students
have considerable difficulty understanding how to abstract,
and perhaps we should start with that, and add implementation
details later.
I once tried teaching "abstraction" in the (errr) abstract, and it bombed.
IMO, a stubbornly concrete domain is necessary for teaching the value and
techniques of abstraction.
Post by Robert Redelmeier
First, you _do_ notice that ALA is on the group list, and
you ought to expect very strong opinions from this bunch.
The whole topic approaches a troll for ALA.
I think learning ASM first gives a very solid foundation upon
which to learn HLLs and other constructs. Especially with
the prdominance of x86. Everything eventually gests reduced
to machine code, and ASM is the closes human-readable form.
OTOH, teaching transistor arrangements is probably unnecessary
except to electrical engineers.
The difference between ASM & HLLs is nothing compared to the
chasm between quantum & Newtonian physics.
The analogy ASM:3GL :: QM:Newtonian breaks down because the structure of QM
seldom sticks its grubby paws into the macroscopic world (please, no flames
from quantum chemists...), but the structure of machine language shows up
all over the place in 3GLs: fixed-width 2's-complement integers, pointers,
arrays, records, the critical importance of exact sequence, etc. etc.

For a physics analogy, I'd pick ASM as being analogous to Newtonian
mechanics, since one very seldom needs to look underneath either when
dealing with the everyday "real world".
--
---------------------------
| BBB b \ Barbara at LivingHistory stop co stop uk
| B B aa rrr b |
| BBB a a r bbb | Quidquid latine dictum sit,
| B B a a r b b | altum viditur.
| BBB aa a r bbb |
-----------------------------
Randall Hyde
2005-02-16 14:02:57 UTC
Permalink
Post by Barb Knox
I once tried teaching "abstraction" in the (errr) abstract, and it bombed.
IMO, a stubbornly concrete domain is necessary for teaching the value and
techniques of abstraction.
This, too, has been my experience. Introductory students want to be
taught *practical* things right away. Stuff they can use. I remember
being taught MIX for example. Everyone in the class was griping
about how useless the knowledge was.
Cheers,
Randy Hyde
Brian Harvey
2005-02-16 18:56:54 UTC
Permalink
Post by Barb Knox
The analogy ASM:3GL :: QM:Newtonian breaks down because the structure of QM
seldom sticks its grubby paws into the macroscopic world (please, no flames
from quantum chemists...), but the structure of machine language shows up
all over the place in 3GLs: fixed-width 2's-complement integers, pointers,
arrays, records, the critical importance of exact sequence, etc. etc.
High level languages don't have fixed-width integers:

STk> (define (! n)
(if (= n 0)
1
(* n (! (- n 1)))))
!
STk> (! 1000)
402387260077093773543702433923003985719374864210714632543799910429938512398629
020592044208486969404800479988610197196058631666872994808558901323829669944590
997424504087073759918823627727188732519779505950995276120874975462497043601418
278094646496291056393887437886487337119181045825783647849977012476632889835955
735432513185323958463075557409114262417474349347553428646576611667797396668820
291207379143853719588249808126867838374559731746136085379534524221586593201928
090878297308431392844403281231558611036976801357304216168747609675871348312025
478589320767169132448426236131412508780208000261683151027341827977704784635868
170164365024153691398281264810213092761244896359928705114964975419909342221566
832572080821333186116811553615836546984046708975602900950537616475847728421889
679646244945160765353408198901385442487984959953319101723355556602139450399736
280750137837615307127761926849034352625200015888535147331611702103968175921510
907788019393178114194545257223865541461062892187960223838971476088506276862967
146674697562911234082439208160153780889893964518263243671616762179168909779911
903754031274622289988005195444414282012187361745992642956581746628302955570299
024324153181617210465832036786906117260158783520751516284225540265170483304226
143974286933061690897968482590125458327168226458066526769958652682272807075781
391858178889652208164348344825993266043367660176999612831860788386150279465955
131156552036093988180612138558600301435694527224206344631797460594682573103790
084024432438465657245014402821885252470935190620929023136493273497565513958720
559654228749774011413346962715422845862377387538230483865688976461927383814900
140767310446640259899490222221765904339901886018566526485061799702356193897017
860040811889729918311021171229845901641921068884387121855646124960798722908519
296819372388642614839657382291123125024186649353143970137428531926649875337218
940694281434118520158014123344828015051399694290153483077644569099073152433278
288269864602789864321139083506217095002597389863554277196742822248757586765752
344220207573630569498825087968928162753848863396909959826280956121450994871701
244516461260379029309120889086942028510640182154399457156805941872748998094254
742173582401063677404595741785160829230135358081840096996372524230560855903700
624271243416909004153690105933983835777939410970027753472000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000

High level languages do have pointers, but they're so ubiquitous that they
don't have the terrifying aspect that they do for C or Java students. And
there's nothing about the underlying hardware that's needed to understand
them -- they're just arrows.

It's true that to understand arrays you need the idea that things can have
consecutive memory addresses, so you can do arithmetic to find a given
element. But that's not much in the way of hardware-specificity.

We do just fine teaching all those ideas before we talk about machines.

PS: Once again, let me repeat that the topic under discussion isn't
whether one should *eventually* teach about machines, just whether one
has to start there. Of course we eventually teach about machines.
Phil Carmody
2005-02-16 20:35:09 UTC
Permalink
[...]
High level languages do have pointers, [...]
WTF?

At weekends do you put on a fake white beard, don a cloak, and tell
people that C doesn't require semicolons at the end of statements?

Phil
Percival
2005-02-16 22:18:04 UTC
Permalink
Post by Brian Harvey
Post by Barb Knox
The analogy ASM:3GL :: QM:Newtonian breaks down because the structure of QM
seldom sticks its grubby paws into the macroscopic world (please, no flames
from quantum chemists...), but the structure of machine language shows up
all over the place in 3GLs: fixed-width 2's-complement integers, pointers,
arrays, records, the critical importance of exact sequence, etc. etc.
<snip>

Generalizations are bad. Some HLL do, some don't.
Post by Brian Harvey
High level languages do have pointers, but they're so ubiquitous that they
don't have the terrifying aspect that they do for C or Java students. And
there's nothing about the underlying hardware that's needed to understand
them -- they're just arrows.
Again, some do, some don't. However, to understand it completely, you must
have a language that can represent pointers. I find it harder explaining
what a pointer is in Java when compared to Assembly.
Post by Brian Harvey
It's true that to understand arrays you need the idea that things can have
consecutive memory addresses, so you can do arithmetic to find a given
element. But that's not much in the way of hardware-specificity.
We do just fine teaching all those ideas before we talk about machines.
PS: Once again, let me repeat that the topic under discussion isn't
whether one should *eventually* teach about machines, just whether one
has to start there. Of course we eventually teach about machines.
I say it depends on the student.

Some learn better from machines and bit twiddling up.

Others are comfortable making the leaps across abstractions and ignoring
the "Why" and "How" underneath.

Percival
Annie
2005-02-16 23:27:43 UTC
Permalink
Post by Barb Knox
I once tried teaching "abstraction" in the (errr) abstract, and
it bombed. IMO, a stubbornly concrete domain is necessary for
teaching the value and techniques of abstraction.
_____
Gawhh! At last! ((( `\
_ _`\ )
The Kiwi lady shines the spot- (^ ) )
light of truth into this foggy ~-( )
swamp of theoretical pseudo- _'((,,,)))
intellectualizing. ,-' \_/ `\
( , |
Right on, Barb! `-.-'`-.-'/|_|
\ / | |
=()=: / ,' aa
Gerry Quinn
2005-02-16 10:01:42 UTC
Permalink
In article <42125677$***@news.tulsaconnect.com>, ***@eskimo.com
says...
Post by Jonathan Bartlett
* Machine language is very concrete. This makes it easy to
_understand_, even if it is hard to _use_ it to solve large problems with.
* People who have never messed with programming often have MAJOR
problems thinking sequentially and exactly. Assembly language breaks
you out of that habit real fast. You can see why the computer needs
instructions so exactly and in sequential order.
* When you learn concepts of other languages, you can see immediately
_why_ they are needed. This promotes curiosity, because you can see as
you learn how everything developed, which will make you curious how
other things develop. If you are just given Java or something "as is",
it tends to limit your question-asking, not extend it.
* Another issue that new programmers have is figuring out how to tie
small operations together to do larger ones. Nothing teaches you that
better than assembly language.
With the possible exception of the third, a traditional Basic does all
the above, and is much less cryptic.

- Gerry Quinn
Ro
2005-02-17 06:16:21 UTC
Permalink
Post by Jonathan Bartlett
Post by Brian Harvey
That doesn't imply that the lowest level is the right place to *start*.
* Machine language is very concrete. This makes it easy to
_understand_, even if it is hard to _use_ it to solve large problems with.
* People who have never messed with programming often have MAJOR
problems thinking sequentially and exactly. Assembly language breaks
you out of that habit real fast. You can see why the computer needs
instructions so exactly and in sequential order.
* When you learn concepts of other languages, you can see immediately
_why_ they are needed. This promotes curiosity, because you can see as
you learn how everything developed, which will make you curious how
other things develop. If you are just given Java or something "as is",
it tends to limit your question-asking, not extend it.
* Another issue that new programmers have is figuring out how to tie
small operations together to do larger ones. Nothing teaches you that
better than assembly language.
from me
* In a machine language seems clear that input and the data of a
routine is where there is the need of thinking too
osmium
2005-02-14 14:09:34 UTC
Permalink
Post by Jonathan Bartlett
Post by Jonathan Bartlett
I'm teaching at our local community college as an adjunct. They have
an
Post by Jonathan Bartlett
"intro to programming" class which teaches flow charting, logic, and
design principles for new programmers, using mostly pseudo-code
rather
Post by Jonathan Bartlett
than actual programs.
Why not use real code in a readable, high-level language such as
Python? I think that is a better way to intoduce newbies to programming
than pseudo-code or machine language.
How about because a programmer who can not read a flow chart has a flawed
background?

I think that state diagrams should also be introduced somewhere (later) in
an in-depth study.
Loading...