#2132: Optimise nested comparisons
---------------------------------+------------------------------------------
Reporter: simonpj | Owner: simonpj
Type: bug | Status: patch
Priority: low | Milestone: 7.4.1
Component: Compiler | Version: 6.8.2
Keywords: | Testcase:
Blockedby: | Difficulty: Unknown
Os: Unknown/Multiple | Blocking:
Architecture: Unknown/Multiple | Failure: Runtime performance bug
---------------------------------+------------------------------------------
Comment(by michalt):
Replying to [comment:17 basvandijk]:
> Would it be hard to extend the language of RULES so that a user can
perform
> this optimization instead of the compiler? ..
Note that this optimization goes a bit further than your example. For
instance, once it knows `x ># y` and `y >=# z` it can optimize away `x <#
z`.
Similarly knowing `x ># 100` and `y <# 10` it can get rid of `x ==# y`.
That would be probably quite difficult to do with rules (even extended).
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2132#comment:18>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs