This is an archive of the discontinued LLVM Phabricator instance.

XCore target: symbols in the .cp.rodata section must be 4 byte aligned
AbandonedPublic

Authored by robertlytton on Aug 1 2014, 6:26 AM.

Details

Reviewers
friedgold
Summary

For the xcore target, the abi requires us to place global constant data with c linkage in the .cp,rodata section.
All symbols in this section require 4 byte alignment.

  • Please review the following from a clang perspective *

Please note the patch to EmitGlobalVarDefinition which now only calls setAlignment if it has not already been set.

Diff Detail

Event Timeline

robertlytton retitled this revision from to XCore target: symbols in the .cp.rodata section must be 4 byte aligned.
robertlytton updated this object.Aug 1 2014, 6:30 AM
robertlytton added a reviewer: friedgold.
robertlytton added a subscriber: Unknown Object (MLST).Aug 1 2014, 7:40 AM
friedgold requested changes to this revision.Aug 28 2014, 3:59 AM
friedgold edited edge metadata.

I think this should set the align to the maximum of the decl alignment and 4 so that, for example, if the user requests a minimum alignment using the aligned attribute it will be respected.

This revision now requires changes to proceed.Aug 28 2014, 3:59 AM
robertlytton abandoned this revision.Nov 25 2014, 10:29 AM