{"action":"created","issue":{"url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/335","repository_url":"https://api.github.com/repos/AccelerateHS/accelerate","labels_url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/335/labels{/name}","comments_url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/335/comments","events_url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/335/events","html_url":"https://github.com/AccelerateHS/accelerate/issues/335","id":190199702,"number":335,"title":"Overlapping instances in accelerate-cuda AST","user":{"login":"djduke","id":15369151,"avatar_url":"https://avatars.githubusercontent.com/u/15369151?v=3","gravatar_id":"","url":"https://api.github.com/users/djduke","html_url":"https://github.com/djduke","followers_url":"https://api.github.com/users/djduke/followers","following_url":"https://api.github.com/users/djduke/following{/other_user}","gists_url":"https://api.github.com/users/djduke/gists{/gist_id}","starred_url":"https://api.github.com/users/djduke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djduke/subscriptions","organizations_url":"https://api.github.com/users/djduke/orgs","repos_url":"https://api.github.com/users/djduke/repos","events_url":"https://api.github.com/users/djduke/events{/privacy}","received_events_url":"https://api.github.com/users/djduke/received_events","type":"User","site_admin":false},"labels":[{"id":94371,"url":"https://api.github.com/repos/AccelerateHS/accelerate/labels/cuda%20backend","name":"cuda backend","color":"0b02e1","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-17T23:55:53Z","updated_at":"2016-12-02T05:02:31Z","closed_at":null,"body":"I'm getting an \"overlapping instances\" error when compiling using GHC HEAD (or at least version 8.1.20161012), see error log below.  On the assumption that the instance in Data.Array.Accelerate.CUDA.AST was intended to be more specific that that from Data.Array.Accelerate.Pretty, I tried to add an OVERLAPPING pragma, but this triggered a further type error in Accelerate.CUDA.CodeGen.Stencil.   I'm aware there have been some changes to the AST to accommodate e.g. deriving strategies; I had to update haskell-src-meta to allow it to compile, but unclear that it has any link with the overlapping issue.   Do you have a successful build of accelerate-cuda on OSX?\r\n\r\nregards, David.\r\n\r\n\r\n```\r\n[18 of 34] Compiling Data.Array.Accelerate.CUDA.AST ( Data/Array/Accelerate/CUDA/AST.hs, dist/build/Data/Array/Accelerate/CUDA/AST.o )\r\n\r\nData/Array/Accelerate/CUDA/AST.hs:152:10: error:\r\n    • Overlapping instances for Show (ExecAfun a)\r\n        arising from a use of ‘GHC.Show.$dmshowsPrec’\r\n      Matching instances:\r\n        instance (accelerate-1.0.0.0:Data.Array.Accelerate.Trafo.Base.Kit\r\n                    acc,\r\n                  PrettyEnv aenv) =>\r\n                 Show (PreOpenAfun acc aenv f)\r\n          -- Defined in ‘Data.Array.Accelerate.Pretty’\r\n        instance Show (ExecAfun a)\r\n          -- Defined at Data/Array/Accelerate/CUDA/AST.hs:152:10\r\n    • In the expression: GHC.Show.$dmshowsPrec @ExecAfun a\r\n      In an equation for ‘showsPrec’:\r\n          showsPrec = GHC.Show.$dmshowsPrec @ExecAfun a\r\n      In the instance declaration for ‘Show (ExecAfun a)’\r\n\r\nData/Array/Accelerate/CUDA/AST.hs:152:10: error:\r\n    • Overlapping instances for Show (ExecAfun a)\r\n        arising from a use of ‘GHC.Show.$dmshowList’\r\n      Matching instances:\r\n        instance (accelerate-1.0.0.0:Data.Array.Accelerate.Trafo.Base.Kit\r\n                    acc,\r\n                  PrettyEnv aenv) =>\r\n                 Show (PreOpenAfun acc aenv f)\r\n          -- Defined in ‘Data.Array.Accelerate.Pretty’\r\n        instance Show (ExecAfun a)\r\n          -- Defined at Data/Array/Accelerate/CUDA/AST.hs:152:10\r\n    • In the expression: GHC.Show.$dmshowList @ExecAfun a\r\n      In an equation for ‘showList’:\r\n          showList = GHC.Show.$dmshowList @ExecAfun a\r\n      In the instance declaration for ‘Show (ExecAfun a)’\r\n```"},"comment":{"url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/comments/264374014","html_url":"https://github.com/AccelerateHS/accelerate/issues/335#issuecomment-264374014","issue_url":"https://api.github.com/repos/AccelerateHS/accelerate/issues/335","id":264374014,"user":{"login":"tmcdonell","id":728113,"avatar_url":"https://avatars.githubusercontent.com/u/728113?v=3","gravatar_id":"","url":"https://api.github.com/users/tmcdonell","html_url":"https://github.com/tmcdonell","followers_url":"https://api.github.com/users/tmcdonell/followers","following_url":"https://api.github.com/users/tmcdonell/following{/other_user}","gists_url":"https://api.github.com/users/tmcdonell/gists{/gist_id}","starred_url":"https://api.github.com/users/tmcdonell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tmcdonell/subscriptions","organizations_url":"https://api.github.com/users/tmcdonell/orgs","repos_url":"https://api.github.com/users/tmcdonell/repos","events_url":"https://api.github.com/users/tmcdonell/events{/privacy}","received_events_url":"https://api.github.com/users/tmcdonell/received_events","type":"User","site_admin":false},"created_at":"2016-12-02T05:02:31Z","updated_at":"2016-12-02T05:02:31Z","body":"This might be a result of https://ghc.haskell.org/trac/ghc/ticket/12881.\r\n\r\nAdding an `{-# OVERLAPS #-}` pragma or similar allows it to proceed, but it falls over later with a different error. More investigation required..."}}
{"actor":{"display_login":"tmcdonell"}}