xiangaodielian / bullet

Automatically exported from code.google.com/p/bullet
Other
0 stars 0 forks source link

union in btAlignPointer() in btScalar.h causes GCC to internally crash. #615

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
- What steps will reproduce the problem?

I don't really have any specific steps other than the inclusion of btScalar.h 
in my project causes the compiler to crash.

- What is the expected output? What do you see instead?

I'd expect the compiler to not crash :)

Bullet/LinearMath/btScalar.h:533: internal compiler error: Segmentation fault: 
11

- What version of the product are you using? On what operating system?

Bullet 2.80 SP1 revision 2531
Mac OSX Lion, Xcode 3.2.6, GCC 4.2

- Please provide any additional information below.

I'd expect the root of the problem to be down to the compiler, but since GCC 
4.2 is a stable build and distributed in IDE versions that ain't going to 
change (like Xcode 3.2.6), it's probably better for Bullet to work around the 
issue.

Original issue reported on code.google.com by m...@danielsefton.com on 30 Mar 2012 at 6:36

GoogleCodeExporter commented 9 years ago
Can you try to apply attached patch (or copy the attached btScalar.h) and see 
if that fixes the issue?

It could be that unnamed unions causes the crash.

Original comment by erwin.coumans on 30 Mar 2012 at 6:46

Attachments:

GoogleCodeExporter commented 9 years ago
attached btScalar.h

Original comment by erwin.coumans on 30 Mar 2012 at 6:47

Attachments:

GoogleCodeExporter commented 9 years ago
Yep, that fixed it, thanks for the hasty response :)

Original comment by m...@danielsefton.com on 30 Mar 2012 at 7:10

GoogleCodeExporter commented 9 years ago
great, thanks for the report. Fixed in latest trunk:
http://code.google.com/p/bullet/source/detail?r=2536

Original comment by erwin.coumans on 30 Mar 2012 at 7:18