mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-31 16:20:13 +01:00
amd/addrlib: prevent defining regparm differently
Define it in meson, so addrlib won't define it. This is adding back the addrlib original code. Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9668>
This commit is contained in:
parent
59912cd4cf
commit
1d69c0419b
2 changed files with 8 additions and 4 deletions
|
|
@ -87,9 +87,12 @@ typedef int INT;
|
|||
#endif
|
||||
|
||||
#ifndef ADDR_FASTCALL
|
||||
#if defined(__GNUC__) || defined(BRAHMA_ARM)
|
||||
// We don't care about the performance of call instructions in addrlib
|
||||
#define ADDR_FASTCALL
|
||||
#if defined(__GNUC__)
|
||||
#if defined(__i386__) || defined(__amd64__) || defined(__x86_64__)
|
||||
#define ADDR_FASTCALL __attribute__((regparm(0)))
|
||||
#else
|
||||
#define ADDR_FASTCALL
|
||||
#endif
|
||||
#else
|
||||
#define ADDR_FASTCALL __fastcall
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -52,7 +52,8 @@ files_addrlib = files(
|
|||
'src/r800/siaddrlib.h',
|
||||
)
|
||||
|
||||
cpp_args_addrlib = []
|
||||
# Skip the addrlib definition of ADDR_FASTCALL so as not to use regparm.
|
||||
cpp_args_addrlib = ['-DADDR_FASTCALL=']
|
||||
foreach w : ['-Wno-unused-variable', '-Wno-unused-local-typedefs',
|
||||
'-Wno-unused-but-set-variable', '-Wno-maybe-uninitialized']
|
||||
if cpp.has_argument(w)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue