25 Replies Latest reply on Dec 23, 2011 2:58 AM by santosh.zanjurne

    iso_c_binding in fortran

    Dimitar_Pashov
      is iso_c_binding coming to open64?

      Hi!

      The iso_c_binding module provides a portable interoperability between C and fortran programs and libraries. It is available at least in gcc, intel, sun pro and pgi's fortran compilers.

      Using this module one can easily write an interface for C function and call it from fortran and vise versa.  Without this module developers are left with messy configure scripts or worse guessing what would the naming conventions be.

      I know it is part of the 2003 standard and not 95 but it is very useful and may not be too hard to implement.

      I hope it is included in open64 soon.

       

       

       

        • iso_c_binding in fortran
          dgilmore

          I just filed an internal feature request for this. 

          Thanks for the feedback,

          Doug

           

            • iso_c_binding in fortran
              RaghavendraSwamy

              Hi,

              - The feature request reported by you has been implemented in the latest AMD x86 Open64 compiler 4.2.4-1 release. The compiler binary can be downloaded from the link: http://developer.amd.com/cpu/open64/Pages/default.aspx

              - Please let us know if you have any other issues.

              Thanks and regards,
              AMD x86 Open64 Compiler Support Engineer.

              -------------------------
              The information presented in this document is for informational purposes only and may contain technical inaccuracies, omissions and typographical errors. Links to third party sites are for convenience only, and no endorsement is implied.

                • iso_c_binding in fortran
                  janusw

                  Hi,

                  I just tried the new ISO_C_BINDING support in openf95, but it rejects the following module (which is accepted by all other compilers I tried: ifort, gfortran, g95, sunf95):

                   

                  module bzip

                    use, intrinsic :: ISO_C_BINDING, only: c_int, c_char

                    implicit none

                    type bzFile
                      integer(c_int) :: handle = 0
                      character(kind=c_char,len=100) :: fname
                    end type

                    interface
                      function fOpen(path,mode) bind(C, NAME='fopen')
                        use, intrinsic :: ISO_C_BINDING
                        character(c_char) path(*),mode(*)
                        integer(c_int) :: fOpen
                      end function
                    end interface

                  contains

                    function bzOpenR(fname)
                      character(len=*) :: fname
                      character(kind=c_char,len=10) :: mode = "r"//achar(0)
                      type(bzFile) :: bzOpenR

                      bzOpenR%fname=trim(fname)//achar(0)
                      bzOpenR%handle = fOpen(bzOpenR%fname,mode)

                    end function

                  end module

                   

                  module bzip
                         ^   
                  openf95-855 openf95: ERROR BZIP, File = bzip.f90, Line = 1, Column = 8
                    The compiler has detected errors in module "BZIP".  No module information file will be created for this module.

                      bzOpenR%handle = fOpen(bzOpenR%fname,mode)
                                                     ^          
                  openf95-435 openf95: ERROR BZOPENR, File = bzip.f90, Line = 28, Column = 36
                    Illegal association of a scalar actual argument with array dummy argument "PATH".
                                                           ^    
                  openf95-435 openf95: ERROR BZOPENR, File = bzip.f90, Line = 28, Column = 42
                    Illegal association of a scalar actual argument with array dummy argument "MODE".

                  openf95: Open64 Fortran Version 4.2.4 (f14) Fri Aug 13, 2010  15:15:54
                  openf95: 32 source lines
                  openf95: 3 Error(s), 0 Warning(s), 0 Other message(s), 0 ANSI(s)
                  openf95: "explain openf95-message number" gives more information about each message

                   

                  Cheers,

                  Janus

                   

                    • iso_c_binding in fortran
                      dgilmore

                      Sorry about that, you trip over a bug in the F90 front end.

                      I am investigating.

                      Doug

                        • iso_c_binding in fortran
                          dgilmore

                          We have a fix for this problem, so the problem will be fixed in the next release.

                          It may be possible to get the change into a patch update of the current 4.2.4 release, we'll let you know if it does.

                          Thanks for reporting this issue.

                          Doug

                            • iso_c_binding in fortran
                              janusw

                              Great, thanks for fixing.

                              Can you tell me when the next release can be expected to be released? Will this be a 4.2.4.x release or rather 4.2.5?

                              I have a large Fortran code, which could not be compiled with openf95 up to now, and which could potentially uncover more bugs. I would be glad to test any patches you provide.

                              Thanks,

                              Janus

                               

                                • iso_c_binding in fortran
                                  dgilmore

                                  We plan to release 4.2.5 early next year.

                                  Obviously 4.2.4.1 will be out sooner, we are still batching up patches associated with this minor release so I can't give you a definite date.

                                  If you are willing to try building your own compiler, I may be able to send you a source patch for the problem.  That would allow us to make headway on any outstanding Fortran front-end issues that we would want to address.

                                  Doug

                                    • iso_c_binding in fortran
                                      janusw

                                      Yes, I am willing to build my own compiler. I haven't tried building open64 up to now, but I have quite some experience with building GCC.

                                      Would be great if you could send me a patch. Then I will check my full code. The test case I posted above was only a part of a module which I use as an interface to libbz2, which in turn is part of a large F77/95/03 code base.

                                      Thanks,

                                      Janus

                                       

                                        • iso_c_binding in fortran
                                          dgilmore

                                          I attached the preliminary patch for the fix.

                                          Note that the change in still in the process of being reviewed and tested so we may be supplying a new version of it in the future.

                                          The file INSTALL in the source tarball contains the build instructions for the compiler.

                                          What Linux distribution are you using (you shouldn't see build issues on RHEL5 or SLES10 or SLES11 systems)?

                                          Doug

                                            • iso_c_binding in fortran
                                              janusw

                                              Thanks a lot for the patch.

                                              I have access to Ubuntu 10.04 as well as openSUSE 11.x systems (x86_64). Should I expect problems on any of these? Any recommendation about which GCC version works best to build open64?

                                              Cheers,

                                              Janus

                                               

                                                • iso_c_binding in fortran
                                                  dgilmore

                                                  I suspect you will have the easiest time on OpenSuse 11, using either 4.2 or 4.3 versioned GNU compilers.

                                                  Doug

                                                   

                                                    • iso_c_binding in fortran
                                                      janusw

                                                      Ok, I have applied the patch and built the compiler (successfully it seems). And I can confirm that the patch indeed fixed the error I reported earlier. So, thanks a lot for that!

                                                      However, I now get errors of the following type when compiling with -r8:

                                                      ### Assertion failure at line 1029 of ../../be/cg/x8664/cg_convert_x87.cxx:
                                                      ### Compiler Error in file barbar_to_barbar_model.f90 during Converting x87 stack registers phase:
                                                      ### x87 stack is non-empty
                                                      openf95 INTERNAL ERROR: /opt/open64/lib/gcc-lib/x86_64-open64-linux/4.2.4/be returned non-zero status 1

                                                      I'll try to prepare a reduced test case ...

                                                      Cheers,

                                                      Janus

                                                        • iso_c_binding in fortran
                                                          janusw

                                                          Here is a test case for the new failure. It's as simple as that:

                                                          program test
                                                            real :: ms
                                                            complex :: direct, crossed
                                                            ms = 2.*(direct+crossed)
                                                          end
                                                           
                                                          When compiled with -g -r8 it gives me:

                                                          ### Assertion failure at line 1366 of ../../be/cg/x8664/cg_convert_x87.cxx:
                                                          ### Compiler Error in file test2.f90 during Converting x87 stack registers phase:
                                                          ### x87 stack is inconsistent.
                                                          openf95 INTERNAL ERROR: /opt/open64/lib/gcc-lib/x86_64-open64-linux/4.2.4/be returned non-zero status 1

                                                          However this only happens with the patched version of 4.2.4 that I built myself, but not with the 4.2.4 binary I downloaded. So it seems like it is a regression of the patch. Any ideas?

                                                          Cheers,

                                                          Janus

                                                           

                                                            • iso_c_binding in fortran
                                                              dgilmore

                                                              Hmmm, I am not seeing this issue with a patched compiler built here.

                                                              Could you add:

                                                               -Wb,-tra -keep -v

                                                              to your compilation command line, and repost with the compiler output and the associated .t file attached to the message (note that you need to upload the files before attaching them)?

                                                              Thanks,

                                                              Doug

                                                                • iso_c_binding in fortran
                                                                  janusw

                                                                  With these additional flags I get the following output:

                                                                  Open64 Compiler Suite: Version 4.2.4
                                                                  Built on: 2010-08-18 16:44:21 +0200
                                                                  Thread model: posix
                                                                  GNU gcc version 4.2.0 (Open64 4.2.4 driver)
                                                                  openf95 WARNING: -g changes optimization to -O0 since no optimization level is specified
                                                                  /opt/open64/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95 -G8 -O0 -g2 -r8 -show -TARG:abi=n32 -FE:cmdline=/tmp/ccL#.9SV1nU -TARGrocessor=athlon -TARG:sse2=off -TARG:mmx=off -TARG:sse=off -TARG:sse3=off -TARG:3dnow=off -TARG:sse4a=off -TARG:ssse3=off -TARG:sse41=off -TARG:sse42=off -TARG:aes=off -TARGclmul=off -TARG:avx=off -TARG:xop=off -TARG:fma4=off -fB,test2.B -fC,test2.T -fD,test2.l -ffree -LANG:=F90 -include=/opt/open64/include/4.2.4 test2.f90
                                                                  /opt/open64/lib/gcc-lib/x86_64-open64-linux/4.2.4/be -PHASE:c -G8 -O0 -g2 -tra -show -TARG:abi=n32 -LANG:=f90 -TARGrocessor=athlon -TARG:sse2=off -TARG:mmx=off -TARG:sse=off -TARG:sse3=off -TARG:3dnow=off -TARG:sse4a=off -TARG:ssse3=off -TARG:sse41=off -TARG:sse42=off -TARG:aes=off -TARGclmul=off -TARG:avx=off -TARG:xop=off -TARG:fma4=off -fB,test2.B -s -fs,test2.s test2.f90
                                                                  Compiling test2.f90 (test2.B) -- Back End
                                                                  Compiling MAIN__(0)

                                                                  ### Assertion failure at line 1366 of ../../be/cg/x8664/cg_convert_x87.cxx:
                                                                  ### Compiler Error in file test2.f90 during Converting x87 stack registers phase:
                                                                  ### x87 stack is inconsistent.
                                                                  openf95 INTERNAL ERROR: /opt/open64/lib/gcc-lib/x86_64-open64-linux/4.2.4/be returned non-zero status 1

                                                                   

                                                                  The .t file is attached.

                                                                  Cheers,

                                                                  Janus

                                                                   

                                                                  ========== Driver dump after IR_READ ========== LOC 0 0 source files: 1 "/home/nucleus/jweil/fortran/compiler_bugs/open64/test2.f90" FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ========== Dump before VHO Lowering ========== FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ========== Dump before F90 Lowering ========== FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ========== Dump after F90 Lowering ========== FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ========== Dump after VHO Lowering ========== FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= WN_Lower: "Fast exponents lowering" flags are: <unrecognized> FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD C8PAREN F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "After lowering" FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= After Region Init: FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "RETURN_VAL & MLDID/MSTID lowering" flags are: LOWER_RETURN_VAL FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "After lowering" FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "Lower MLDID/MSTID when not running WOPT" flags are: LOWER_MLDID_MSTID FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "After lowering" FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "Lowering to CG" flags are: LOWER_DO_LOOP LOWER_DO_WHILE LOWER_WHILE_DO LOWER_IF LOWER_COMPLEX LOWER_ARRAY LOWER_ENTRY_EXIT LOWER_CALL LOWER_IO_STATEMENT LOWER_MSTORE LOWER_CVT LOWER_MP LOWER_COMPGOTO LOWER_MADD LOWER_INTRINSIC LOWER_INLINE_INTRINSIC LOWER_INL_STACK_INTRINSIC LOWER_PREFETCH_MAPS LOWER_ALIAS_MAPS LOWER_DEPGRAPH_MAPS LOWER_PARITY_MAPS LOWER_PICCALL LOWER_ASSERT LOWER_FREQUENCY_MAPS LOWER_FORMAL_REF LOWER_UPLEVEL LOWER_ENTRY_FORMAL_REF LOWER_SHORTCIRCUIT LOWER_BIT_FIELD_ID <unrecognized> <unrecognized> LOWER_TO_CG FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} C8C8LDID 0 <2,1,CROSSED> T<18,.predef_C8,4> C8C8LDID 0 <2,2,DIRECT> T<18,.predef_C8,4> C8ADD F8CONST <1,55,____2.000000000000000> C8MPY F8FIRSTPART F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= WN_Lower: "After lowering" FUNC_ENTRY <1,50,MAIN__> {line: 3} BODY BLOCK {line: 0} END_BLOCK BLOCK {line: 0} END_BLOCK BLOCK {line: 3} PRAGMA 0 120 <null-st> 0 (0x0) # PREAMBLE_END {line: 0} F8F8LDID 0 <2,1,CROSSED> T<11,.predef_F8,4> F8F8LDID 0 <2,2,DIRECT> T<11,.predef_F8,4> F8ADD F8STID 49 <1,11,.preg_F8> T<11,.predef_F8,4> # <preg> {line: 6} F8F8LDID 8 <2,1,CROSSED> T<11,.predef_F8,4> F8F8LDID 8 <2,2,DIRECT> T<11,.predef_F8,4> F8ADD F8STID 50 <1,11,.preg_F8> T<11,.predef_F8,4> # <preg> {line: 6} F8F8LDID 49 <1,11,.preg_F8> T<11,.predef_F8,4> # <preg> F8CONST <1,60,____2.000000000000000> F8MPY F8STID 0 <2,3,MS> T<11,.predef_F8,4> {line: 6} VCALL 2174 <1,52,_END> # flags 0x87e {line: 7} RETURN {line: 7} END_BLOCK ======================================================================= ======================================================================= ======================================================================= IR after Code_Expansion ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0009 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] TN4(%rsp) :- spadjust TN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 |||||[1]! compile with -r8 |||||[2] |||||[3]program test [ 3, 0] TN4(%rsp) :- pushl TN3(%rbp) TN4(%rsp)<defopnd> ; [ 3, 0] TN3(%rbp) :- mov32 TN4(%rsp) ; copy [ 3, 0] TN4(%rsp) :- spadjust TN4(%rsp)<defopnd> (0x0) ; |||||[4] real :: ms |||||[5] complex :: direct, crossed |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150 :- fldl TN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151 :- fldl TN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149 :- fadd TN150 TN151 ; [ 6, 0] TN153 :- fldl TN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154 :- fldl TN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152 :- fadd TN153 TN154 ; [ 6, 0] TN155 :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156 :- fmul TN149 TN155 ; [ 6, 0] :- fstpl TN156 TN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0004 Exit block SP exit adj: [ 7, 0] TN4(%rsp) :- spadjust TN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none [ 7, 0] TN4(%rsp) :- spadjust TN4(%rsp)<defopnd> (0x0) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ======================================================================= ======================================================================= IR after Localize ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0009 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 defreach_in : {} live_in : {3-4,157-159} defreach_out: {3-4} live_out : {4,157-159} live_def : {} live_use : {3-4} |||||[3]program test [ 3, 0] GTN4(%rsp) :- pushl GTN3(%rbp) GTN4(%rsp)<defopnd> ; [ 3, 0] GTN3(%rbp) :- mov32 GTN4(%rsp) ; copy [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150 :- fldl GTN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151 :- fldl GTN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149 :- fadd TN150 TN151 ; [ 6, 0] TN153 :- fldl GTN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154 :- fldl GTN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152 :- fadd TN153 TN154 ; [ 6, 0] TN155 :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156 :- fmul TN149 TN155 ; [ 6, 0] :- fstpl TN156 GTN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0004 Exit block SP exit adj: [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none defreach_in : {3-4} live_in : {4} defreach_out: {3-4} live_out : {} live_def : {} live_use : {4} [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ======================================================================= ======================================================================= IR after Local Register Allocation ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0809 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 defreach_in : {} live_in : {3-4,157-159} defreach_out: {3-4} live_out : {4,157-159} live_def : {} live_use : {3-4} |||||[3]program test [ 3, 0] GTN4(%rsp) :- pushl GTN3(%rbp) GTN4(%rsp)<defopnd> ; [ 3, 0] GTN3(%rbp) :- mov32 GTN4(%rsp) ; copy [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150(%st4) :- fldl GTN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151(%st1) :- fldl GTN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149(%st1) :- fadd TN149(%st1)<defopnd> TN150(%st4) ; [ 6, 0] TN153(%st3) :- fldl GTN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154(%st2) :- fldl GTN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152(%st2) :- fadd TN152(%st2)<defopnd> TN153(%st3) ; [ 6, 0] TN155(%st0) :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156(%st0) :- fmul TN156(%st0)<defopnd> TN149(%st1) ; [ 6, 0] :- fstpl TN156(%st0) GTN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0804 Exit block SP exit adj: [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none defreach_in : {3-4} live_in : {4} defreach_out: {3-4} live_out : {} live_def : {} live_use : {4} [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ======================================================================= ======================================================================= IR after GRU0 ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0809 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 defreach_in : {} live_in : {3-4,157-159} defreach_out: {3-4} live_out : {4,157-159} live_def : {} live_use : {3-4} |||||[3]program test [ 3, 0] GTN4(%rsp) :- pushl GTN3(%rbp) GTN4(%rsp)<defopnd> ; [ 3, 0] GTN3(%rbp) :- mov32 GTN4(%rsp) ; copy [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150(%st4) :- fldl GTN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151(%st1) :- fldl GTN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149(%st1) :- fadd TN149(%st1)<defopnd> TN150(%st4) ; [ 6, 0] TN153(%st3) :- fldl GTN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154(%st2) :- fldl GTN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152(%st2) :- fadd TN152(%st2)<defopnd> TN153(%st3) ; [ 6, 0] TN155(%st0) :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156(%st0) :- fmul TN156(%st0)<defopnd> TN149(%st1) ; [ 6, 0] :- fstpl TN156(%st0) GTN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0804 Exit block SP exit adj: [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none defreach_in : {3-4} live_in : {4} defreach_out: {3-4} live_out : {} live_def : {} live_use : {4} [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ======================================================================= ======================================================================= IR after GRU ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0809 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 defreach_in : {} live_in : {3-4,157-159} defreach_out: {3-4} live_out : {4,157-159} live_def : {} live_use : {3-4} |||||[3]program test [ 3, 0] GTN4(%rsp) :- pushl GTN3(%rbp) GTN4(%rsp)<defopnd> ; [ 3, 0] GTN3(%rbp) :- mov32 GTN4(%rsp) ; copy [ 3, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150(%st4) :- fldl GTN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151(%st1) :- fldl GTN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149(%st1) :- fadd TN149(%st1)<defopnd> TN150(%st4) ; [ 6, 0] TN153(%st3) :- fldl GTN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154(%st2) :- fldl GTN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152(%st2) :- fadd TN152(%st2)<defopnd> TN153(%st3) ; [ 6, 0] TN155(%st0) :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156(%st0) :- fmul TN156(%st0)<defopnd> TN149(%st1) ; [ 6, 0] :- fstpl TN156(%st0) GTN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0804 Exit block SP exit adj: [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none defreach_in : {3-4} live_in : {4} defreach_out: {3-4} live_out : {} live_def : {} live_use : {4} [ 7, 0] GTN4(%rsp) :- spadjust GTN4(%rsp)<defopnd> (0x0) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ======================================================================= ======================================================================= IR after Hyperlock Scheduler ======================================================================= ======================================================================= .proc MAIN__# ----------------------------------------------------------------------- // Block: 1 Pred: Succ: 2 ----------------------------------------------------------------------- BB:1 (length:13) -- flags = 0x0c09 Entry block Call block Entrypoint: MAIN__ Starting Line 3 SP entry adj: [ 3, 0] GTN4(%rsp) :- addi32 GTN4(%rsp)<defopnd> (0xffffffffffffffd0) ; In linear order, BB_prev == BB:-1; BB_next == BB: 2 Predecessors: none Successors: BB: 2 defreach_in : {} live_in : {3-4,157-159} defreach_out: {3-4} live_out : {4,157-159} live_def : {} live_use : {3-4} |||||[3]program test [ 3, 0] GTN4(%rsp) :- pushl GTN3(%rbp) GTN4(%rsp)<defopnd> ; [ 3, 0] GTN3(%rbp) :- mov32 GTN4(%rsp) ; copy [ 3, 0] GTN4(%rsp) :- addi32 GTN4(%rsp)<defopnd> (0xffffffffffffffd0) ; |||||[6] ms = 2.*(direct+crossed) [ 6, 0] TN150(%st4) :- fldl GTN3(%rbp) (sym:CROSSED+0) ; [ 6, 0] TN151(%st1) :- fldl GTN3(%rbp) (sym:DIRECT+0) ; [ 6, 0] TN149(%st1) :- fadd TN149(%st1)<defopnd> TN150(%st4) ; [ 6, 0] TN153(%st3) :- fldl GTN3(%rbp) (sym:CROSSED+8) ; [ 6, 0] TN154(%st2) :- fldl GTN3(%rbp) (sym:DIRECT+8) ; [ 6, 0] TN152(%st2) :- fadd TN152(%st2)<defopnd> TN153(%st3) ; [ 6, 0] TN155(%st0) :- fldl_n32 (sym:.rodata+0) ; noalias [ 6, 0] TN156(%st0) :- fmul TN156(%st0)<defopnd> TN149(%st1) ; [ 6, 0] :- fstpl TN156(%st0) GTN3(%rbp) (sym:MS+0) ; side_effects |||||[7]end [ 7, 0] :- call (sym:_END+0) ; ----------------------------------------------------------------------- // Block: 2 Pred: 1 Succ: ----------------------------------------------------------------------- BB:2 (length:2) -- flags = 0x0804 Exit block SP exit adj: [ 7, 0] GTN4(%rsp) :- leave GTN3(%rbp) ; In linear order, BB_prev == BB: 1; BB_next == BB:-1 Predecessors: BB: 1 Successors: none defreach_in : {3-4} live_in : {4} defreach_out: {3-4} live_out : {} live_def : {} live_use : {4} [ 7, 0] GTN4(%rsp) :- leave GTN3(%rbp) ; [ 7, 0] :- ret ; .endp ======================================================================= ======================================================================= ### Assertion failure at line 1366 of ../../be/cg/x8664/cg_convert_x87.cxx: ### Compiler Error in file test2.f90 during Converting x87 stack registers phase: ### x87 stack is inconsistent.

                                                                    • iso_c_binding in fortran
                                                                      dgilmore

                                                                      Thanks for the info.

                                                                      I actually was able to reproduce the problem with the release 4.2.4 compiler, could you check again for me?

                                                                      I suspect that you saw it work with the 4.2.3 build of the compiler, this problem was introduced with the 4.2.4.

                                                                      The problem is exposed with -m32 -march=anyx86 or -march=athlon.

                                                                      BTW, what processor are you using?

                                                                      We just started to look into the problem, so I don't yet have a timeline for a fix.

                                                                      Doug

                                                                        • iso_c_binding in fortran
                                                                          janusw

                                                                          I definitely saw it working with the 4.2.4 release (on a Core2 processor). But when using "-g -r8 -m32 -march=anyx86", it also fails with the 4.2.4 release.

                                                                          The system where I originally observed the failure is an Athlon II X2 240.

                                                                          Thanks for looking into it.

                                                                          Cheers,

                                                                          Janus

                                                                            • iso_c_binding in fortran
                                                                              dgilmore

                                                                              Are you running a 64 bit OS?

                                                                              If so, could you post a message with the contents of /proc/cpuinfo attached?

                                                                              This bug shouldn't be exposed when compiling with -m64.

                                                                              Thanks,

                                                                              Doug

                                                                                • iso_c_binding in fortran
                                                                                  janusw

                                                                                  Yes, I'm running a 64 bit OS (openSUSE 11.2).

                                                                                  /pro/cpuinfo is attached.

                                                                                  When building the compiler, I was following the "INSTALL" document, which recommends to build with:

                                                                                  make all MACHINE_TYPE=i386

                                                                                  Could this be the reason why I get the failure? Should it go away if I leave out "MACHINE_TYPE=i386"?

                                                                                  Thanks,

                                                                                  Janus

                                                                                  processor : 0 vendor_id : AuthenticAMD cpu family : 16 model : 6 model name : AMD Athlon(tm) II X2 240 Processor stepping : 2 cpu MHz : 800.000 cache size : 1024 KB physical id : 0 siblings : 2 core id : 0 cpu cores : 2 apicid : 0 initial apicid : 0 fpu : yes fpu_exception : yes cpuid level : 5 wp : yes flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt bogomips : 5585.60 TLB size : 1024 4K pages clflush size : 64 cache_alignment : 64 address sizes : 48 bits physical, 48 bits virtual power management: ts ttp tm stc 100mhzsteps hwpstate processor : 1 vendor_id : AuthenticAMD cpu family : 16 model : 6 model name : AMD Athlon(tm) II X2 240 Processor stepping : 2 cpu MHz : 800.000 cache size : 1024 KB physical id : 0 siblings : 2 core id : 1 cpu cores : 2 apicid : 1 initial apicid : 1 fpu : yes fpu_exception : yes cpuid level : 5 wp : yes flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nonstop_tsc extd_apicid pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt bogomips : 5586.44 TLB size : 1024 4K pages clflush size : 64 cache_alignment : 64 address sizes : 48 bits physical, 48 bits virtual power management: ts ttp tm stc 100mhzsteps hwpstate

                                                                                    • iso_c_binding in fortran
                                                                                      janusw

                                                                                      In any case, using -m64 as a workaround gets me past the error. But then I see yet another failure: When compiling the two attached modules in separate files via

                                                                                      openf95 -c sourceTypeDefinition.f90 determineSource.f90

                                                                                      I get:

                                                                                      Signal: Segmentation fault in IR->WHIRL Conversion phase.
                                                                                      "determineSource.f90": Error: Signal Segmentation fault in phase IR->WHIRL Conversion -- processing aborted
                                                                                      *** Internal stack backtrace:
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80e8f47]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80e9db1]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80e9b45]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80e9bbc]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80ea411]
                                                                                          [0x55573400]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80ae58b]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80b0137]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x82c2259]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x82bf9a3]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x82cdf85]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x82ce080]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x82ce531]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95() [0x80f5029]
                                                                                          /lib32/libc.so.6(__libc_start_main+0xe6) [0x556ecbd6]
                                                                                          /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95(__gxx_personality_v0+0xf9) [0x804c221]
                                                                                      openf95 INTERNAL ERROR: /opt/x86_open64-4.2.4/lib/gcc-lib/x86_64-open64-linux/4.2.4/mfef95 died due to signal 4

                                                                                       

                                                                                      This happens both with the patched and unpatched 4.2.4 release. (And btw it's the same failure that I recently reported to the PathScale team.)

                                                                                      Thanks for your continued support,

                                                                                      Janus

                                                                                      module sourceTypeDefinition type quelle real, dimension(1:3) :: position = 0. real, dimension(1:3) :: velocity = 0. end type quelle end module module determineSource use sourceTypeDefinition implicit none type(quelle), allocatable, dimension(:) :: TheSource contains subroutine Get_FragmentingSource(numEnsembles,sourceType) integer :: numEnsembles integer, dimension(1:numEnsembles) :: sourceType allocate(TheSource(10)) contains subroutine setParticlesToSources end subroutine end subroutine end module

                                                                                      • iso_c_binding in fortran
                                                                                        mickpont

                                                                                        I've also been trying to use the ISO_C_BINDING module, but without luck.

                                                                                        This routine fails to compile:

                                                                                            SUBROUTINE J10AAFT(W,X)
                                                                                               USE ISO_C_BINDING, ONLY : C_LOC, C_PTR
                                                                                               TYPE (C_PTR), INTENT (OUT)        :: W
                                                                                               REAL (KIND=KIND(0.0D0)), TARGET   :: X
                                                                                               W = C_LOC(X)
                                                                                               RETURN
                                                                                            END SUBROUTINE J10AAFT

                                                                                        giving this error message:

                                                                                        $ openf95 -c ~/try3.f90

                                                                                               W = C_LOC(X)
                                                                                                 ^         
                                                                                        openf95-356 openf95: ERROR J10AAFT, File = try3.f90, Line = 5, Column = 10
                                                                                          Assignment of a Cray pointer expression to a type(C_PTR) variable is not allowed.

                                                                                        It seems that the compiler thinks C_LOC is of type "Cray pointer" rather than type C_PTR.

                                                                                        $ openf95 --version
                                                                                        Open64 Compiler Suite: Version 4.2.4
                                                                                        Built on: 2010-06-28 16:07:57 -0700

                                                                                        Mick Pont

                                                                                • iso_c_binding in fortran
                                                                                  dgilmore

                                                                                  > /pro/cpuinfo is attached.
                                                                                  Thanks!

                                                                                  Our parsing of the model name is broken.  I supplied a patch to address this proproblem.

                                                                                  > When building the compiler, I was following the "INSTALL" document, which recommends to build with:
                                                                                  >
                                                                                  > make all MACHINE_TYPE=i386
                                                                                  >
                                                                                  > Could this be the reason why I get the failure? Should it go away if I leave out "MACHINE_TYPE=i386"?
                                                                                  Actually it won't, since the problem is with the driver, even if you built the compiler proper 64 bits, the driver CPU detection code would "determine" that the processor was 32 bit.  Mumble.

                                                                                  Doug