From: Ian Lynagh Date: Thu, 10 Jul 2008 14:07:57 +0000 (+0000) Subject: Move more flags from the Makefile into pragmas X-Git-Tag: Before_cabalised-GHC~29 X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=d7b3ad9be373e02ea8b679d978f6ca898436892d Move more flags from the Makefile into pragmas --- diff --git a/compiler/Makefile b/compiler/Makefile index e23cbce..96057bc 100644 --- a/compiler/Makefile +++ b/compiler/Makefile @@ -571,24 +571,6 @@ ifeq "$(BootingFromHc)" "YES" SRC_CC_OPTS += -D__GLASGOW_HASKELL__=$(ProjectVersionInt) endif -# Special flags for particular modules -# The standard suffix rule for compiling a Haskell file -# adds these flags to the command line - -# There used to be a -fforce-recomp flag on PrimOp, but why? -# It's an expensive module to recompile! -prelude/PrimOp_HC_OPTS = -H80m - - -main/ParsePkgConf_HC_OPTS += -fno-warn-incomplete-patterns -parser/Parser_HC_OPTS += -fno-warn-incomplete-patterns - -# Careful optimisation of the parser: we don't want to throw everything -# at it, because that takes too long and doesn't buy much, but we do want -# to inline certain key external functions, so we instruct GHC not to -# throw away inlinings as it would normally do in -O0 mode: -parser/Parser_HC_OPTS += -O0 -fno-ignore-interface-pragmas - ifeq "$(HOSTPLATFORM)" "hppa1.1-hp-hpux9" rename/RnMonad_HC_OPTS = -O2 -O2-for-C endif diff --git a/compiler/main/ParsePkgConf.y b/compiler/main/ParsePkgConf.y index ea515db..b09f2b3 100644 --- a/compiler/main/ParsePkgConf.y +++ b/compiler/main/ParsePkgConf.y @@ -1,5 +1,5 @@ { -{-# OPTIONS -fno-warn-unused-binds -fno-warn-unused-matches -fno-warn-missing-signatures #-} +{-# OPTIONS -fno-warn-unused-binds -fno-warn-unused-matches -fno-warn-missing-signatures -fno-warn-incomplete-patterns #-} -- The above warning supression flag is a temporary kludge. -- While working on this module you are encouraged to remove it and fix -- any warnings in the module. See diff --git a/compiler/parser/Parser.y.pp b/compiler/parser/Parser.y.pp index e4285ba..d7971b4 100644 --- a/compiler/parser/Parser.y.pp +++ b/compiler/parser/Parser.y.pp @@ -8,6 +8,14 @@ -- --------------------------------------------------------------------------- { +{-# OPTIONS_GHC -O0 -fno-ignore-interface-pragmas #-} +{- +Careful optimisation of the parser: we don't want to throw everything +at it, because that takes too long and doesn't buy much, but we do want +to inline certain key external functions, so we instruct GHC not to +throw away inlinings as it would normally do in -O0 mode. +-} + {-# OPTIONS -w #-} -- The above warning supression flag is a temporary kludge. -- While working on this module you are encouraged to remove it and fix diff --git a/compiler/prelude/PrimOp.lhs b/compiler/prelude/PrimOp.lhs index 61ccc8d..c2cac8f 100644 --- a/compiler/prelude/PrimOp.lhs +++ b/compiler/prelude/PrimOp.lhs @@ -4,6 +4,7 @@ \section[PrimOp]{Primitive operations (machine-level)} \begin{code} +{-# OPTIONS_GHC -H80m #-} {-# OPTIONS -fno-warn-unused-binds #-} -- The above warning supression flag is a temporary kludge. -- While working on this module you are encouraged to remove it and fix