Xcode 3.2.2 and 3.2.3 not supported and may cause errors

Xcode 3.2.2 and 3.2.3 not supported and may cause errors

UPDATE 12/2/2010: The underlying linker issue is fixed by Apple in Xcode 3.2.5. Please upgrade to this version of Xcode.

UPDATE 8/30/2010: This issue has a workaround in the 11.1 Update 7 compiler, posted to Intel Registration center (https://registrationcenter.intel.com). ALL users with Xcode 3.2.2 and above should upgrade to 11.1 Update 7, 11.1.089 or greater.

UPDATE 5/7/2010: Xcode 3.2.2 and Xcode 3.2.3 and ifort are not compatible and can cause incorrect runtime results or segmentation faults. A possible workaround is to add -use-asm option to all compile and ifort link commands (see below). We are continuing to work with Apple to resolve this issue.

READ THE PROBLEM WRITEUP HERE: http://software.intel.com/en-us/articles/intel-fortran-for-mac-os-x-incompatible-with-xcode-322/

The current Intel Compilers 11.1 officially support Mac OS* X 10.6.2 and Xcode* 3.2.1.

Unofficial testing indicates that Mac OS* X 10.6.3 and Xcode* 3.2.1 appear to work together with the compiler, however this configuration is not OFFICIALLY supported at this time.

However, Mac OS* X 10.6.3 and Xcode* 3.2.2 combination with the Intel Compilers v11.1 have at least 1 known critical issue under investigation. At this time we do not recommend upgrading Xcode to 3.2.2 (or later). This version of Xcode includes a new build of gcc/g++ and it's libraries that appear to affect the Fortran runtime library. We will post more information as the investigation continues.

If you are seeing unusual behavior for your previously working applications after the Xcode 3.2.2 please add a reply to this thread. Particularly if you see any Intel C or C++ issues. So far we only have reports from Fortran users.


Ron W. Green, 28 April 2010

31 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Indeed it appears that there are severe problems when usingXcode* 3.2.2 in conjunction with the intel fortrancompiler 11.1. After going fromXcode* 3.2.1 to 3.2.2 I observe segmentation faults after recompilationof the MOLPRO (www.molpro.net) program. The code works flawlessly when compiling on another (otherwise identical) machine, which was not yet updated to version 3.2.2. Compilation on the basis of gfortran workson both machines.Martin Schtz, Regensburg, 4 Mai 2010

I am running OSX 10.6.3 and Xcode 3.2.2. Can we donwload to Xcode 3.2.1 ?
Try this :ifort bugg.f90 -o bugg./bugghere is the result !size(u)= 28size(v)= 28i= 1 u,v= 0.111259634513577-307 0.111259634513577-307i= 2 u,v= 0.452218665183552E-13 0.452218665183552E-13i= 3 u,v= 0.212199580875164-313 0.212199580875164-313i= 4 u,v= 0.116709768504572-311 0.116709768504572-311i= 5 u,v= 0.111259634513577-307 0.111259634513577-307i= 6 u,v= 0.452288054122591E-13 0.452288054122591E-13i= 7 u,v= 0.212199580875164-313 0.212199580875164-313i= 8 u,v= 0.116709768504572-311 0.116709768504572-311i= 9 u,v= 0.278193648195574-308 0.278193648195574-308i=10 u,v= 0.763918562419558-312 0.763918562419558-312i=11 u,v= 0.424399158242461-313 0.424399158242461-313i=12 u,v= 0.212199579788219-313 0.212199579788219-313i=13 u,v= 0.556327880508949-308 0.556327880508949-308i=14 u,v= 0.278253573535859-308 0.278253573535859-308i=15 u,v= 0.224633149715818-313 0.224633149715818-313i=16 u,v= 0.297079410843833-312 0.297079410843833-312i=17 u,v= 0.212199579145934-313 0.212199579145934-313i=18 u,v= 0.116709768531252-311 0.116709768531252-311i=19 u,v= 0.000000000000000E+00 0.000000000000000E+00i=20 u,v= 0.166666666666667E+00 0.166666666666667E+00i=21 u,v= 0.333333333333333E+00 0.333333333333333E+00i=22 u,v= 0.500000000000000E+00 0.500000000000000E+00i=23 u,v= 0.666666666666667E+00 0.666666666666667E+00i=24 u,v= 0.833333333333333E+00 0.833333333333333E+00i=25 u,v= 0.100000000000000E+01 0.100000000000000E+01i=26 u,v= 0.000000000000000E+00 0.000000000000000E+00i=27 u,v= 0.166666666666667E+00 0.166666666666667E+00i=28 u,v= 0.333333333333333E+00 0.333333333333333E+00and here is the program bugg.f90program buggreal(8) :: u(28),v(28)u( 1)= 0.00000000000000000d0u( 2)= 0.16666666666666666d0u( 3)= 0.33333333333333331d0u( 4)= 0.50000000000000000d0u( 5)= 0.66666666666666663d0u( 6)= 0.83333333333333337d0u( 7)= 0.10000000000000000d1u( 8)= 0.00000000000000000d0u( 9)= 0.16666666666666666d0u( 10)= 0.33333333333333331d0u( 11)= 0.50000000000000000d0u( 12)= 0.66666666666666663d0u( 13)= 0.83333333333333337d0u( 14)= 0.00000000000000000d0u( 15)= 0.16666666666666666d0u( 16)= 0.33333333333333331d0u( 17)= 0.50000000000000000d0u( 18)= 0.66666666666666663d0u( 19)= 0.00000000000000000d0u( 20)= 0.16666666666666666d0u( 21)= 0.33333333333333331d0u( 22)= 0.50000000000000000d0u( 23)= 0.00000000000000000d0u( 24)= 0.16666666666666666d0u( 25)= 0.33333333333333331d0u( 26)= 0.00000000000000000d0u( 27)= 0.16666666666666666d0u( 28)= 0.00000000000000000d0!v( 1)= 0.00000000000000000d0v( 2)= 0.00000000000000000d0v( 3)= 0.00000000000000000d0v( 4)= 0.00000000000000000d0v( 5)= 0.00000000000000000d0v( 6)= 0.00000000000000000d0v( 7)= 0.00000000000000000d0v( 8)= 0.16666666666666666d0v( 9)= 0.16666666666666666d0v( 10)= 0.16666666666666666d0v( 11)= 0.16666666666666666d0v( 12)= 0.16666666666666666d0v( 13)= 0.16666666666666666d0v( 14)= 0.33333333333333331d0v( 15)= 0.33333333333333331d0v( 16)= 0.33333333333333331d0v( 17)= 0.33333333333333331d0v( 18)= 0.33333333333333331d0v( 19)= 0.50000000000000000d0v( 20)= 0.50000000000000000d0v( 21)= 0.50000000000000000d0v( 22)= 0.50000000000000000d0v( 23)= 0.66666666666666663d0v( 24)= 0.66666666666666663d0v( 25)= 0.66666666666666663d0v( 26)= 0.83333333333333337d0v( 27)= 0.83333333333333337d0v( 28)= 0.10000000000000000d1write(*,'("size(u)=",i3)')size(u)write(*,'("size(v)=",i3)')size(v)do i=1,28 write(*,'("i=",i2,3x,"u,v=",2(e22.15,1x))')i,u(i),v(i)enddo end program bugg

Can we donwload to Xcode 3.2.1 ?

I have also been having trouble with OSX 10.6.3, Xcode 3.2.2, and ifort 11.1.088.

Xcode 3.2.2, specifically the linker 'ld' that came with this and is used by the Intel compiler, has broken the Intel Fortran compiler. We are still investigating and trying to determine how to work with this new linker.

In the meantime, yes, the fix is to go back to Xcode 3.2.1. Reinstalling this puts the older linker and header files on the system, overwriting the ones put on by Xcode 3.2.2.

You get the older Xcode from developer.apple.com. You will need an account with them, but the accounts are free.


2010 May 7:

A workaround for the incompatibility of Xcode 3.2.2 and ifort has been found: Please add compiler option -use_asm to all compilation and ifort link commands.

ifort -use_asm ...rest of your options...


Do you mean -use-asm ?

yes, although both work it is probably best to use the documented option.

The work-around does not work in combination with other options:
ifort -static-intel -openmp -use-asm test.fld: warning: for symbol _message_catalog tentative definition of size 16 from /usr/bin/ifort-11.1-base/lib/libiomp5.a(iomp.o) is being replaced by a real definition of size 8 from /usr/bin/ifort-11.1-base/lib/libifcoremt.a(for_diags_intel.o)ld: warning: _message_catalog has different visibility (default) in /usr/bin/ifort-11.1-base/lib/libifcoremt.a(for_diags_intel.o) and (hidden) in /usr/bin/ifort-11.1-base/lib/libiomp5.a(iomp.o)ld: duplicate symbol ___intel_cpu_indicator$non_lazy_pointer in a.out and a.out

To reinstall install Xcode 3.2.1 find your original Snow Leopard 10.6.0 DVD, the installer is in one of the folders.

You can also download it from the Mac Dev Center. Click on Developer Downloads > Developer Tools, and search for Xcode 3.2.1.
After reinstalling Xcode, you should reinstall Intel Fortran to ensure it works correctly with all of the libraries.


I have issues with a mixed fortran/C program. The error occurs in a C function, while the main program is fortran, if the code is compiled with -O2 or -O3. The symptom is the following error message.

malloc: *** mmap(size=9223372036854775808) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug

The broken malloc is one in a series of malloc commands, and while the error insinuates that I try to allocate around 9EB, I am positive that I only request 1*sizeof(double) bytes. However, the constant that is guaranteed to be "1" is optimized out by the compiler with -O2 or -O3.

Funnily enough the error also disappears, if I insert printf("\n") statements before and after each malloc command in the sequence.

The problem goes away if I use the -use-asm in all icc and ifort commands. I could not yet downgrade to Xcode 3.2.1. If I can provide any other information, please let me know.



We are aware of the problem with constant addresses in Fortran, this is the first report on our C/C++ compiler. I have the team look into this for C/C++. I though it odd that only Fortran would be impacted.


now that I think about it, it probably is not surprising that the C++ code is affected. If Fortran is your main, it can be corrupting the memory space for the entire application, including the C code. Does your application stay in the C code, or are you calling/returning to Fortran in between the mallocs()? The Fortran can be blasting the value in the constant "1" in between calls to the C code.

If you stay in the C code for these mallocs without returning, then I have some investigation to do.


Is this an Xcode 3.2.2 problem, or something else? A simple program generates an uninitialized variable run time error:

program test1
   integer j, k
   print *, 'Input j?'
   read (*,*) j
   if (j < 10) k = 1
   k = k + 1
end program test1

With ifort 11.1 Update 4 and Mac OS 10.5.8 I get the expected run time message and a traceback:

mac56:~/bugs/ifort/traceback 62> ifort -check uninit -traceback undefined.f90
mac56:~/bugs/ifort/traceback 63> ./a.out 
 Input j?
forrtl: severe (193): Run-Time Check Failure. The variable 'test1_$K' is
   being used without being defined
Image              PC                Routine            Line        Source
a.out              0000000100073C9C  Unknown               Unknown  Unknown
a.out              00000001000727D4  Unknown               Unknown  Unknown
a.out              000000010004A147  Unknown               Unknown  Unknown
a.out              000000010001B3EA  Unknown               Unknown  Unknown
a.out              000000010001BE98  Unknown               Unknown  Unknown
a.out              000000010000131A  _MAIN__                     6  undefined.f90
a.out              000000010000123C  Unknown               Unknown  Unknown
a.out              00000001000011D4  Unknown               Unknown  Unknown

With ifort Update 6 and Mac OS 10.6.3 I get a generic runtime message, and no traceback. I tried -use_asm here, but it did not make any difference:

mac78:~/bugs/ifort/traceback 167> ifort -use_asm -check uninit 
   -traceback undefined.f90
mac78:~/bugs/ifort/traceback 168> ./a.out 
 Input j?
forrtl: error (76): Abort trap signal

Additional version info for Update 4, OS 10.5.8:

mac56:~/bugs/ifort/traceback 67> ifort -V
Intel Fortran Intel 64 Compiler Professional for applications
   running on Intel 64, Version 11.1    Build 20091130 Package ID:
Copyright (C) 1985-2009 Intel Corporation.  All rights reserved.

mac56:~/bugs/ifort/traceback 68> uname -v
Darwin Kernel Version 9.8.0: Wed Jul 15 16:55:01 PDT 2009;

mac56:~/bugs/ifort/traceback 69> otool -L a.out
       (compatibility version 1.0.0, current version 1.0.0)
       (compatibility version 1.0.0, current version 292.4.0)
       (compatibility version 1.0.0, current version 111.1.5)

Additional version info for Update 6, OS 10.6.3:

mac78:~/bugs/ifort/traceback 171> ifort -V
Intel Fortran Intel 64 Compiler Professional for
   applications running on Intel 64, Version 11.1
   Build 20100401 Package ID: m_cprof_p_11.1.088
Copyright (C) 1985-2010 Intel Corporation.  All rights reserved.

mac78:~/bugs/ifort/traceback 172> uname -v
Darwin Kernel Version 10.3.0: Fri Feb 26 11:58:09 PST 2010;

mac78:~/bugs/ifort/traceback 173> otool -L a.out
      (compatibility version 1.0.0, current version 1.0.0)
      (compatibility version 1.0.0, current version 315.0.0)
      (compatibility version 1.0.0, current version 125.0.1)

Correction. I wrote:.. "With ifort Update 6 and Mac OS 10.6.3 I get ...".But I do not actually know the OS minor rev number. It might just be 10.6.0. The closest I can come is the Darwin kernel version number,10.3.0..--Dave

Let me be clear: do not use Xcode 3.2.2 and Intel Fortran. They are currently not compatible. It is independent of the Mac OS version. The linker released with Xcode 3.2.2 is not handling the object files created by Intel Fortran (all versions) correctly.

We have a workaround that changes our object file format. This will work around the linker change. We will have an update compiler for 11.1 with this fix in the coming weeks and will post this compiler to registrationcenter.intel.com.

Ron,.I understand your warning perfectly. My problem is that I do not have a clue as to what my Xcode version is in either of the two cases above, thus the reason for my original question..How do I find the Xcode version number? I can not find this component anywhere -- Applications, man Xcode, or which Xcode. The version info that I gave above does not mention Xcode, and is otherwise incomprehensible to me. I work on a large network of remotely and somewhat anonymously managed computers. I have no access to or knowledge of an installation disk. Sorry if this is a Mac idiot question. Please assist..--Dave

Via the Mac Desktop GUI, starting Xcode displays the version otherwise use the Apple launchbar via feft-click the Xcode GUI to set the focus of the launchbar to Xcode and then select Xcode > About Xcode.

In the absence of the Xcode GUI, version information is available in the file: /Developer/Applications/Xcode.app/Contents/version.plist

cat the file and look for the value appearing after CFBundleShortVersionString.

For example, for Xcode 3.1.4 the file contains:


The linker version is also shown in the Knowledge Base article on this issue here: http://software.intel.com/en-us/articles/intel-fortran-for-mac-os-x-incompatible-with-xcode-322/

Ken,.Thank you very much, the direct file address got the Xcode version number for me. I was not able to get the version number with either of the GUI methods because I have only command line access to the processor of interest.

mac78:~ 7> cat /Developer/Applications/Xcode.app/Contents/version.plist
<?xml version="1.0" encoding="UTF-8"?>


I confirmed that I had Xcode version 3.2.2 on this processor, thus my original symptom is indeed just the Xcode 3.2.2 problem..Thanks to you and Ron for your help..--Dave


the fortran main program calls the C subroutine. The constant "1" is defined in the C preprocessor and stored in a variable

#define CONST 1
int var;
var = CONST;

(might actually become a real variable in a later version) and later:
ptr = (double *)malloc(var * sizeof(double));

causes the malloc problem, unless I insert a printf(""); before it.

The malloc problem appears, before the execution returns to the fortran part of the code. No fortran code is called from C. However, the initial C subroutine calls several C functions spread over different source code files (and thus over different .o object files).


We just setup a 10.6.3 test desktop, and run in compile/link problems with Intel fortran.
Is there an ETA on when Intel will release a 3.2.2 compatible version, so we can plan for 10.6 deployment ?

A fix is targeted for the next 11.1 compiler update, tendatively scheduled for mid-to-late August. We tend to do updates roughly every 3 months.


Hey Ronald, I too would like to know the next 11.1 update.. any news on one? should be around that time..

Create perfect work schedules using Fendza employee scheduling software..

A fix is in the 11.1 Update 7 compiler, 11.1.089, which is posted to Intel Registration Center, https://registrationcenter.intel.com.

This compiler was posted late last week and activated.


Thanks for the info, Ron. To be clear, is this 11.1.089 okay to use with Xcode 3.2.3 as well as Xcode 3.2.2? The System Requirements section of the 11.1.089 release notes PDF seems to point to Xcode 3.2.2 as the most recent version with which you're compatible.Kind regards,Todd

When Apple releases an Xcode version we have to play catch up, so the documentation an our QA and Validation teams lag a little. To date, no issues have been found with Xcode 3.2.3. However "officially" we are only supporting 3.2.2.
I don't know of any issues with 3.2.3, I've been using it myself for a while.

That is correct - there is a bug currently with C/C++ switch statements. There is a fix in the works for the next update release. Use -use-asm to work around the problem until it is fixed.


Leave a Comment

Please sign in to add a comment. Not a member? Join today