Permalink
Browse files

Change TRACE mode to use -O2

  • Loading branch information...
1 parent 0af107c commit b94138651c43a76c6d606f1701824808b027fd9e Edwin Brady committed Sep 5, 2012
Showing with 5 additions and 5 deletions.
  1. +1 −1 iif/big.iif
  2. +1 −1 rts/idris_main.c
  3. +2 −2 src/IRTS/CodegenC.hs
  4. +1 −1 src/IRTS/LParser.hs
View
@@ -4,4 +4,4 @@ fun fact(x) = case (x ==: 0:) of {
}
fun main() = let f = fact(200:) in
- %WriteString(%BigStr(f) ++ "\n")
+ %WriteString(%BigString(f) ++ "\n")
View
@@ -2,7 +2,7 @@ int main(int argc, char* argv[]) {
VM* vm = init_vm(1024000, 1024000);
_idris_main(vm, NULL);
-#ifdef IDRIS_DEBUG
+#ifdef IDRIS_TRACE
printf("\nStack: %p %p\n", vm->valstack, vm->valstack_top);
printf("GCs: %d\n", vm->collections);
printf("Final heap size %d\n", (int)(vm->heap_size));
View
@@ -52,11 +52,11 @@ codegenC defs out exec incs libs dbg
headers [] = "#include <idris_rts.h>\n\n"
headers (x : xs) = "#include <" ++ x ++ ">\n" ++ headers xs
-debug TRACE = "#define IDRIS_DEBUG\n\n"
+debug TRACE = "#define IDRIS_TRACE\n\n"
debug _ = ""
gccDbg DEBUG = "-g"
-gccDbg TRACE = "-g"
+gccDbg TRACE = "-O2"
gccDbg _ = "-O2"
cname :: Name -> String
View
@@ -54,7 +54,7 @@ fovm f = do defs <- parseFOVM f
let checked = checkDefs defuns (toAlist defuns)
-- print checked
case checked of
- OK c -> codegenC c "a.out" True ["math.h"] "" NONE
+ OK c -> codegenC c "a.out" True ["math.h"] "" TRACE
Error e -> fail $ show e
parseFOVM :: FilePath -> IO [(Name, LDecl)]

0 comments on commit b941386

Please sign in to comment.