[LLVMbugs] [Bug 11655] clang alignment mismatch with gcc for ppc architecture

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Jan 17 01:20:34 PST 2012


http://llvm.org/bugs/show_bug.cgi?id=11655

mackyle at gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
            Version|2.9                         |3.0
         Resolution|WORKSFORME                  |

--- Comment #5 from mackyle at gmail.com 2012-01-17 03:20:34 CST ---
When run against the released clang 3.0:

$ clang-mp-3.0 --version
clang-mp-3.0(46723) malloc: *** error for object 0x14d2674: Non-aligned pointer
being freed
*** set a breakpoint in malloc_error_break to debug
clang-mp-3.0(46723) malloc: *** error for object 0x14d2674: Non-aligned pointer
being freed
*** set a breakpoint in malloc_error_break to debug
clang-mp-3.0(46723) malloc: *** error for object 0x14d2674: Non-aligned pointer
being freed
*** set a breakpoint in malloc_error_break to debug
clang version 3.0 (tags/RELEASE_30/final)
Target: i386-apple-darwin9.8.0
Thread model: posix

The output of example.c when compiled for -arch ppc (powerpc-apple-darwin9) is
still:

offsetof(struct badsize,f4) = 24
  sizeof(struct badsize)    = 32

but it should be:

offsetof(struct badsize,f4) = 20
  sizeof(struct badsize)    = 28

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list