[llvm-bugs] [Bug 48489] New: __builtin___clear_cache() has a different prototype than GCC
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Dec 11 12:44:25 PST 2020
https://bugs.llvm.org/show_bug.cgi?id=48489
Bug ID: 48489
Summary: __builtin___clear_cache() has a different prototype
than GCC
Product: clang
Version: unspecified
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P
Component: C
Assignee: unassignedclangbugs at nondot.org
Reporter: alx.manpages at gmail.com
CC: blitzrakete at gmail.com, dgregor at apple.com,
erik.pilkington at gmail.com, llvm-bugs at lists.llvm.org,
richard-llvm at metafoo.co.uk
GCC provides:
void __builtin___clear_cache(void *begin, void *end);
See: https://gcc.gnu.org/onlinedocs/gcc/Other-Builtins.html
Clang provides:
void __builtin___clear_cache(char *begin, char *end);
I think GCC used char *' in the past, and moved to 'void *', but I'm not sure
about this. Please, use the same prototype that GCC uses, for compatibility
reasons.
I don't know much about internals of Clang/LLVM, but the only source I could
find that defines the types for the prototype is:
https://github.com/llvm/llvm-project/blob/7faf62a80bfc3a9dfe34133681fcc31f8e8d658b/clang/include/clang/Basic/Builtins.def#L583
If you can confirm that, or tell me which other sources need to be modified,
I'll be happy to submit a patch.
And a reminder to myself when this bug is closed: Update cacheflush(2) manual
page.
Related linux-man@ thread:
https://lore.kernel.org/linux-man/747d56e0-c102-ab40-add4-530a48a43a4d@gmx.de/T/#t
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20201211/e52db4ca/attachment.html>
More information about the llvm-bugs
mailing list