https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66594
Bug ID: 66594 Summary: jitted code should use -mtune=native Product: gcc Version: 6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: jit Assignee: dmalcolm at gcc dot gnu.org Reporter: dmalcolm at gcc dot gnu.org Target Milestone: --- We should probably default to -mtune=native when building code in-memory (but probably to -mtune=generic when compiling to disk?). Perhaps an option, or maybe expose these options directly? Note to self: * I see in gcc.c: /* As special support for cross compilers we read -mtune=native as -mtune=generic. With native compilers we won't see the -mtune=native, as it was changed by the driver. */ if (!strcmp (opts->x_ix86_tune_string, "native")) { opts->x_ix86_tune_string = "generic"; } hence we need to somehow run the *driver* logic for -mtune=native. Note that that logic can be a no-op under non-bootstrapped builds; see bug 66593.