mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-30 08:41:15 +00:00
Kernel: Wrap x86 assembly behind ARCH(...)
in Syscall.h
Unlike GCC, Clang parses assembly eagerly, and immediately rejects inline assembly that's not for the right architecture.
This commit is contained in:
parent
9b90f1fed5
commit
294cb3cef4
Notes:
sideshowbarker
2024-07-17 23:11:13 +09:00
Author: https://github.com/BertalanD Commit: https://github.com/SerenityOS/serenity/commit/294cb3cef48 Pull-request: https://github.com/SerenityOS/serenity/pull/11164
|
@ -489,6 +489,7 @@ struct SC_statvfs_params {
|
||||||
void initialize();
|
void initialize();
|
||||||
int sync();
|
int sync();
|
||||||
|
|
||||||
|
# if ARCH(I386) || ARCH(X86_64)
|
||||||
inline uintptr_t invoke(Function function)
|
inline uintptr_t invoke(Function function)
|
||||||
{
|
{
|
||||||
uintptr_t result;
|
uintptr_t result;
|
||||||
|
@ -542,6 +543,7 @@ inline uintptr_t invoke(Function function, T1 arg1, T2 arg2, T3 arg3, T4 arg4)
|
||||||
: "memory");
|
: "memory");
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue