some more testcases I had lying around here
[cparser] / driver / firm_cmdline.c
index c7f563b..d78dc09 100644 (file)
@@ -13,7 +13,7 @@
 #include <libfirm/be.h>
 
 #ifdef _WIN32
-#define DEFAULT_OS OS_SUPPORT_WIN32
+#define DEFAULT_OS OS_SUPPORT_MINGW
 #else
 #define DEFAULT_OS OS_SUPPORT_LINUX
 #endif
@@ -26,8 +26,8 @@ struct a_firm_opt firm_opt = {
   /* reassoc         = */ TRUE,
   /* cse             = */ TRUE,
   /* control_flow    = */ TRUE,
-  /* code_place      = */ TRUE,
-  /* gvn_pre         = */ FALSE,       /* currently buggy */
+  /* gcse            = */ TRUE,
+  /* gvn_pre         = */ FALSE,
   /* cond_eval       = */ FALSE,
   /* if_conversion   = */ FALSE,
   /* func_calls      = */ TRUE,
@@ -128,8 +128,8 @@ static const struct params {
   { X("no-const-fold"),          &firm_opt.const_folding,    0, "firm: disable constant folding" },
   { X("control_flow"),           &firm_opt.control_flow,     1, "firm: enable control flow optimization" },
   { X("no-control-flow"),        &firm_opt.control_flow,     0, "firm: disable control flow optimization" },
-  { X("code-place"),             &firm_opt.code_place,       1, "firm: enable GCSE and code placement" },
-  { X("no-code-place"),          &firm_opt.code_place,       0, "firm: disable GCSE and code placement" },
+  { X("gcse"),                   &firm_opt.gcse,             1, "firm: enable global common subexpression elimination" },
+  { X("no-gcse"),                &firm_opt.gcse,             0, "firm: disable global common subexpression elimination" },
   { X("gvn-pre"),                &firm_opt.gvn_pre,          1, "firm: enable GVN partial redundancy elimination" },
   { X("no-gvn-pre"),             &firm_opt.gvn_pre,          0, "firm: disable GVN partial redundancy elimination" },
   { X("cond-eval"),              &firm_opt.cond_eval,        1, "firm: enable partial condition evaluation optimization" },
@@ -245,7 +245,7 @@ static const struct params {
   { X("stat-pattern"),           &firm_dump.stat_pattern,    1, "misc: Firm statistic calculates most used pattern" },
   { X("stat-dag"),               &firm_dump.stat_dag,        1, "misc: Firm calculates DAG statistics" },
   { X("firm-asm"),               &firm_dump.gen_firm_asm,    1, "misc: output Firm assembler" },
-  { X("win32"),                  &firm_opt.os_support,       OS_SUPPORT_WIN32, "misc: generate Win32 code" },
+  { X("win32"),                  &firm_opt.os_support,       OS_SUPPORT_MINGW, "misc: generate MinGW Win32 code" },
   { X("mac"),                    &firm_opt.os_support,       OS_SUPPORT_MACHO, "misc: generate MacOS code" },
   { X("linux"),                  &firm_opt.os_support,       OS_SUPPORT_LINUX, "misc: generate Linux-ELF code" },
   { X("ycomp"),                  &firm_opt.ycomp_dbg,        1, "misc: enable yComp debugger extension" },
@@ -290,7 +290,7 @@ static void disable_opts(void) {
   firm_opt.reassoc         = FALSE;
   firm_opt.cse             = FALSE;
   /* firm_opt.control_flow */
-  firm_opt.code_place      = FALSE;
+  firm_opt.gcse            = FALSE;
   firm_opt.gvn_pre         = FALSE;
   firm_opt.cond_eval       = FALSE;
   firm_opt.if_conversion   = FALSE;
@@ -373,10 +373,8 @@ int firm_option(const char *opt)
         if (firm_opt.debug_mode == DBG_MODE_FULL)
           disable_opts();
         res = 1;
-#ifdef FIRM_BACKEND
         res &= firm_be_option("omitfp=0");
         res &= firm_be_option("stabs");
-#endif /* FIRM_BACKEND */
         return res;
       }
       break;