[project @ 2003-06-26 20:47:08 by panne]
[ghc-hetmet.git] / ghc / compiler / main / DriverPipeline.hs
index 51267d9..e0aa062 100644 (file)
@@ -1109,7 +1109,9 @@ hscNextPhase hsc_lang = do
                HscC -> HCc
                HscAsm | split -> SplitMangle
                       | otherwise -> As
-               HscNothing -> HCc
+               HscNothing     -> HCc  -- dummy (no output will be generated)
+               HscInterpreted -> HCc  -- "" ""
+               _other         -> HCc  -- "" ""
        )
 
 hscMaybeAdjustLang :: HscLang -> IO HscLang
@@ -1121,6 +1123,8 @@ hscMaybeAdjustLang current_hsc_lang = do
         | current_hsc_lang == HscInterpreted = current_hsc_lang
        -- force -fvia-C if we are being asked for a .hc file
         | todo == StopBefore HCc  || keep_hc = HscC
+       -- force -fvia-C when profiling or ticky-ticky is on
+        | opt_SccProfilingOn || opt_DoTickyProfiling = HscC
        -- otherwise, stick to the plan
         | otherwise = current_hsc_lang
   return hsc_lang