https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97159
--- Comment #3 from Jan Hubicka <hubicka at ucw dot cz> --- Recursion is handled in normal compilation (we analyze the function and while hitting the recursive call we skip the summary). I suppose here the problem is missing LTO and offloading. With LTO lto summaries (that include types) are streamed out while they are turned into non-lto summaries at ltrans time. We need to do similar thing with offload. Honza