Linkers and Loaders (The Morgan Kaufmann Series in Software Engineering and Programming)
W**D
Best around
I've been around compilers, code generation, and object formats enough that this was mostly a refresher - but I did like some of the historical references and notes on atypical processors. I think this works at a good level of detail for experienced programmers who can fill in the blanks for things like relocation records that identify which bit positions need to be set. An experienced programmer will also have used symbolic debuggers, and will have a fair idea of what those tools expect to find in an executable image.I found discussion of linker scripts a bit thin, though - on one embedded application, I think I wrote more lines of linker scripts than of assembler. The author does mention things like linking a piece of code to run at address X but storing it in memory at address Y. You'll need this, for example, when your processor has a small but fast on-chip RAM (address X), and you have a few different code fragments (stored at addresses Y) you'll be loading into that buffer at different times.It also doesn't mention useful things like defining a symbol at the linker instead of the application code - helpful when coding to a memory mapped device that might live at different addresses in different application configurations. I also used this this feature with the GNU linker and this command line option: "-defsym,buildDateTime=$(shell date +%s)". That embeds the build time in the application - not as a value stored in memory, but as the address of the buildDateTime symbol which then gets cast to a time value.This does mention overlays, which can still be life-savers when coding a large application for a small (e.g. 16-bit) address space. I saw only 'tree-structured' overlays described, though, the kind found in DEC's RSX-11 operating system. I did not see mention of 'band-structured' overlays, as found in DEC's RT-11 system. That disappointed me because I've found the concept helpful in small address spaces with larger ROMs where, for example, something like overlays could be used for internationalization. With a helpful bus controller, you could swap between UI messages in different languages by choosing which languages' message overlay appears in the address space at any given time.No text can cover everything. For example, this omits the "cmpexe" compound executable format used in the Apollo Domain system. The one runnable file actually held code in two different instruction sets, so one program file could be used on both the 680x0 or the "Prism" processor architectures - the loader just chose which side of the program to run. Heterogeneous environments like that have been rarities, but the idea remains interesting. I was also involved in design of a microcode linker, where addresses were not numbers but bit-strings. Since sequential addresses had little meaning, individual instructions from different input segments could be interleaved, subject to bit pattern constraints on micro-addresses.Historical exotica aside, this gives a strong foundation in the basic concepts of linking and loading. It offers just enough of a look at CPU hardware to show how instruction formats and memory characteristics affect the process. It also presents a nice progression from simpler to more complex object formats, and the reasons for them. I imagine this as a useful adjunct to a college course in compilers or operating systems, and helpful to professionals self-teaching about what's "under the hood" in familiar programming tools. Highly recommended, but you might outgrow it quickly once you start working on the tools yourself.-- wiredweird
A**R
Excellent Coverage of Underexplained Concepts
I've yet to come across someone who wrote software who didn't learn most of this material the hard way; most software-related education neglects that real projects need to be built with objects, libraries, debug information, dependencies, and so on, and not just header-file + source file = program. This provides that missing... link.See what I just did there?Seriously though, it's far from an exhaustive reference of every build structure for every platform (good luck finding one that is), but it covers most of the things necessary to string a real project together of greater scope than a semester project. An understanding of compilers is fairly important for getting this book. If you put together anything more complex than "link UI to database and you're done here," read this book so someone doesn't have to explain why your project isn't building.
P**E
A classic
Well worth reading if you want to understand many of the ideas that went into the design of loadable and executable binaries.
I**Y
but its still a great treatment of the subject matter
Delivered as promised. The book is a bit dated, but its still a great treatment of the subject matter.
S**E
Really Cool Knowledge
It's true that this book is a few years old. But, I emailed the author and he said not much as changed so it's safe to read the book and know you are still learning good stuff. I bought this book to help me understand how compilers and linkers work. Thus far it's been a good education. I can certainly look at my iOS\Objective-C coding and have some understanding of what's going on under the hood, which helps with understanding the language. I am finding that I need to read each section several times over. But, this is normal for a completely new topic of learning. I give this book 4 starts because I"m not completely confident that I'm not learning a few things that are outdated. But, a history lesson doesn't hurt either.
D**R
Five Stars
Careful introduction to linking and loading based on the simplest up to very sophisticated processor architectures.
P**Y
Solid
Really solid coverage of the topics.
T**K
Hard to understand. Tons of information dumped without explanation.
The media could not be loaded. Book is full of information without any explanation.
S**R
The only (and naturally the best) book on the subject!!
The book is the only one of its kind, and of great value to anyone who wishes to look under the hood of program loading and linking mechanisms.Needless to say, it is an indispensable resource for compiler and linker experts. The only downside is that the book is slightly dated (with loads of legacy topics and their history to be found) and has not been updated in a recent edition. But then, once a solid groundwork is laid, it should be easy to explore and understand newer linking mechanisms pretty quickly; after all, it's not everyday that a newer linker feature is developed or architecture targeted!!
H**H
Five Stars
perfect
I**C
Clear and comprehensive
This book is a great deal for everyone interested in how does linking and loading work under the hood. It goes clearly and steadily from basic notions of architecture into the gory details of linking and loading on multiple platforms. Definitely the best on the topic I've ever read.
O**N
dllのしくみがわかる!
WindowsのOSとしての核心技術dllのしくみがわかる数少ない書籍。全体としては実行モジュール(exe,dll)がメモリにどのようにロード、リンクされて実行されるのかを代表的なCPUのアーキテクチャ(x86,SPARC等)、実行ファイルのアーキテクチャ(Windows,UNIX等)毎にも説明してくれます。
C**H
one of the best books for ld / Link load / linking and loading
Art of systems programming and the support of modularity truly with c/c++ is finally at the end comes to Linking and loaded , it takes times to master it, but when you start to learn, I highly recommend this book as it gives very good info and insights. V knowledgeable author and contents. May be old, but does not matter, gold standard book.
Trustpilot
1 day ago
2 months ago