xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* Clang tools build
@ 2016-02-12 15:25 Andrew Cooper
  2016-02-12 16:04 ` Jan Beulich
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Cooper @ 2016-02-12 15:25 UTC (permalink / raw)
  To: Xen-devel List, Jan Beulich, Ian Campbell, Ian Jackson, Wei Liu

Hello,

Now that Clang 3.5 can build the hypervisor, I was just preparing a
patch to README, and encountered this:

In file included from xc_altp2m.c:23:
In file included from ./xc_private.h:35:
In file included from ./include/xenctrl.h:53:
/local/xen.git/tools/libxc/../../tools/include/xen/foreign/x86_64.h:203:47:
error: 'aligned' attribute ignored when parsing type
[-Werror,-Wignored-attributes]
    __align8__ uint64_t evtchn_pending[sizeof(__align8__ uint64_t) * 8];
                                              ^~~~~~~~~~
/local/xen.git/tools/libxc/../../tools/include/xen/foreign/x86_64.h:13:36:
note: expanded from macro '__align8__'
# define __align8__ __attribute__((aligned (8)))
                                   ^~~~~~~~~~~
/local/xen.git/tools/libxc/../../tools/include/xen/foreign/x86_64.h:204:44:
error: 'aligned' attribute ignored when parsing type
[-Werror,-Wignored-attributes]
    __align8__ uint64_t evtchn_mask[sizeof(__align8__ uint64_t) * 8];
                                           ^~~~~~~~~~
/local/xen.git/tools/libxc/../../tools/include/xen/foreign/x86_64.h:13:36:
note: expanded from macro '__align8__'
# define __align8__ __attribute__((aligned (8)))
                                   ^~~~~~~~~~~
2 errors generated.

In this case, Clang is complaining that the alignment attribute is wrong
for uint64_t.  This is correct for 64bit compilations, but wrong for
32bit.  On the other hand, I am not sure whether it is sensible to do a
blanket disable of -Wignored-attributes.

Thoughts?

~Andrew

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-02-12 16:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-12 15:25 Clang tools build Andrew Cooper
2016-02-12 16:04 ` Jan Beulich
2016-02-12 16:20   ` Andrew Cooper

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).