This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH for java.nio FileChannel and MappedByteBuffer



On Mar 18, 2004, at 16:56, Mike Stump wrote:
I am seeing a bootstrap error on darwin:

/Volumes/mrs3/net/gcc-darwin/gcc/xgcc -shared-libgcc -B/Volumes/mrs3/net/gcc-darwin/gcc/ -nostdinc++ -L/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libstdc++-v3/ src -L/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libstdc++-v3/ src/.libs -B/Volumes/mrs3/Packages/gcc-20040315/powerpc-apple-darwin7.2.0/bin/ -B/Volumes/mrs3/Packages/gcc-20040315/powerpc-apple-darwin7.2.0/lib/ -isystem /Volumes/mrs3/Packages/gcc-20040315/powerpc-apple-darwin7.2.0/include -isystem /Volumes/mrs3/Packages/gcc-20040315/powerpc-apple-darwin7.2.0/sys- include -dynamiclib -flat_namespace -undefined suppress -o .libs/libgcj.6.0.0.dylib .libs/libgcj.6.0.0.dylib-master.o -L/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libstdc++-v3/ src -L/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libstdc++-v3/ src/.libs -L/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libjava ../boehm-gc/.libs/libgcjgc_convenience.a ../libffi/.libs/libffi_convenience.a ../zlib/.libs/libzgcj_convenience.a -lpthread ./libltdl/.libs/libltdlc.a -ldl -lc -install_name /Volumes/mrs3/Packages/gcc-20040315/lib/libgcj.6.dylib -compatibility_version 7 -current_version 7.0
ld: warning multiple definitions of symbol _sqrt
.libs/libgcj.6.0.0.dylib-master.o definition of _sqrt in section (__TEXT,__text)
/usr/lib/libpthread.dylib(sqrt970.o) definition of _sqrt
ld: .libs/libgcj.6.0.0.dylib-master.o has external relocation entries in non-writable section (__TEXT,__text) for symbols:
_libiconv
_msync
_munmap
/usr/bin/libtool: internal link edit command failed
make[2]: *** [libgcj.la] Error 1
make[2]: Leaving directory `/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libjava'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/Volumes/mrs3/net/gcc-darwin/powerpc-apple-darwin7.2.0/libjava'
make: *** [all-target-libjava] Error 2


I think Geoff's tester is offline, as otherwise I think it would have complained about it. Could the person that broke it fix it, thanks. I don't know exactly who that is.


I know who caused it by really it is a latent bug in Darwin's back end.

See PR 14580 (if you can):

Here is the latest from Roger (who caused the failure), it is the bug already:
Well, it looks like combine is doing "the right thing" as far as the RTL-level
transformation is concerned. It's turning


(set (reg119) (...)) (REG_EQUAL symbol_ref (!t__unmap)))
(set (reg3) (call (mem (reg119))))

into

(set (reg3) (call (mem (symbol_ref (!t__unmap)))))

i.e. it's optimized an indirect jump into a direct jump. I suspect that
the problem with the rs6000.md backend may be that the constraints for the
*call_value_nonlocal_sysv pattern shouldn't be accepting this replacement,
recognizing "mem (symbol_ref (!t__unmap))" as a invalid operand on darwin.


I think rs6000's use of REG_EQUAL notes is reasonable in this case, as they
can be used in other optimizations. So I believe that the correct fix is to
inform the backend that library functions must be called indirectly via their
thunks. I'm also surprised that this hasn't bitten folks in CSE and/or GCSE
before now.


Of course, I'm assuming that the RTL is accurately describing the intended
semantics here.



Thanks, Andrew Pinski


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]