diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,11 @@
+0.6: [2021-01-07]
+-----------------
+* Remove hashable flag (only necessary was unordered-containers flag)
+* Drop redundant `Eq` constraint on default definition of `coprime`
+* Document (lack of guaranteed) rounding behaviour of quotRem
+* Fix totally broken Ord instance for Tropical
+* Stop depending on integer-gmp
+
 0.5.4: [2020.07.13]
 -------------------
 * Drop support for GHCs prior to 7.10
diff --git a/Data/Euclidean.hs b/Data/Euclidean.hs
--- a/Data/Euclidean.hs
+++ b/Data/Euclidean.hs
@@ -9,6 +9,12 @@
 {-# LANGUAGE DefaultSignatures          #-}
 {-# LANGUAGE GeneralizedNewtypeDeriving #-}
 {-# LANGUAGE MagicHash                  #-}
+#if MIN_VERSION_base(4,12,0)
+{-# LANGUAGE DerivingVia                #-}
+{-# LANGUAGE StandaloneDeriving         #-}
+#else
+{-# LANGUAGE TemplateHaskell            #-}
+#endif
 
 module Data.Euclidean
   ( Euclidean(..)
@@ -30,9 +36,11 @@
 import Data.Semiring (Semiring(..), Ring(..), (*), minus, isZero, Mod2)
 import Data.Word (Word, Word8, Word16, Word32, Word64)
 import Foreign.C.Types (CFloat, CDouble)
-import GHC.Exts (Int(..), Word(..))
-import GHC.Integer.GMP.Internals (gcdInt, gcdWord, gcdInteger, lcmInteger)
 
+#if !MIN_VERSION_base(4,12,0)
+import Language.Haskell.TH.Syntax (Q, Dec, Type)
+#endif
+
 import Numeric.Natural
 
 ---------------------------------------------------------------------
@@ -101,7 +109,7 @@
   -- prop> \x y -> coprime x y == isJust (1 `divide` gcd x y)
   coprime :: a -> a -> Bool
 
-  default coprime :: Eq a => a -> a -> Bool
+  default coprime :: a -> a -> Bool
   coprime x y = isJust (one `divide` gcd x y)
 
 infixl 7 `divide`
@@ -114,6 +122,12 @@
 -- 'Euclidean' represents a
 -- <https://en.wikipedia.org/wiki/Euclidean_domain Euclidean domain>
 -- endowed by a given Euclidean function 'degree'.
+--
+-- No particular rounding behaviour is expected of 'quotRem'. E. g.,
+-- it is not guaranteed to truncate towards zero or towards negative
+-- infinity (cf. 'P.divMod'), and remainders are not guaranteed to be non-negative.
+-- For a faithful representation of residue classes one can use
+-- <http://hackage.haskell.org/package/mod mod> package instead.
 class GcdDomain a => Euclidean a where
   {-# MINIMAL (quotRem | quot, rem), degree #-}
   -- | Division with remainder.
@@ -221,71 +235,6 @@
   quot    = P.quot
   rem     = P.rem
 
-instance GcdDomain Int where
-  divide x y = case x `P.quotRem` y of (q, 0) -> Just q; _ -> Nothing
-#if MIN_VERSION_integer_gmp(0,5,1)
-  gcd (I# x) (I# y) = I# (gcdInt x y)
-#else
-  gcd     = P.gcd
-#endif
-  lcm     = P.lcm
-  coprime = coprimeIntegral
-
-instance GcdDomain Word where
-  divide x y = case x `P.quotRem` y of (q, 0) -> Just q; _ -> Nothing
-#if MIN_VERSION_integer_gmp(1,0,0)
-  gcd (W# x) (W# y) = W# (gcdWord x y)
-#else
-  gcd     = P.gcd
-#endif
-  lcm     = P.lcm
-  coprime = coprimeIntegral
-
-instance GcdDomain Integer where
-  divide x y = case x `P.quotRem` y of (q, 0) -> Just q; _ -> Nothing
-  gcd     = gcdInteger
-  lcm     = lcmInteger
-  coprime = coprimeIntegral
-
-#define deriveGcdDomain(ty)     \
-instance GcdDomain (ty) where { \
-;  divide x y = case x `P.quotRem` y of { (q, 0) -> Just q; _ -> Nothing } \
-;  gcd     = P.gcd              \
-;  lcm     = P.lcm              \
-;  coprime = coprimeIntegral    \
-}
-
-deriveGcdDomain(Int8)
-deriveGcdDomain(Int16)
-deriveGcdDomain(Int32)
-deriveGcdDomain(Int64)
-deriveGcdDomain(Word8)
-deriveGcdDomain(Word16)
-deriveGcdDomain(Word32)
-deriveGcdDomain(Word64)
-deriveGcdDomain(Natural)
-
-#define deriveEuclidean(ty)       \
-instance Euclidean (ty) where {   \
-;  degree  = P.fromIntegral . abs \
-;  quotRem = P.quotRem            \
-;  quot    = P.quot               \
-;  rem     = P.rem                \
-}
-
-deriveEuclidean(Int)
-deriveEuclidean(Int8)
-deriveEuclidean(Int16)
-deriveEuclidean(Int32)
-deriveEuclidean(Int64)
-deriveEuclidean(Integer)
-deriveEuclidean(Word)
-deriveEuclidean(Word8)
-deriveEuclidean(Word16)
-deriveEuclidean(Word32)
-deriveEuclidean(Word64)
-deriveEuclidean(Natural)
-
 -- | Wrapper around 'Fractional'
 -- with trivial 'GcdDomain'
 -- and 'Euclidean' instances.
@@ -404,3 +353,82 @@
   rem         = const $ const zero
 
 instance Field a => Field (Complex a)
+
+#if MIN_VERSION_base(4,12,0)
+deriving via (WrappedIntegral Int) instance GcdDomain Int
+deriving via (WrappedIntegral Int8) instance GcdDomain Int8
+deriving via (WrappedIntegral Int16) instance GcdDomain Int16
+deriving via (WrappedIntegral Int32) instance GcdDomain Int32
+deriving via (WrappedIntegral Int64) instance GcdDomain Int64
+deriving via (WrappedIntegral Integer) instance GcdDomain Integer
+deriving via (WrappedIntegral Word) instance GcdDomain Word
+deriving via (WrappedIntegral Word8) instance GcdDomain Word8
+deriving via (WrappedIntegral Word16) instance GcdDomain Word16
+deriving via (WrappedIntegral Word32) instance GcdDomain Word32
+deriving via (WrappedIntegral Word64) instance GcdDomain Word64
+deriving via (WrappedIntegral Natural) instance GcdDomain Natural
+#else
+$(let
+  deriveGcdDomain :: Q Type -> Q [Dec]
+  deriveGcdDomain ty = [d|
+      instance GcdDomain $ty where
+         gcd     = P.gcd
+         lcm     = P.lcm
+         coprime = coprimeIntegral
+      |]
+
+  in P.concat P.<$> P.traverse deriveGcdDomain
+    [[t|Int|]
+    ,[t|Int8|]
+    ,[t|Int16|]
+    ,[t|Int32|]
+    ,[t|Int64|]
+    ,[t|Integer|]
+    ,[t|Word|]
+    ,[t|Word8|]
+    ,[t|Word16|]
+    ,[t|Word32|]
+    ,[t|Word64|]
+    ,[t|Natural|]
+    ])
+#endif
+
+#if MIN_VERSION_base(4,12,0)
+deriving via (WrappedIntegral Int) instance Euclidean Int
+deriving via (WrappedIntegral Int8) instance Euclidean Int8
+deriving via (WrappedIntegral Int16) instance Euclidean Int16
+deriving via (WrappedIntegral Int32) instance Euclidean Int32
+deriving via (WrappedIntegral Int64) instance Euclidean Int64
+deriving via (WrappedIntegral Integer) instance Euclidean Integer
+deriving via (WrappedIntegral Word) instance Euclidean Word
+deriving via (WrappedIntegral Word8) instance Euclidean Word8
+deriving via (WrappedIntegral Word16) instance Euclidean Word16
+deriving via (WrappedIntegral Word32) instance Euclidean Word32
+deriving via (WrappedIntegral Word64) instance Euclidean Word64
+deriving via (WrappedIntegral Natural) instance Euclidean Natural
+#else
+$(let
+  deriveEuclidean :: Q Type -> Q [Dec]
+  deriveEuclidean ty = [d|
+      instance Euclidean $ty where
+         degree  = P.fromIntegral . abs
+         quotRem = P.quotRem
+         quot    = P.quot
+         rem     = P.rem
+      |]
+
+  in P.concat P.<$> P.traverse deriveEuclidean
+    [[t|Int|]
+    ,[t|Int8|]
+    ,[t|Int16|]
+    ,[t|Int32|]
+    ,[t|Int64|]
+    ,[t|Integer|]
+    ,[t|Word|]
+    ,[t|Word8|]
+    ,[t|Word16|]
+    ,[t|Word32|]
+    ,[t|Word64|]
+    ,[t|Natural|]
+    ])
+#endif
diff --git a/Data/Semiring.hs b/Data/Semiring.hs
--- a/Data/Semiring.hs
+++ b/Data/Semiring.hs
@@ -11,6 +11,11 @@
 {-# LANGUAGE Rank2Types                 #-}
 {-# LANGUAGE ScopedTypeVariables        #-}
 {-# LANGUAGE StandaloneDeriving         #-}
+#if MIN_VERSION_base(4,12,0)
+{-# LANGUAGE DerivingVia                #-}
+#else
+{-# LANGUAGE TemplateHaskell            #-}
+#endif
 
 -----------------------------------------------------------------------------
 -- |
@@ -118,14 +123,19 @@
 import           GHC.Float (Float, Double)
 import           GHC.Generics (Generic,Generic1)
 import           GHC.IO (IO)
-import           GHC.Integer (Integer)
 import qualified GHC.Num as Num
 import           GHC.Read (Read)
 import           GHC.Real (Integral, Fractional, Real, RealFrac)
 import qualified GHC.Real as Real
 import           GHC.Show (Show)
 import           Numeric.Natural (Natural)
+import           Prelude (Integer)
 
+#if !MIN_VERSION_base(4,12,0)
+import           Language.Haskell.TH.Syntax (Q, Dec, Type)
+import qualified Prelude as P
+#endif
+
 #ifdef mingw32_HOST_OS
 #define HOST_OS_WINDOWS 1
 #else
@@ -664,80 +674,6 @@
 deriving instance Ring a => Ring (Op a b)
 #endif
 
-#define deriveSemiring(ty)         \
-instance Semiring (ty) where {     \
-   zero  = 0                       \
-;  one   = 1                       \
-;  plus  x y = (Num.+) x y         \
-;  times x y = (Num.*) x y         \
-;  fromNatural = Real.fromIntegral \
-;  {-# INLINE zero #-}             \
-;  {-# INLINE one  #-}             \
-;  {-# INLINE plus #-}             \
-;  {-# INLINE times #-}            \
-;  {-# INLINE fromNatural #-}      \
-}
-
-deriveSemiring(Int)
-deriveSemiring(Int8)
-deriveSemiring(Int16)
-deriveSemiring(Int32)
-deriveSemiring(Int64)
-deriveSemiring(Integer)
-deriveSemiring(Word)
-deriveSemiring(Word8)
-deriveSemiring(Word16)
-deriveSemiring(Word32)
-deriveSemiring(Word64)
-deriveSemiring(Float)
-deriveSemiring(Double)
-deriveSemiring(CUIntMax)
-deriveSemiring(CIntMax)
-deriveSemiring(CUIntPtr)
-deriveSemiring(CIntPtr)
-deriveSemiring(CSUSeconds)
-deriveSemiring(CUSeconds)
-deriveSemiring(CTime)
-deriveSemiring(CClock)
-deriveSemiring(CSigAtomic)
-deriveSemiring(CWchar)
-deriveSemiring(CSize)
-deriveSemiring(CPtrdiff)
-deriveSemiring(CDouble)
-deriveSemiring(CFloat)
-deriveSemiring(CULLong)
-deriveSemiring(CLLong)
-deriveSemiring(CULong)
-deriveSemiring(CLong)
-deriveSemiring(CUInt)
-deriveSemiring(CInt)
-deriveSemiring(CUShort)
-deriveSemiring(CShort)
-deriveSemiring(CUChar)
-deriveSemiring(CSChar)
-deriveSemiring(CChar)
-deriveSemiring(IntPtr)
-deriveSemiring(WordPtr)
-
-#if !HOST_OS_WINDOWS
-deriveSemiring(CCc)
-deriveSemiring(CDev)
-deriveSemiring(CGid)
-deriveSemiring(CIno)
-deriveSemiring(CMode)
-deriveSemiring(CNlink)
-deriveSemiring(COff)
-deriveSemiring(CPid)
-deriveSemiring(CRLim)
-deriveSemiring(CSpeed)
-deriveSemiring(CSsize)
-deriveSemiring(CTcflag)
-deriveSemiring(CUid)
-deriveSemiring(Fd)
-#endif
-
-deriveSemiring(Natural)
-
 instance Integral a => Semiring (Ratio a) where
   {-# SPECIALIZE instance Semiring Rational #-}
   zero  = 0 % 1
@@ -764,70 +700,6 @@
   {-# INLINE times #-}
   {-# INLINE fromNatural #-}
 
-#define deriveRing(ty)          \
-instance Ring (ty) where {      \
-  negate = Num.negate           \
-; {-# INLINE negate #-}         \
-}
-
-deriveRing(Int)
-deriveRing(Int8)
-deriveRing(Int16)
-deriveRing(Int32)
-deriveRing(Int64)
-deriveRing(Integer)
-deriveRing(Word)
-deriveRing(Word8)
-deriveRing(Word16)
-deriveRing(Word32)
-deriveRing(Word64)
-deriveRing(Float)
-deriveRing(Double)
-deriveRing(CUIntMax)
-deriveRing(CIntMax)
-deriveRing(CUIntPtr)
-deriveRing(CIntPtr)
-deriveRing(CSUSeconds)
-deriveRing(CUSeconds)
-deriveRing(CTime)
-deriveRing(CClock)
-deriveRing(CSigAtomic)
-deriveRing(CWchar)
-deriveRing(CSize)
-deriveRing(CPtrdiff)
-deriveRing(CDouble)
-deriveRing(CFloat)
-deriveRing(CULLong)
-deriveRing(CLLong)
-deriveRing(CULong)
-deriveRing(CLong)
-deriveRing(CUInt)
-deriveRing(CInt)
-deriveRing(CUShort)
-deriveRing(CShort)
-deriveRing(CUChar)
-deriveRing(CSChar)
-deriveRing(CChar)
-deriveRing(IntPtr)
-deriveRing(WordPtr)
-
-#if !HOST_OS_WINDOWS
-deriveRing(CCc)
-deriveRing(CDev)
-deriveRing(CGid)
-deriveRing(CIno)
-deriveRing(CMode)
-deriveRing(CNlink)
-deriveRing(COff)
-deriveRing(CPid)
-deriveRing(CRLim)
-deriveRing(CSpeed)
-deriveRing(CSsize)
-deriveRing(CTcflag)
-deriveRing(CUid)
-deriveRing(Fd)
-#endif
-
 instance Integral a => Ring (Ratio a) where
   negate = Num.negate
   {-# INLINE negate #-}
@@ -1012,3 +884,268 @@
 isOne :: (Eq a, Semiring a) => a -> Bool
 isOne x = x == one
 {-# INLINEABLE isOne #-}
+
+#if MIN_VERSION_base(4,12,0)
+deriving via (WrappedNum Int) instance Semiring Int
+deriving via (WrappedNum Int8) instance Semiring Int8
+deriving via (WrappedNum Int16) instance Semiring Int16
+deriving via (WrappedNum Int32) instance Semiring Int32
+deriving via (WrappedNum Int64) instance Semiring Int64
+deriving via (WrappedNum Integer) instance Semiring Integer
+deriving via (WrappedNum Word) instance Semiring Word
+deriving via (WrappedNum Word8) instance Semiring Word8
+deriving via (WrappedNum Word16) instance Semiring Word16
+deriving via (WrappedNum Word32) instance Semiring Word32
+deriving via (WrappedNum Word64) instance Semiring Word64
+deriving via (WrappedNum Float) instance Semiring Float
+deriving via (WrappedNum Double) instance Semiring Double
+deriving via (WrappedNum CUIntMax) instance Semiring CUIntMax
+deriving via (WrappedNum CIntMax) instance Semiring CIntMax
+deriving via (WrappedNum CUIntPtr) instance Semiring CUIntPtr
+deriving via (WrappedNum CIntPtr) instance Semiring CIntPtr
+deriving via (WrappedNum CSUSeconds) instance Semiring CSUSeconds
+deriving via (WrappedNum CUSeconds) instance Semiring CUSeconds
+deriving via (WrappedNum CTime) instance Semiring CTime
+deriving via (WrappedNum CClock) instance Semiring CClock
+deriving via (WrappedNum CSigAtomic) instance Semiring CSigAtomic
+deriving via (WrappedNum CWchar) instance Semiring CWchar
+deriving via (WrappedNum CSize) instance Semiring CSize
+deriving via (WrappedNum CPtrdiff) instance Semiring CPtrdiff
+deriving via (WrappedNum CDouble) instance Semiring CDouble
+deriving via (WrappedNum CFloat) instance Semiring CFloat
+deriving via (WrappedNum CULLong) instance Semiring CULLong
+deriving via (WrappedNum CLLong) instance Semiring CLLong
+deriving via (WrappedNum CULong) instance Semiring CULong
+deriving via (WrappedNum CLong) instance Semiring CLong
+deriving via (WrappedNum CUInt) instance Semiring CUInt
+deriving via (WrappedNum CInt) instance Semiring CInt
+deriving via (WrappedNum CUShort) instance Semiring CUShort
+deriving via (WrappedNum CShort) instance Semiring CShort
+deriving via (WrappedNum CUChar) instance Semiring CUChar
+deriving via (WrappedNum CSChar) instance Semiring CSChar
+deriving via (WrappedNum CChar) instance Semiring CChar
+deriving via (WrappedNum IntPtr) instance Semiring IntPtr
+deriving via (WrappedNum WordPtr) instance Semiring WordPtr
+#if !HOST_OS_WINDOWS
+deriving via (WrappedNum CCc) instance Semiring CCc
+deriving via (WrappedNum CDev) instance Semiring CDev
+deriving via (WrappedNum CGid) instance Semiring CGid
+deriving via (WrappedNum CIno) instance Semiring CIno
+deriving via (WrappedNum CMode) instance Semiring CMode
+deriving via (WrappedNum CNlink) instance Semiring CNlink
+deriving via (WrappedNum COff) instance Semiring COff
+deriving via (WrappedNum CPid) instance Semiring CPid
+deriving via (WrappedNum CRLim) instance Semiring CRLim
+deriving via (WrappedNum CSpeed) instance Semiring CSpeed
+deriving via (WrappedNum CSsize) instance Semiring CSsize
+deriving via (WrappedNum CTcflag) instance Semiring CTcflag
+deriving via (WrappedNum CUid) instance Semiring CUid
+deriving via (WrappedNum Fd) instance Semiring Fd
+#endif
+deriving via (WrappedNum Natural) instance Semiring Natural
+#else
+-- Integral and fieldlike instances
+$(let
+  deriveSemiring :: Q Type -> Q [Dec]
+  deriveSemiring ty = [d|
+      instance Semiring $ty where
+         zero  = 0
+         one   = 1
+         plus  x y = (Num.+) x y
+         times x y = (Num.*) x y
+         fromNatural = Real.fromIntegral
+         {-# INLINE zero #-}
+         {-# INLINE one  #-}
+         {-# INLINE plus #-}
+         {-# INLINE times #-}
+         {-# INLINE fromNatural #-}
+      |]
+
+  in P.concat P.<$> P.traverse deriveSemiring
+   [[t|Int|]
+   ,[t|Int8|]
+   ,[t|Int16|]
+   ,[t|Int32|]
+   ,[t|Int64|]
+   ,[t|Integer|]
+   ,[t|Word|]
+   ,[t|Word8|]
+   ,[t|Word16|]
+   ,[t|Word32|]
+   ,[t|Word64|]
+   ,[t|Float|]
+   ,[t|Double|]
+   ,[t|CUIntMax|]
+   ,[t|CIntMax|]
+   ,[t|CUIntPtr|]
+   ,[t|CIntPtr|]
+   ,[t|CSUSeconds|]
+   ,[t|CUSeconds|]
+   ,[t|CTime|]
+   ,[t|CClock|]
+   ,[t|CSigAtomic|]
+   ,[t|CWchar|]
+   ,[t|CSize|]
+   ,[t|CPtrdiff|]
+   ,[t|CDouble|]
+   ,[t|CFloat|]
+   ,[t|CULLong|]
+   ,[t|CLLong|]
+   ,[t|CULong|]
+   ,[t|CLong|]
+   ,[t|CUInt|]
+   ,[t|CInt|]
+   ,[t|CUShort|]
+   ,[t|CShort|]
+   ,[t|CUChar|]
+   ,[t|CSChar|]
+   ,[t|CChar|]
+   ,[t|IntPtr|]
+   ,[t|WordPtr|]
+#if !HOST_OS_WINDOWS
+   ,[t|CCc|]
+   ,[t|CDev|]
+   ,[t|CGid|]
+   ,[t|CIno|]
+   ,[t|CMode|]
+   ,[t|CNlink|]
+   ,[t|COff|]
+   ,[t|CPid|]
+   ,[t|CRLim|]
+   ,[t|CSpeed|]
+   ,[t|CSsize|]
+   ,[t|CTcflag|]
+   ,[t|CUid|]
+   ,[t|Fd|]
+#endif
+   ,[t|Natural|]
+   ])
+#endif
+
+#if MIN_VERSION_base(4,12,0)
+deriving via (WrappedNum Int) instance Ring Int
+deriving via (WrappedNum Int8) instance Ring Int8
+deriving via (WrappedNum Int16) instance Ring Int16
+deriving via (WrappedNum Int32) instance Ring Int32
+deriving via (WrappedNum Int64) instance Ring Int64
+deriving via (WrappedNum Integer) instance Ring Integer
+deriving via (WrappedNum Word) instance Ring Word
+deriving via (WrappedNum Word8) instance Ring Word8
+deriving via (WrappedNum Word16) instance Ring Word16
+deriving via (WrappedNum Word32) instance Ring Word32
+deriving via (WrappedNum Word64) instance Ring Word64
+deriving via (WrappedNum Float) instance Ring Float
+deriving via (WrappedNum Double) instance Ring Double
+deriving via (WrappedNum CUIntMax) instance Ring CUIntMax
+deriving via (WrappedNum CIntMax) instance Ring CIntMax
+deriving via (WrappedNum CUIntPtr) instance Ring CUIntPtr
+deriving via (WrappedNum CIntPtr) instance Ring CIntPtr
+deriving via (WrappedNum CSUSeconds) instance Ring CSUSeconds
+deriving via (WrappedNum CUSeconds) instance Ring CUSeconds
+deriving via (WrappedNum CTime) instance Ring CTime
+deriving via (WrappedNum CClock) instance Ring CClock
+deriving via (WrappedNum CSigAtomic) instance Ring CSigAtomic
+deriving via (WrappedNum CWchar) instance Ring CWchar
+deriving via (WrappedNum CSize) instance Ring CSize
+deriving via (WrappedNum CPtrdiff) instance Ring CPtrdiff
+deriving via (WrappedNum CDouble) instance Ring CDouble
+deriving via (WrappedNum CFloat) instance Ring CFloat
+deriving via (WrappedNum CULLong) instance Ring CULLong
+deriving via (WrappedNum CLLong) instance Ring CLLong
+deriving via (WrappedNum CULong) instance Ring CULong
+deriving via (WrappedNum CLong) instance Ring CLong
+deriving via (WrappedNum CUInt) instance Ring CUInt
+deriving via (WrappedNum CInt) instance Ring CInt
+deriving via (WrappedNum CUShort) instance Ring CUShort
+deriving via (WrappedNum CShort) instance Ring CShort
+deriving via (WrappedNum CUChar) instance Ring CUChar
+deriving via (WrappedNum CSChar) instance Ring CSChar
+deriving via (WrappedNum CChar) instance Ring CChar
+deriving via (WrappedNum IntPtr) instance Ring IntPtr
+deriving via (WrappedNum WordPtr) instance Ring WordPtr
+
+#if !HOST_OS_WINDOWS
+deriving via (WrappedNum CCc) instance Ring CCc
+deriving via (WrappedNum CDev) instance Ring CDev
+deriving via (WrappedNum CGid) instance Ring CGid
+deriving via (WrappedNum CIno) instance Ring CIno
+deriving via (WrappedNum CMode) instance Ring CMode
+deriving via (WrappedNum CNlink) instance Ring CNlink
+deriving via (WrappedNum COff) instance Ring COff
+deriving via (WrappedNum CPid) instance Ring CPid
+deriving via (WrappedNum CRLim) instance Ring CRLim
+deriving via (WrappedNum CSpeed) instance Ring CSpeed
+deriving via (WrappedNum CSsize) instance Ring CSsize
+deriving via (WrappedNum CTcflag) instance Ring CTcflag
+deriving via (WrappedNum CUid) instance Ring CUid
+deriving via (WrappedNum Fd) instance Ring Fd
+#endif
+#else
+$(let
+  deriveRing :: Q Type -> Q [Dec]
+  deriveRing ty = [d|
+      instance Ring $ty where
+        negate = Num.negate
+        {-# INLINE negate #-}
+      |]
+
+  in P.concat P.<$> P.traverse deriveRing
+    [[t|Int|]
+    ,[t|Int8|]
+    ,[t|Int16|]
+    ,[t|Int32|]
+    ,[t|Int64|]
+    ,[t|Integer|]
+    ,[t|Word|]
+    ,[t|Word8|]
+    ,[t|Word16|]
+    ,[t|Word32|]
+    ,[t|Word64|]
+    ,[t|Float|]
+    ,[t|Double|]
+    ,[t|CUIntMax|]
+    ,[t|CIntMax|]
+    ,[t|CUIntPtr|]
+    ,[t|CIntPtr|]
+    ,[t|CSUSeconds|]
+    ,[t|CUSeconds|]
+    ,[t|CTime|]
+    ,[t|CClock|]
+    ,[t|CSigAtomic|]
+    ,[t|CWchar|]
+    ,[t|CSize|]
+    ,[t|CPtrdiff|]
+    ,[t|CDouble|]
+    ,[t|CFloat|]
+    ,[t|CULLong|]
+    ,[t|CLLong|]
+    ,[t|CULong|]
+    ,[t|CLong|]
+    ,[t|CUInt|]
+    ,[t|CInt|]
+    ,[t|CUShort|]
+    ,[t|CShort|]
+    ,[t|CUChar|]
+    ,[t|CSChar|]
+    ,[t|CChar|]
+    ,[t|IntPtr|]
+    ,[t|WordPtr|]
+
+#if !HOST_OS_WINDOWS
+    ,[t|CCc|]
+    ,[t|CDev|]
+    ,[t|CGid|]
+    ,[t|CIno|]
+    ,[t|CMode|]
+    ,[t|CNlink|]
+    ,[t|COff|]
+    ,[t|CPid|]
+    ,[t|CRLim|]
+    ,[t|CSpeed|]
+    ,[t|CSsize|]
+    ,[t|CTcflag|]
+    ,[t|CUid|]
+    ,[t|Fd|]
+#endif
+    ])
+#endif
diff --git a/Data/Semiring/Tropical.hs b/Data/Semiring/Tropical.hs
--- a/Data/Semiring/Tropical.hs
+++ b/Data/Semiring/Tropical.hs
@@ -103,11 +103,11 @@
 instance forall e a. (Ord a, Extremum e) => Ord (Tropical e a) where
   compare Infinity Infinity         = EQ
   compare Infinity _                = case extremum (EProxy :: EProxy e) of
-    Minima -> LT
-    Maxima -> GT
-  compare _ Infinity                = case extremum (EProxy :: EProxy e) of
     Minima -> GT
     Maxima -> LT
+  compare _ Infinity                = case extremum (EProxy :: EProxy e) of
+    Minima -> LT
+    Maxima -> GT
   compare (Tropical x) (Tropical y) = compare x y
 
 instance forall e a. (Ord a, Monoid.Monoid a, Extremum e) => Semiring (Tropical e a) where
diff --git a/semirings.cabal b/semirings.cabal
--- a/semirings.cabal
+++ b/semirings.cabal
@@ -1,6 +1,6 @@
 name:          semirings
 category:      Algebra, Data, Data Structures, Math, Maths, Mathematics
-version:       0.5.4
+version:       0.6
 license:       BSD3
 cabal-version: >= 1.10
 license-file:  LICENSE
@@ -34,23 +34,13 @@
              , GHC == 8.2.2
              , GHC == 8.4.4
              , GHC == 8.6.5
-             , GHC == 8.8.3
-             , GHC == 8.10.1
+             , GHC == 8.8.4
+             , GHC == 8.10.2
 
 source-repository head
   type: git
   location: git://github.com/chessai/semirings.git
 
-flag hashable
-  description:
-    You can disable the use of the `hashable` package using `-f-hashable`.
-    .
-    Disabling this may be useful for accelerating builds in sandboxes for expert users.
-    .
-    Note: `-f-hashable` implies `-f-unordered-containers`, as we are necessarily not able to supply those instances as well.
-  default: True
-  manual: True
-
 flag containers
   description:
     You can disable the use of the `containers` package using `-f-containers`.
@@ -74,7 +64,6 @@
   build-depends:
       base >= 4.8 && < 5
     , base-compat-batteries
-    , integer-gmp >= 0.1.0.0
   exposed-modules:
     Data.Euclidean
     Data.Field
@@ -83,14 +72,13 @@
     Data.Semiring.Tropical
     Data.Semiring.Generic
 
+  if impl(ghc < 8.6.1)
+    build-depends: template-haskell >= 2.4.0.0
+
   if flag(containers)
     build-depends: containers >= 0.5.4 && < 0.7
 
-  if flag(hashable)
-    build-depends: hashable >= 1.1  && < 1.4
-
-  if flag(hashable)
-    build-depends: hashable >= 1.1  && < 1.4
-
-  if flag(hashable) && flag(unordered-containers)
-    build-depends: unordered-containers >= 0.2  && < 0.3
+  if flag(unordered-containers)
+    build-depends:
+        hashable >= 1.1  && < 1.4
+      , unordered-containers >= 0.2  && < 0.3
