Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : master

http://hackage.haskell.org/trac/ghc/changeset/748883b4f157a495dec59ba59dd1d21556778efe

>---------------------------------------------------------------

commit 748883b4f157a495dec59ba59dd1d21556778efe
Author: Karel Gardas <[email protected]>
Date:   Sat Aug 20 23:58:15 2011 +0200

    enable ARM specific target data layout and triple again
    
    This patch is allowed by the 'on ARMv7 with VFPv3[D16] support pass
     appropriate -mattr value to LLVM llc' patch. The trick is that LLVM
    by default (probably!) does not enable VFP, but GHC requires it
    so LLVM's llc asserts on unavailable floating point register. i.e. GHC/LLVM
    backend compiles into LLVM code which is using floats, but llc thinks
    no float regs for this are available. Passing appropriate llc option
    which is implemented in patch mentioned above fixes this issue.

>---------------------------------------------------------------

 compiler/llvmGen/LlvmCodeGen/Ppr.hs |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/compiler/llvmGen/LlvmCodeGen/Ppr.hs 
b/compiler/llvmGen/LlvmCodeGen/Ppr.hs
index 2f4fbfa..399a82f 100644
--- a/compiler/llvmGen/LlvmCodeGen/Ppr.hs
+++ b/compiler/llvmGen/LlvmCodeGen/Ppr.hs
@@ -51,12 +51,12 @@ moduleLayout =
     $+$ text "target triple = \"x86_64-linux-gnu\""
 #endif
 
--- #elif defined (arm_TARGET_ARCH)
+#elif defined (arm_TARGET_ARCH)
 
--- #if linux_TARGET_OS
---    text "target datalayout = 
\"e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:64:128-a0:0:64-n32\""
---    $+$ text "target triple = \"arm-unknown-linux-gnueabi\""
--- #endif
+#if linux_TARGET_OS
+    text "target datalayout = 
\"e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:64:128-a0:0:64-n32\""
+    $+$ text "target triple = \"arm-unknown-linux-gnueabi\""
+#endif
 
 #else
     -- FIX: Other targets



_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to