You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kudu.apache.org by "Grant Henke (Jira)" <ji...@apache.org> on 2020/06/02 20:28:00 UTC
[jira] [Updated] (KUDU-2094) GCC 7.1 complains about alignment of
Counter
[ https://issues.apache.org/jira/browse/KUDU-2094?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Grant Henke updated KUDU-2094:
------------------------------
Component/s: build
> GCC 7.1 complains about alignment of Counter
> --------------------------------------------
>
> Key: KUDU-2094
> URL: https://issues.apache.org/jira/browse/KUDU-2094
> Project: Kudu
> Issue Type: Bug
> Components: build
> Reporter: Tim Armstrong
> Priority: Minor
>
> I found this when building the kudu/util subtree in Impala with gcc 7.1.
> In a few places, e.g. metrics.h, the compiler complains that the alignment required by Counter is less than the alignment guaranteed by new.
> {code}
> m = new Counter(proto);
> {code}
> I worked around this by setting -faligned-new, which was added recently to GCC and is enabled by default with C++17. The setting ensures that new allocates memory with the alignment required by the data type.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)