Bug 25652 - Java support for amd64-pc-freebsd
Summary: Java support for amd64-pc-freebsd
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: boehm-gc (show other bugs)
Version: unknown
: P3 normal
Target Milestone: 4.3.0
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-03 16:41 UTC by arno
Modified: 2008-01-26 12:04 UTC (History)
3 users (show)

See Also:
Host:
Target: amd64-pc-freebsd[56]
Build:
Known to work:
Known to fail:
Last reconfirmed: 2006-01-29 17:34:54


Attachments
Add support for amd64--freebsd (2.40 KB, patch)
2006-01-03 16:43 UTC, arno
Details | Diff
take-II this one works at -head as well (1.33 KB, patch)
2006-07-26 18:36 UTC, arno
Details | Diff
Take III (787 bytes, patch)
2006-10-23 14:58 UTC, arno
Details | Diff
No longer exclude libgcj on x86_64. (226 bytes, patch)
2007-09-13 10:48 UTC, arno
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description arno 2006-01-03 16:41:21 UTC
Hello,

Java is not supported for the amd64--freebsd targets, essentially
because of lacking support in boehm-gc.
I created a simple patch to do so :

 - no credits to me: most of this is directly inspired
   by the official freebsd-port of boehm-gc

 - tested for over 6 months on a non-graphical application
   with long-lasting scientific calculations (mixing
   C++, Fortran and Java code)

Concerning the patch :

  - the boehm-gc/include/gc_cpp.h-diff is only 
    to quiet the compiler,
  - the GC_parallel-diff in boehm-gc/pthread_support.c
    is not amd64--freebsd specific, but I did not test
    without it.

Thanx for your great work.
Comment 1 arno 2006-01-03 16:43:27 UTC
Created attachment 10578 [details]
Add support for amd64--freebsd
Comment 2 arno 2006-01-03 22:54:58 UTC
I forgot to mention : correct libjava testsuite results :

                === libjava Summary ===

# of expected passes            3964
# of unexpected failures        24
# of expected failures          10
# of untested testcases         26

FAIL: cxxtest.cc compilation
FAIL: PR16923.c compilation
Running /files/home/scito/.scito/tools/gcc41-branch/gcc/libjava/testsuite/libjav
a.lang/lang.exp ...
FAIL: PR18699 execution - gij test
FAIL: PR18699 execution - gij test
WARNING: program timed out.
FAIL: Process_1 execution - gij test
WARNING: program timed out.
FAIL: Process_1 execution - gij test
WARNING: program timed out.
FAIL: Process_2 execution - gij test
WARNING: program timed out.
FAIL: Process_2 execution - gij test
WARNING: program timed out.
FAIL: Process_3 execution - gij test
WARNING: program timed out.
FAIL: Process_3 execution - gij test
WARNING: program timed out.
FAIL: Process_4 execution - gij test
WARNING: program timed out.
FAIL: Process_5 execution - gij test
WARNING: program timed out.
FAIL: Process_6 execution - gij test
WARNING: program timed out.
FAIL: Process_6 execution - gij test
FAIL: Thread_Interrupt output - gij test
FAIL: Thread_Interrupt output - gij test
FAIL: Thread_Wait_Interrupt output - bytecode->native test
FAIL: Thread_Wait_Interrupt -O3 output - source compiled test
FAIL: Throw_2 execution - source compiled test
FAIL: Throw_2 execution - gij test
FAIL: Throw_2 execution - bytecode->native test
FAIL: Throw_2 -O3 execution - source compiled test
FAIL: Throw_2 execution - gij test
FAIL: Throw_2 -O3 execution - bytecode->native test
Comment 3 Andrew Pinski 2006-01-29 17:34:54 UTC
Confirmed, patches go to gcc-patches@ and java-patches@.
Comment 4 Tom Tromey 2006-01-30 16:37:37 UTC
You may want to send the GC patch upstream, to the GC list.
Comment 5 arno 2006-07-26 18:36:41 UTC
Created attachment 11950 [details]
take-II this one works at -head as well

Bon,

apparently I'm (almost) the only one who uses gcj on freebsd-amd64, but here's another patch; the basic differences with the first one are removal of unneeded diffs (apart non-tested gcconfig.h support for freebsd-[arm|powerpc]) and explicitly using FREEBSD_STACKBOTTOM as well as GC_FreeBSDGetDataStart().

 === libjava Summary ===

# of expected passes            6887
# of unexpected failures        21
# of expected failures          12
# of untested testcases         28

Failures are :

FAIL: PR16923.c
FAIL: PR27908
FAIL: Throw_2
Comment 6 arno 2006-10-23 14:58:30 UTC
Created attachment 12480 [details]
Take III

Most of the original patch probably has been commited when
adding support for GNU/kFreeBSD.

However, this final small patch is still needed to actually
recognise freebsd-amd64 and correctly build and run
boehm-gc when --enable-libgcj is given
Comment 7 Gerald Pfeifer 2007-08-25 14:55:35 UTC
Is this patch still relevant as is?  I'd like to ask our Java developers
to have a look, but it would be good if you (as the original submitter)
could verify and, if needed, provide a patch against our current development
tree.

Thanks!
Comment 8 arno 2007-09-13 10:46:25 UTC

Since January commits to boehm-gc for handling amd64/x86-64 cpu under
GNU/kFreeBSD, I confirm that libgcj-support is OK for x86_64*freebsd

IMHO this PR can be closed

I propose a last 'patch' to hook it by default on
the build
Comment 9 arno 2007-09-13 10:48:08 UTC
Created attachment 14201 [details]
No longer exclude libgcj on x86_64.
Comment 10 Richard Biener 2008-01-26 12:04:42 UTC
Fixed.