aboutsummaryrefslogtreecommitdiff
path: root/gcc/jit/jit-playback.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/jit/jit-playback.cc')
-rw-r--r--gcc/jit/jit-playback.cc12
1 files changed, 11 insertions, 1 deletions
diff --git a/gcc/jit/jit-playback.cc b/gcc/jit/jit-playback.cc
index 142a8db..e8887e9 100644
--- a/gcc/jit/jit-playback.cc
+++ b/gcc/jit/jit-playback.cc
@@ -572,7 +572,8 @@ new_function (location *loc,
std::string>> &string_attributes,
const std::vector<std::pair<gcc_jit_fn_attribute,
std::vector<int>>>
- &int_array_attributes)
+ &int_array_attributes,
+ bool is_target_builtin)
{
int i;
param *param;
@@ -608,6 +609,15 @@ new_function (location *loc,
tree fn_attributes = NULL_TREE;
+ if (is_target_builtin)
+ {
+ tree *decl = target_builtins.get (name);
+ if (decl != NULL)
+ fndecl = *decl;
+ else
+ add_error (loc, "cannot find target builtin %s", name);
+ }
+
if (builtin_id)
{
gcc_assert (loc == NULL);