home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Bug_Fixes / Net.v7bugs / 0074 < prev    next >
Encoding:
Text File  |  1982-02-17  |  1.3 KB  |  32 lines

  1. Autzoo.1394
  2. net.bugs.v7
  3. utcsrgv!utzoo!henry
  4. Wed Feb 17 00:01:55 1982
  5. ld big-file bug
  6. To see an interesting explosion, try the following.  Compile all the
  7. pieces of f77pass1.  Either work in a copy of the makefile or set up
  8. a shell variable (say $all) containing the list of files in $(OBJECTS)
  9. in the makefile.  Do this:
  10.  
  11.     ld -r -X $all -o junk.o
  12.  
  13. This has created one a.out with all the object modules in it.  The -r
  14. is to tell it we're not through yet, the -X is to strip trivia out of
  15. the symbol table so later steps won't blow up on too many symbols.  Run
  16. "size" on junk.o, noticing that text+data (forgetting bss) is over 16 bits.
  17. Now:
  18.  
  19.     ld -X /lib/crt0.o -i junk.o -lc
  20.  
  21. This ought to yield f77pass1, right?  Wrong, it lists _main as undefined
  22. and then explodes, giving an "internal error" message.  The fixed-up
  23. loader supplied with VU Pascal explodes the same way.  The fixes don't go
  24. far enough.
  25.  
  26. The problem is almost certainly a 16-bit overflow in a file offset, but
  27. I've tried some obvious fixes and they don't help (at least, not enough),
  28. and I lack the time to explore ld.c in detail just now.  Note that it shows
  29. up only for monstrous INPUT files:  ld has no trouble building f77pass1
  30. if the input is broken up into the usual pieces.  This makes the problem
  31. a bit less important than it would be otherwise.
  32.