X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fmain%2FDynFlags.hs;h=28943abd9ad1ba477546c0f018469ddd4c8aad39;hp=b3bea06d795a146ad49735672504596908608b77;hb=12b7e9f1fa41e42350408f2bf0d6885f3fcba068;hpb=615dbe7edd0a51bcb61565081dfa09a9bf37058d diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs index b3bea06..28943ab 100644 --- a/compiler/main/DynFlags.hs +++ b/compiler/main/DynFlags.hs @@ -166,7 +166,6 @@ data DynFlag | Opt_MonomorphismRestriction | Opt_MonoPatBinds | Opt_ExtendedDefaultRules -- Use GHC's extended rules for defaulting - | Opt_GlasgowExts | Opt_FFI | Opt_UnliftedFFITypes | Opt_PArr -- Syntactic support for parallel arrays @@ -177,8 +176,6 @@ data DynFlag | Opt_ImplicitPrelude | Opt_ScopedTypeVariables | Opt_UnboxedTuples - | Opt_ExpressionSignaturesUnboxedTuples - | Opt_TypeSynonymUnboxedTuples | Opt_BangPatterns | Opt_TypeFamilies | Opt_OverloadedStrings @@ -187,6 +184,8 @@ data DynFlag | Opt_RecordPuns | Opt_GADTs | Opt_RelaxedPolyRec -- -X=RelaxedPolyRec + | Opt_StandaloneDeriving + | Opt_DeriveDataTypeable | Opt_TypeSynonymInstances | Opt_FlexibleContexts | Opt_FlexibleInstances @@ -677,6 +676,7 @@ data CoreToDo -- These are diff core-to-core passes, | CoreCSE | CoreDoRuleCheck Int{-CompilerPhase-} String -- Check for non-application of rules -- matching this string + | CoreDoVectorisation | CoreDoNothing -- Useful when building up | CoreDoPasses [CoreToDo] -- lists of these things @@ -712,6 +712,7 @@ getCoreToDo dflags spec_constr = dopt Opt_SpecConstr dflags liberate_case = dopt Opt_LiberateCase dflags rule_check = ruleCheck dflags + vectorisation = dopt Opt_Vectorise dflags core_todo = if opt_level == 0 then @@ -739,6 +740,15 @@ getCoreToDo dflags MaxSimplifierIterations max_iter ], + + -- We run vectorisation here for now, but we might also try to run + -- it later + runWhen vectorisation (CoreDoPasses [ + CoreDoVectorisation, + CoreDoSimplify SimplGently + [NoCaseOfCase, + MaxSimplifierIterations max_iter]]), + -- Specialisation is best done before full laziness -- so that overloaded functions have all their dictionary lambdas manifest CoreDoSpecialising, @@ -1072,6 +1082,7 @@ dynamic_flags = [ -- these -f flags can all be reversed with -fno- fFlags = [ + ( "warn-dodgy-imports", Opt_WarnDodgyImports ), ( "warn-duplicate-exports", Opt_WarnDuplicateExports ), ( "warn-hi-shadowing", Opt_WarnHiShadows ), ( "warn-implicit-prelude", Opt_WarnImplicitPrelude ), @@ -1165,8 +1176,8 @@ xFlags = [ ( "ImplicitParams", Opt_ImplicitParams ), ( "ScopedTypeVariables", Opt_ScopedTypeVariables ), ( "UnboxedTuples", Opt_UnboxedTuples ), - ( "ExpressionSignaturesUnboxedTuples", Opt_ExpressionSignaturesUnboxedTuples ), - ( "TypeSynonymUnboxedTuples", Opt_TypeSynonymUnboxedTuples ), + ( "StandaloneDeriving", Opt_StandaloneDeriving ), + ( "DeriveDataTypeable", Opt_DeriveDataTypeable ), ( "TypeSynonymInstances", Opt_TypeSynonymInstances ), ( "FlexibleContexts", Opt_FlexibleContexts ), ( "FlexibleInstances", Opt_FlexibleInstances ), @@ -1184,17 +1195,17 @@ impliedFlags = [ ( Opt_GADTs, [Opt_RelaxedPolyRec] ) -- We want type-sig variables to be completely rigid for GADTs ] -glasgowExtsFlags = [ Opt_GlasgowExts - , Opt_PrintExplicitForalls +glasgowExtsFlags = [ + Opt_PrintExplicitForalls , Opt_FFI , Opt_UnliftedFFITypes , Opt_GADTs , Opt_ImplicitParams , Opt_ScopedTypeVariables , Opt_UnboxedTuples - , Opt_ExpressionSignaturesUnboxedTuples - , Opt_TypeSynonymUnboxedTuples , Opt_TypeSynonymInstances + , Opt_StandaloneDeriving + , Opt_DeriveDataTypeable , Opt_FlexibleContexts , Opt_FlexibleInstances , Opt_ConstrainedClassMethods