{"action":"created","issue":{"url":"https://api.github.com/repos/pg-strom/devel/issues/294","repository_url":"https://api.github.com/repos/pg-strom/devel","labels_url":"https://api.github.com/repos/pg-strom/devel/issues/294/labels{/name}","comments_url":"https://api.github.com/repos/pg-strom/devel/issues/294/comments","events_url":"https://api.github.com/repos/pg-strom/devel/issues/294/events","html_url":"https://github.com/pg-strom/devel/issues/294","id":242881146,"number":294,"title":"(JP) gpuMemAlloc() / gpuMemFree() アプリケーション側での管理","user":{"login":"kaigai","id":216210,"avatar_url":"https://avatars5.githubusercontent.com/u/216210?v=3","gravatar_id":"","url":"https://api.github.com/users/kaigai","html_url":"https://github.com/kaigai","followers_url":"https://api.github.com/users/kaigai/followers","following_url":"https://api.github.com/users/kaigai/following{/other_user}","gists_url":"https://api.github.com/users/kaigai/gists{/gist_id}","starred_url":"https://api.github.com/users/kaigai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaigai/subscriptions","organizations_url":"https://api.github.com/users/kaigai/orgs","repos_url":"https://api.github.com/users/kaigai/repos","events_url":"https://api.github.com/users/kaigai/events{/privacy}","received_events_url":"https://api.github.com/users/kaigai/received_events","type":"User","site_admin":false},"labels":[{"id":91154848,"url":"https://api.github.com/repos/pg-strom/devel/labels/feature","name":"feature","color":"84b6eb","default":false},{"id":645870284,"url":"https://api.github.com/repos/pg-strom/devel/labels/v2.0","name":"v2.0","color":"d93f0b","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/pg-strom/devel/milestones/1","html_url":"https://github.com/pg-strom/devel/milestone/1","labels_url":"https://api.github.com/repos/pg-strom/devel/milestones/1/labels","id":2638088,"number":1,"title":"PG-Strom v2.0雑多な改善","description":"PG-Strom v2.0に向けたその他の改善項目","creator":{"login":"kaigai","id":216210,"avatar_url":"https://avatars5.githubusercontent.com/u/216210?v=3","gravatar_id":"","url":"https://api.github.com/users/kaigai","html_url":"https://github.com/kaigai","followers_url":"https://api.github.com/users/kaigai/followers","following_url":"https://api.github.com/users/kaigai/following{/other_user}","gists_url":"https://api.github.com/users/kaigai/gists{/gist_id}","starred_url":"https://api.github.com/users/kaigai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaigai/subscriptions","organizations_url":"https://api.github.com/users/kaigai/orgs","repos_url":"https://api.github.com/users/kaigai/repos","events_url":"https://api.github.com/users/kaigai/events{/privacy}","received_events_url":"https://api.github.com/users/kaigai/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":0,"state":"open","created_at":"2017-07-13T01:25:05Z","updated_at":"2017-07-14T02:35:30Z","due_on":null,"closed_at":null},"comments":0,"created_at":"2017-07-14T02:35:30Z","updated_at":"2017-07-14T02:48:21Z","closed_at":null,"body":"cuMemAlloc() と、特にメモリチャンク数が多くなってきた時の gpuMemFree() のパフォーマンスが惨い。\r\n\r\n```\r\ntv_process_task = 35.663 46.375 7.071 34.835\r\n```\r\nprocess_task 35.663s 中 7.071s がcuMemAlloc()\r\n\r\ncomplete_task 46.375s 中 34.835s がcuMemFree()\r\n\r\nどうせGPU ServerでGPU Contextは使い回すので、デバイス側のメモリ保護は効かない。\r\n1GBみたいなセグメントである程度粒度の大きなアロケーションを行う。"},"comment":{"url":"https://api.github.com/repos/pg-strom/devel/issues/comments/315255341","html_url":"https://github.com/pg-strom/devel/issues/294#issuecomment-315255341","issue_url":"https://api.github.com/repos/pg-strom/devel/issues/294","id":315255341,"user":{"login":"kaigai","id":216210,"avatar_url":"https://avatars5.githubusercontent.com/u/216210?v=3","gravatar_id":"","url":"https://api.github.com/users/kaigai","html_url":"https://github.com/kaigai","followers_url":"https://api.github.com/users/kaigai/followers","following_url":"https://api.github.com/users/kaigai/following{/other_user}","gists_url":"https://api.github.com/users/kaigai/gists{/gist_id}","starred_url":"https://api.github.com/users/kaigai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaigai/subscriptions","organizations_url":"https://api.github.com/users/kaigai/orgs","repos_url":"https://api.github.com/users/kaigai/repos","events_url":"https://api.github.com/users/kaigai/events{/privacy}","received_events_url":"https://api.github.com/users/kaigai/received_events","type":"User","site_admin":false},"created_at":"2017-07-14T02:48:21Z","updated_at":"2017-07-14T02:48:21Z","body":"Unified Memoryと、従来のDevice Memoryの使い分けを考える必要あり。\r\n\r\n予め必要サイズが固まっており、小さい：pds_src、kparams（PL/CUDA除く）\r\n⇒従来型の方がよい\r\n\r\n事前に必要サイズが分からない：pds_dst、kern_results\r\n⇒Unified Memoryがよい。各GpuTask毎に持つ必要はない。\r\n⇒GpuJoin以外はkern_resultsそれほど大きくないので、従来型でもよい。\r\n⇒GpuJoinの場合、kern_results溢れのリスクあり。Retryで救えるのでよいが。\r\n\r\nAlloc/Free頻度が低い：InnerBuffer、FinalBuffer\r\n⇒Unified Memoryがよい。"}}
{"actor":{"display_login":"kaigai"}}