aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vect-patterns.cc
diff options
context:
space:
mode:
authorIain Buclaw <ibuclaw@gdcproject.org>2022-06-11 12:40:00 +0200
committerIain Buclaw <ibuclaw@gdcproject.org>2022-06-13 16:37:13 +0200
commit77718f38f896191e39b1e14c66ed990f0fff391b (patch)
tree12501410623ab6c27871a8584af8d38f9b7d0928 /gcc/tree-vect-patterns.cc
parentf8baf4004ef965ce7a9edf6d2f5eb99adb15803a (diff)
downloadgcc-77718f38f896191e39b1e14c66ed990f0fff391b.zip
gcc-77718f38f896191e39b1e14c66ed990f0fff391b.tar.gz
gcc-77718f38f896191e39b1e14c66ed990f0fff391b.tar.bz2
d: Match function declarations of gcc built-ins from any module.
Declarations of recognised gcc built-in functions are now matched from any module. Previously, only the `core.stdc' package was scanned. In addition to matching of the symbol, any user-applied `@attributes' or `pragma(mangle)' name will be applied to the built-in decl as well. Because there would now be no control over where built-in declarations are coming from, the warning option `-Wbuiltin-declaration-mismatch' has been implemented in the D front-end too. gcc/d/ChangeLog: * d-builtins.cc: Include builtins.h. (gcc_builtins_libfuncs): Remove. (strip_type_modifiers): New function. (matches_builtin_type): New function. (covariant_with_builtin_type_p): New function. (maybe_set_builtin_1): Set front-end built-in if identifier matches gcc built-in name. Apply user-specified attributes and assembler name overrides to the built-in. Warn about built-in declaration mismatches. (d_builtin_function): Set IDENTIFIER_DECL_TREE of built-in functions. * d-compiler.cc (Compiler::onParseModule): Scan all modules for any identifiers that match built-in function names. * lang.opt (Wbuiltin-declaration-mismatch): New option. gcc/testsuite/ChangeLog: * gdc.dg/Wbuiltin_declaration_mismatch.d: New test. * gdc.dg/builtins.d: New test.
Diffstat (limited to 'gcc/tree-vect-patterns.cc')
0 files changed, 0 insertions, 0 deletions