gcc/
* multiple_target.c (create_dispatcher_calls): Add target check
on ifunc.
(create_target_clone): Change assembler name for versioned declarations.
gcc/testsuite/
* g++.dg/ext/mvc4.C: Add dg-require-ifunc condition.
* gcc.target/i386/mvc5.c: Ditto.
* gcc.target/i386/mvc7.c: Add dg-require-ifunc condition and checks on
resolver.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@229706
138bc75d-0d04-0410-961f-
82ee72b054a4
+2015-11-03 Evgeny Stupachenko <evstupac@gmail.com>
+
+ * multiple_target.c (create_dispatcher_calls): Add target check
+ on ifunc.
+ (create_target_clone): Change assembler name for versioned declarations.
+
2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
Chung-Lin Tang <cltang@codesourcery.com>
|| !DECL_FUNCTION_VERSIONED (decl))
continue;
+ if (!targetm.has_ifunc_p ())
+ {
+ error_at (gimple_location (call),
+ "the call requires ifunc, which is not"
+ " supported by this target");
+ break;
+ }
e_next = e->next_caller;
idecl = targetm.get_function_versions_dispatcher (decl);
if (!idecl)
{
error_at (gimple_location (call),
"default target_clones attribute was not set");
+ break;
}
inode = cgraph_node::get (idecl);
gcc_assert (inode);
{
tree new_decl = copy_node (node->decl);
new_node = cgraph_node::get_create (new_decl);
+ /* Generate a new name for the new version. */
+ symtab->change_decl_assembler_name (new_node->decl,
+ clone_function_name (node->decl,
+ name));
}
return new_node;
}
+2015-11-03 Evgeny Stupachenko <evstupac@gmail.com>
+
+ * g++.dg/ext/mvc4.C: Add dg-require-ifunc condition.
+ * gcc.target/i386/mvc5.c: Ditto.
+ * gcc.target/i386/mvc7.c: Add dg-require-ifunc condition and checks on
+ resolver.
+
2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
* c-c++-common/goacc-gomp/nesting-fail-1.c: Move "atomic" tests
/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
+/* { dg-require-ifunc "" } */
/* { dg-options "-mavx" } */
#include <immintrin.h>
/* { dg-do compile } */
+/* { dg-require-ifunc "" } */
/* { dg-options "-fno-inline" } */
/* { dg-final { scan-assembler-times "foo.ifunc" 6 } } */
/* { dg-do compile } */
+/* { dg-require-ifunc "" } */
+/* { dg-final { scan-assembler "foo.resolver" } } */
+/* { dg-final { scan-assembler "avx" } } */
+/* { dg-final { scan-assembler "slm" } } */
/* { dg-final { scan-assembler-times "foo.ifunc" 4 } } */
__attribute__((target_clones("avx","default","arch=slm","arch=core-avx2")))