{"action":"created","issue":{"url":"https://api.github.com/repos/KhronosGroup/glslang/issues/316","repository_url":"https://api.github.com/repos/KhronosGroup/glslang","labels_url":"https://api.github.com/repos/KhronosGroup/glslang/issues/316/labels{/name}","comments_url":"https://api.github.com/repos/KhronosGroup/glslang/issues/316/comments","events_url":"https://api.github.com/repos/KhronosGroup/glslang/issues/316/events","html_url":"https://github.com/KhronosGroup/glslang/issues/316","id":157778210,"number":316,"title":"Changing SPIR-V default to no debug names. Does this break anything?","user":{"login":"johnkslang","id":5607714,"avatar_url":"https://avatars.githubusercontent.com/u/5607714?v=3","gravatar_id":"","url":"https://api.github.com/users/johnkslang","html_url":"https://github.com/johnkslang","followers_url":"https://api.github.com/users/johnkslang/followers","following_url":"https://api.github.com/users/johnkslang/following{/other_user}","gists_url":"https://api.github.com/users/johnkslang/gists{/gist_id}","starred_url":"https://api.github.com/users/johnkslang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnkslang/subscriptions","organizations_url":"https://api.github.com/users/johnkslang/orgs","repos_url":"https://api.github.com/users/johnkslang/repos","events_url":"https://api.github.com/users/johnkslang/events{/privacy}","received_events_url":"https://api.github.com/users/johnkslang/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/KhronosGroup/glslang/labels/question","name":"question","color":"cc317c"},{"url":"https://api.github.com/repos/KhronosGroup/glslang/labels/SPIR-V","name":"SPIR-V","color":"0052cc"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-05-31T21:46:47Z","updated_at":"2016-06-03T13:26:50Z","closed_at":null,"body":"Glslang currently includes **OpName** debug instructions in generated SPIR-V, by default.\r\n\r\nThe default should be to not include these; when needed, it should be requested.  Note the specification says:\r\n\r\n>  This has no semantic impact and can safely be removed from a module.\r\n\r\nGlslang should help ensure nothing accidentally depends on this, as well as generate smaller SPIR-V files by default. (There have been some reports of accidental dependence on debug information.)\r\n\r\nAre there any concerns with changing this default?\r\n\r\nOr, what options should be employed to generate debug information?\r\n"},"comment":{"url":"https://api.github.com/repos/KhronosGroup/glslang/issues/comments/223578102","html_url":"https://github.com/KhronosGroup/glslang/issues/316#issuecomment-223578102","issue_url":"https://api.github.com/repos/KhronosGroup/glslang/issues/316","id":223578102,"user":{"login":"baldurk","id":661798,"avatar_url":"https://avatars.githubusercontent.com/u/661798?v=3","gravatar_id":"","url":"https://api.github.com/users/baldurk","html_url":"https://github.com/baldurk","followers_url":"https://api.github.com/users/baldurk/followers","following_url":"https://api.github.com/users/baldurk/following{/other_user}","gists_url":"https://api.github.com/users/baldurk/gists{/gist_id}","starred_url":"https://api.github.com/users/baldurk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baldurk/subscriptions","organizations_url":"https://api.github.com/users/baldurk/orgs","repos_url":"https://api.github.com/users/baldurk/repos","events_url":"https://api.github.com/users/baldurk/events{/privacy}","received_events_url":"https://api.github.com/users/baldurk/received_events","type":"User","site_admin":false},"created_at":"2016-06-03T13:26:50Z","updated_at":"2016-06-03T13:26:50Z","body":":+1: to the above from a debugging standpoint. Having naming information makes frame debugging _much_ easier.\r\n\r\nPotentially a middle ground would be only naming externally visible objects, like input/output structures, bound resources, entry point, etc and stripping the naming of local variables. That still does decrease the quality of the output of SPIRV-Cross and other tools for generating human-readable representations of the SPIR-V, so I would remain in favour of keeping the behaviour as-is by default.\r\n\r\nFWIW looking at the D3D compiler, it will emit the equivalent of global OpName information for reflection by default and you have to pass a command switch / flag bit to strip that data out. It also provides functionality for stripping the data out of an already compiled blob. What you need to opt-in to is including verbose debugging information where e.g. the source files are included verbatim and line number information is provided - which AFAIK glslang does not support yet. But making that opt-in is a no-brainer :smile:."}}
{"actor":{"display_login":"baldurk"}}