Bug 28628 - Not forcing alignment of arrays in structs with -fsection-anchors
Summary: Not forcing alignment of arrays in structs with -fsection-anchors
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: 4.2.0
: P3 enhancement
Target Milestone: 6.0
Assignee: Jan Hubicka
URL:
Keywords: missed-optimization
Depends on:
Blocks:
 
Reported: 2006-08-07 07:07 UTC by Dorit Naishlos
Modified: 2015-03-09 01:36 UTC (History)
2 users (show)

See Also:
Host: powerpc-linux
Target: powerpc-linux
Build: powerpc-linux
Known to work:
Known to fail:
Last reconfirmed: 2006-08-07 07:41:54


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dorit Naishlos 2006-08-07 07:07:20 UTC
Since the fix to PR27770, we now miss opportunities to align some arrays when -fsection-anchors is enabled. The patch for PR27770 increases the alignment of (global) arrays only. We have a few testcases though (e.g. section-anchors-vect-69.c) that have global structs that contain fields that are arrays. Aligning the beginning of these structs can sometime align one/some of their array fields. Since the new function cgraph_increase_alignment does notattempt to do that, we have cases that will be vectorized less efficiently. To solve this we need to extend the optimization to align global structs that have array fields that could become aligned as a result.
Comment 1 Andrew Pinski 2006-08-07 07:41:54 UTC
Confirmed.
Comment 2 Jan Hubicka 2015-03-09 01:36:11 UTC
This is something we can solve next stage1 by breaking up the pass queue and doing all RTL generation after tree optimization.