possible ar/ld bug on cygwin

Wei Dai weidai@eskimo.com
Mon Oct 23 21:08:00 GMT 2000


I'm running into what seems like a bug in ar or ld, where ld produces an
executable that contains a "call 0" instruction which of course causes an
access violation. This happens if the code that generates the "call
0" is in a library produced by ar, but it doesn't happen if I skip ar and
just link all the .o files together. The call instruction should be
calling a static member function of a template class in the standard C++
library (namely __default_alloc_template<__threads, __inst>::_S_refill). 

I'm running Celeron, Windows 2000 SP1, cygwin DLL 1.1.4, GCC 2.95.2-2,
and binutils 2.10.90. The same code compiles and links fine on FreeBSD
4.1, GCC 2.95.2, and binutils 2.10.0. I would appreciate any advice on
what to try next, and I would also be happy to send the code and makefile
to anyone or put it up on a web site.


More information about the Binutils mailing list