gcc/testsuite/ChangeLog:
* jit.dg/all-non-failing-tests.h: Update comment about
test-cold-attribute.c.
* jit.dg/test-cold-attribute.c: Use -Oz to fix test.
#undef create_code
#undef verify_code
-/* test-cold-attribute.c: This can't be in the testcases array as it needs
- the `-O2` flag. */
+/* test-cold-attribute.c: This can't be in the testcases array as it needs a
+ specific optimization flag. */
/* test-constants.c */
#define create_code create_code_constants
#define TEST_ESCHEWS_SET_OPTIONS
static void set_options (gcc_jit_context *ctxt, const char *argv0)
{
- // Set "-O2".
- gcc_jit_context_set_int_option(ctxt, GCC_JIT_INT_OPTION_OPTIMIZATION_LEVEL, 2);
+ // Set "-Oz".
+ gcc_jit_context_add_command_line_option (ctxt, "-Oz");
}
#define TEST_COMPILING_TO_FILE