View Issue Details

IDProjectCategoryView StatusLast Update
0031696FPCCompilerpublic2018-10-21 22:52
ReporterKarl-Michael Schindler Assigned ToJonas Maebe  
Status closedResolutionno change required 
PlatformdarwinOSMac OS X 
Product Version3.0.2 
Summary0031696: Many linker warnings after update to Xcode 8.3 about not aligned pointer address
DescriptionCompiling test.pas
Assembling (pipe) test.s
Linking test
ld: warning: pointer not aligned at address 0x1000218CF (_RTTI_$SYSTEM_$$_openchararray + 31 from /sw/lib/fpc/3.0.2/units/x86_64-darwin/rtl/system.o)

and many more.

The program works, but the warnings are a nuisance.

Rebuilding fpc from sources did not fix it, 3.0.2 or 3.1.1.

Also the same for i386-darwin.

I also tried to enforce alignment during rebuilding fpc with -Oa=16, but it did not fix it.

The compiler D seems to have the same issue:
TagsNo tags attached.
Fixed in Revision
Attached Files


Jonas Maebe

2017-04-22 13:13

manager   ~0099764

x86 perfectly supports unaligned pointers. I don't understand the point of the warning. We pack the RTTI data on purpose so it takes up less space.

Karl-Michael Schindler

2017-04-22 13:28

reporter   ~0099766

Last edited: 2017-04-22 14:52

View 2 revisions

That means that passing -w (no warnings) to the linker is the only option?
Is there any chance to revert this through a bug report to Apple?

update to Xcode 8.3.2 (ld64-278.4) did not change this issue.

Jonas Maebe

2017-04-22 15:44

manager   ~0099778

> That means that passing -w (no warnings) to the linker is the only option?

I don't know. Maybe there is a specific option to only switch off this warning.

> Is there any chance to revert this through a bug report to Apple?

You can always try. At the very least, they will probably explain why it was added.

Karl-Michael Schindler

2017-10-01 21:23

reporter   ~0103141

The warning seems to have gone with Xcode9 (ld64-302.3). However, I had switched off the warnings and how can i know that the switch on was successful. Can someone actually confirm that the warning goes away by updating to Xcode9?

Jonas Maebe

2018-10-21 22:08

manager   ~0111507

These warnings indeed no longer seem to show up in current Xcode versions.

Karl-Michael Schindler

2018-10-21 22:51

reporter   ~0111509

Thanks to everyone.

Issue History

Date Modified Username Field Change
2017-04-22 13:06 Karl-Michael Schindler New Issue
2017-04-22 13:13 Jonas Maebe Note Added: 0099764
2017-04-22 13:28 Karl-Michael Schindler Note Added: 0099766
2017-04-22 14:52 Karl-Michael Schindler Note Edited: 0099766 View Revisions
2017-04-22 15:44 Jonas Maebe Note Added: 0099778
2017-10-01 21:23 Karl-Michael Schindler Note Added: 0103141
2018-10-21 22:08 Jonas Maebe Note Added: 0111507
2018-10-21 22:08 Jonas Maebe Status new => resolved
2018-10-21 22:08 Jonas Maebe Resolution open => no change required
2018-10-21 22:08 Jonas Maebe Assigned To => Jonas Maebe
2018-10-21 22:51 Karl-Michael Schindler Note Added: 0111509
2018-10-21 22:51 Karl-Michael Schindler Status resolved => closed