In case there will one day be another revision of the text I thought I'd point out a few minor details that I noticed that may be errors or anomalies that may warrant a little comment.
chapter 6:
In both the read-record.s and write-record.s functions the register %ebx gets pushl'ed onto the stack and popl'ed off the stack for no apparent reason as far as I could see.
In write-records.s the ".section .text" assembler directive is missing. As it is now, all the instructions are inside .data.
In count-chars.s the standard "movl %ebp, %esp" (of the C calling convention) is missing from count_loop_end:.
chapter 8:
The modification of add-year.s should contain the line "jge continue_processing" instead of "jl continue_processing". This is a somewhat critical bug, as it obviously prevents the program from running as expected.
chapter 9:
The text describes (aptly!) the following sequence of data from the bottom of the stack upwards:
zero -> program name -> environment variables -> command-line arguments -> # of arguments (= position of %esp)
The diagram however gives the following sequence from the bottom of the stack upwards:
zero -> environment variables -> command-line arguments -> program name -> # of arguments (= position of %esp)
Either one of these places puts the program name in the wrong place or there is something left unexplained here.
I apologize if any of these 'bugs' have already been reported or if I simply misread things. If I stumble on anymore anomalies during further reading I'd be happy to report those too if appreciated (apart from harmless typos ;). Thanks again for an enjoyable read.
Ruben
_______________________________________________ Pgubook-readers mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/pgubook-readers
