summaryrefslogtreecommitdiff
path: root/compiler/nativeGen/AsmCodeGen.lhs
Commit message (Collapse)AuthorAgeFilesLines
...
| * Remove some more redundant Platform argumentsIan Lynagh2012-06-201-2/+1
| |
| * Make -dppr-cols a dynamic flagIan Lynagh2012-06-181-1/+1
| |
| * Stop exporting, and stop using, some deprecated functionsIan Lynagh2012-06-131-2/+2
| |
| * Remove more unused Platform argumentsIan Lynagh2012-06-131-1/+1
| |
| * Remove PlatformOutputableIan Lynagh2012-06-131-7/+7
| | | | | | | | | | We can now get the Platform from the DynFlags inside an SDoc, so we no longer need to pass the Platform in.
| * Add DynFlags to the SDoc stateIan Lynagh2012-06-121-2/+2
| |
| * Use SDoc rather than Doc in the native gensIan Lynagh2012-06-121-26/+25
| | | | | | | | This avoid lots of converting back and forth between the two types.
| * Pass DynFlags down to showSDocIan Lynagh2012-06-121-4/+3
| |
| * Pass DynFlags to renderWithStyleIan Lynagh2012-06-111-1/+1
| |
| * add support for ARM hard-float ABI (fixes #5914)Karel Gardas2012-04-271-1/+1
| | | | | | | | | | | | | | This patch enhances Platform's ArchARM to include ARM ABI value. It also tweaks configure machinery to detect hard-float ABI and to set it wherever needed. Finally when hard-float ABI is in use, pass appropriate compiler option to the LLVM's llc. Fixes #5914.
| * Fix the unregisterised build; fixes #5901Ian Lynagh2012-02-271-1/+5
| |
| * Whitespace only in nativeGen/AsmCodeGen.lhsIan Lynagh2012-02-271-301/+294
| |
* | no need to check for unreachable blocks with -fnew-codegenSimon Marlow2012-07-031-1/+6
| | | | | | | | we've already done it
* | re-enable constant folding in the NCG, while cmmRewriteAssignments is offSimon Marlow2012-02-151-1/+2
| |
* | Merge remote-tracking branch 'origin/master' into newcgSimon Marlow2012-02-131-7/+7
|\ \ | |/ | | | | | | | | | | | | Conflicts: compiler/cmm/CmmLint.hs compiler/cmm/OldCmm.hs compiler/codeGen/CgMonad.lhs compiler/main/CodeOutput.lhs
| * Track STG live register information for use in LLVMDavid Terei2012-01-091-2/+2
| | | | | | | | | | | | | | | | | | We now carry around with CmmJump statements a list of the STG registers that are live at that jump site. This is used by the LLVM backend so it can avoid unnesecarily passing around dead registers, improving perfromance. This gives us the framework to finally fix trac #4308.
| * Remove unused argument field on CmmJumpDavid Terei2012-01-051-2/+2
| |
| * Make getDynFlags* functions use HasDynFlags/getDynFlags tooIan Lynagh2011-12-191-5/+5
| |
* | Thread the UniqSupply around properlySimon Marlow2012-01-271-6/+7
| |
* | Run the complete backend (Stg -> .S) incrementally on each StgBindingSimon Marlow2012-01-261-5/+35
|/ | | | | | | | | This is so that we can process the Stg code in constant space. Before we were generating all the C-- up front, leading to a large space leak. I haven't converted the LLVM or C back ends to the incremental scheme, but it's not hard to do.
* add some SCCsSimon Marlow2011-12-131-4/+4
|
* Detect cases where as(1) doesn't recognise .ident directive (#5408)PHO2011-12-081-4/+7
| | | | .ident directives are usually ignored by as(1), and in some cases (like Darwin/PPC) they even raise an error.
* Get rid of the "safety" field of CmmCall (OldCmm)Simon Marlow2011-11-291-2/+2
| | | | | This field was doing nothing. I think it originally appeared in a very old incarnation of the new code generator.
* Remove registerised code for dead architectures: mips, ia64, alpha,David Terei2011-11-221-6/+0
| | | | hppa1, m68k
* Finish de-CPPing CmmOpt.hsIan Lynagh2011-11-051-7/+9
|
* Fix bitrotted NCG_DEBUG code, and switch to using a Haskell conditionalIan Lynagh2011-11-051-1/+2
|
* Use -fwarn-tabs when validatingIan Lynagh2011-11-041-0/+7
| | | | | We only use it for "compiler" sources, i.e. not for libraries. Many modules have a -fno-warn-tabs kludge for now.
* Eliminate all uses of IF_ARCH_i386, and remove the definitionIan Lynagh2011-10-231-3/+4
|
* A little more CPP removalIan Lynagh2011-10-191-0/+6
|
* Convert the HAVE_GNU_NONEXEC_STACK conditional into HaskellIan Lynagh2011-10-191-4/+5
|
* Remove all Haskell conditionals on HAVE_SUBSECTIONS_VIA_SYMBOLSIan Lynagh2011-10-191-7/+7
| | | | We now use the value from the targetPlatform instead.
* Revert "Remove ArchUnknown"Ian Lynagh2011-10-191-0/+2
| | | | | | | This reverts commit 2dea11a442e1d14d86fa661804de06a721943bf0. On second thoughts, this does make sense, for unregisterised via-C arches at least.
* Remove ArchUnknownIan Lynagh2011-10-181-2/+0
| | | | | | | It doesn't make sense. If platformArch is ArchUnknown then we don't know the answer to any questions about the arch. So now if we don't recognise the arch we just fail, and the new arch will need to be added to the datatype.
* More CPP removal: pprDynamicLinkerAsmLabel in CLabelIan Lynagh2011-10-021-11/+16
| | | | And some knock-on changes
* Renaming onlySimon Peyton Jones2011-08-251-36/+36
| | | | | CmmTop -> CmmDecl CmmPgm -> CmmGroup
* Snapshot of codegen refactoring to share with simonpjSimon Marlow2011-08-251-4/+4
|
* enhance ArchARM with ISA and ISA extensionsKarel Gardas2011-08-211-1/+1
| | | | | | | This patch enhances ArchARM with ARM ISA and ISA extensions details as is suggested in the comment in Platform.hs file. The patch is needed by future patch which will use ARM ISA information in order to pass appropriate command-line option to the LLVM llc tool.
* Small refactoringIan Lynagh2011-07-151-2/+2
|
* Remove more defaultTargetPlatform usesIan Lynagh2011-07-151-2/+2
|
* Remove some more defaultTargetPlatform usesIan Lynagh2011-07-151-5/+6
|
* Remove some defaultTargetPlatform'sIan Lynagh2011-07-151-1/+1
| | | | We now pass the correct platform in instead
* More work towards cross-compilationIan Lynagh2011-07-151-14/+15
| | | | | | | | | | | | There's now a variant of the Outputable class that knows what platform we're targetting: class PlatformOutputable a where pprPlatform :: Platform -> a -> SDoc pprPlatformPrec :: Platform -> Rational -> a -> SDoc and various instances have had to be converted to use that class, and we pass Platform around accordingly.
* CPP removalIan Lynagh2011-07-131-7/+7
|
* Refactoring: explicitly mark whether we have an info table in RawCmmMax Bolingbroke2011-07-061-1/+1
| | | | | | | | | | | | I introduced this to support explicitly recording the info table label in RawCmm for another patch I am working on, but it turned out to lead to significant simplification in those parts of the compiler that consume RawCmm. Now, instead of lots of tests for null [CmmStatic] we have a simple test of a Maybe, and have reduced the number of guys that need to know how to convert entry->info labels by a TON. There are only 3 callers of that function now!
* Refactoring: use a structured CmmStatics type rather than [CmmStatic]Max Bolingbroke2011-07-051-41/+41
| | | | | | | | | | | | | | | | | | I observed that the [CmmStatics] within CmmData uses the list in a very stylised way. The first item in the list is almost invariably a CmmDataLabel. Many parts of the compiler pattern match on this list and fail if this is not true. This patch makes the invariant explicit by introducing a structured type CmmStatics that holds the label and the list of remaining [CmmStatic]. There is one wrinkle: the x86 backend sometimes wants to output an alignment directive just before the label. However, this can be easily fixed up by parameterising the native codegen over the type of CmmStatics (though the GenCmmTop parameterisation) and using a pair (Alignment, CmmStatics) there instead. As a result, I think we will be able to remove CmmAlign and CmmDataLabel from the CmmStatic data type, thus nuking a lot of code and failing pattern matches. This change will come as part of my next patch.
* add missing cases for ArchARMSimon Marlow2011-06-271-0/+2
|
* Skip constant folding in nativegen if new codegen used.Edward Z. Yang2011-06-171-2/+8
| | | | Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
* Port MachOp folding to new code generator.Edward Z. Yang2011-06-171-13/+36
| | | | | | | | | | | | | | | * Rewrote cmmMachOpFold to cmmMachOpFoldM, which returns Nothing if no folding took place. * Wrote some generic mapping functions which take functions of form 'a -> Maybe a' and are smart about sharing. * Split up optimizations from PIC and PPC work in the native codegen, so they'll be easier to turn off later (they are not currently being turned off, however.) * Whitespace fixes! ToDo: Turn off MachOp folding when new codegenerator is being used. Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
* cmmTopCodeGen no longer takes DynFlags as an argumentIan Lynagh2011-06-081-3/+3
| | | | It is in the NatM monad, which has DynFlags as part of its state.
* Remove CPP from nativeGen/RegAlloc/Linear/FreeRegs.hsIan Lynagh2011-05-311-1/+1
| | | | Fixes more failures on arches without an NCG