diff --git a/backendC/CleanCompilerSources/cocl.c b/backendC/CleanCompilerSources/cocl.c index 7a6ebfaff314060f82124f42b51c35fb40dc91e7..d403213800887bdd83c5acb51abadf88d9d66185 100644 --- a/backendC/CleanCompilerSources/cocl.c +++ b/backendC/CleanCompilerSources/cocl.c @@ -128,6 +128,7 @@ Bool CallCompiler (int argc, char **argv) DoTimeProfiling=False; DoReuseUniqueNodes=False; DoFusion=False; + DoGenericFusion=False; DoDescriptors=False; ExportLocalLabels=False; AddStrictnessToExportedFunctionTypes=False; @@ -192,6 +193,8 @@ Bool CallCompiler (int argc, char **argv) ExportLocalLabels=True; else if (strcmp (argv_i,"-fusion") == 0) DoFusion=True; + else if (strcmp (argv_i,"-generic_fusion") == 0) + DoGenericFusion=True; else if (strcmp (argv_i,"-seft") == 0) AddStrictnessToExportedFunctionTypes=True; else if (strcmp (argv_i,"-dynamics") == 0) diff --git a/backendC/CleanCompilerSources/instructions.c b/backendC/CleanCompilerSources/instructions.c index 39c9487146478c90baf76dd29898aad89a06d027..cc891e0ef32c56e3080f7328d0cd8510ea8752b4 100644 --- a/backendC/CleanCompilerSources/instructions.c +++ b/backendC/CleanCompilerSources/instructions.c @@ -55,9 +55,10 @@ static void error_in_function (char *m) #define N_DoFusion 9 #define N_Do64BitArch 10 #define N_Dynamics 11 +#define N_DoGenericFusion 12 #define MINIMUM_N_OPTIONS 9 -#define N_OPTIONS 12 +#define N_OPTIONS 13 static void ConvertOptionsToString (char *optstring) { @@ -79,10 +80,11 @@ static void ConvertOptionsToString (char *optstring) optstring[N_DoWarning] = DoWarning ? '1' : '0'; optstring[N_System] = '0'; - if (DoFusion || ObjectSizes[RealObj]!=2 || Dynamics){ + if (DoFusion || ObjectSizes[RealObj]!=2 || Dynamics || DoGenericFusion){ optstring[N_DoFusion] = DoFusion ? '1' : '0'; optstring[N_Do64BitArch] = ObjectSizes[RealObj]!=2 ? '1' : '0'; optstring[N_Dynamics] = Dynamics ? '1' : '0'; + optstring[N_DoGenericFusion] = DoGenericFusion ? '1' : '0'; optstring[N_OPTIONS]='\0'; } else optstring[MINIMUM_N_OPTIONS]='\0'; diff --git a/backendC/CleanCompilerSources/settings.c b/backendC/CleanCompilerSources/settings.c index 166b53ef0f5e2634062f7be233d171f2ebdd81fd..7b466841ed49d5450570bf05623ce168e3a5bc9b 100644 --- a/backendC/CleanCompilerSources/settings.c +++ b/backendC/CleanCompilerSources/settings.c @@ -31,6 +31,7 @@ Bool DoTimeProfiling=False; Bool DoReuseUniqueNodes = False; Bool DoFusion = False; +Bool DoGenericFusion = False; Bool OptimizeLazyTupleRecursion=False; Bool OptimizeTailCallModuloCons=True; diff --git a/backendC/CleanCompilerSources/settings.h b/backendC/CleanCompilerSources/settings.h index 678106eec22fcbcfb26cdce823f177512a4c298b..aa996c95c02aed6d4d0f4e491542a50f33afe475 100644 --- a/backendC/CleanCompilerSources/settings.h +++ b/backendC/CleanCompilerSources/settings.h @@ -29,6 +29,7 @@ extern Bool DoTimeProfiling; extern Bool DoReuseUniqueNodes; extern Bool DoFusion; +extern Bool DoGenericFusion; extern Bool OptimizeLazyTupleRecursion; extern Bool OptimizeTailCallModuloCons; extern Bool WriteModificationTimes;