mirror of
https://github.com/amadvance/snapraid.git
synced 2026-12-04 05:40:14 -05:00
Align critical loops to 64 bytes using __align_loops attribute
This commit is contained in:
parent
91761768a0
commit
ec71f519b0
6 changed files with 25 additions and 0 deletions
|
|
@ -70,6 +70,22 @@
|
|||
#define __noreturn __attribute__((noreturn))
|
||||
#endif
|
||||
|
||||
#ifndef __aligned
|
||||
#if defined(__GNUC__) || defined(__clang__)
|
||||
#define __aligned(n) __attribute__((aligned(n)))
|
||||
#else
|
||||
#define __aligned(n)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef __aligned_loops
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#define __aligned_loops(n) __attribute__((optimize("align-loops=" #n)))
|
||||
#else
|
||||
#define __aligned_loops(n)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Architecture for inline assembly.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue