8220283: ZGC fails to build on GCC 4.4.7: ATTRIBUTE_ALIGNED compatibility issue
Reviewed-by: shade, kbarrett
This commit is contained in:
parent
5250aaafdb
commit
cafb914cca
@ -269,6 +269,9 @@ inline int wcslen(const jchar* x) { return wcslen((const wchar_t*)x); }
|
||||
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55382 and
|
||||
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53017
|
||||
//
|
||||
#define ATTRIBUTE_ALIGNED(x) __attribute__((aligned(x+0)))
|
||||
// GCC versions older than 4.6.4 would fail even with "+0", and needs additional
|
||||
// cast to typeof(x) to work around the similar bug.
|
||||
//
|
||||
#define ATTRIBUTE_ALIGNED(x) __attribute__((aligned((typeof(x))x+0)))
|
||||
|
||||
#endif // SHARE_UTILITIES_GLOBALDEFINITIONS_GCC_HPP
|
||||
|
Loading…
x
Reference in New Issue
Block a user