{"action":"created","issue":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/4218","repository_url":"https://api.github.com/repos/dolphin-emu/dolphin","labels_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/4218/labels{/name}","comments_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/4218/comments","events_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/4218/events","html_url":"https://github.com/dolphin-emu/dolphin/pull/4218","id":177334144,"number":4218,"title":"Fix a bunch of debugger stepping issues.","user":{"login":"aldelaro5","id":8932978,"avatar_url":"https://avatars.githubusercontent.com/u/8932978?v=3","gravatar_id":"","url":"https://api.github.com/users/aldelaro5","html_url":"https://github.com/aldelaro5","followers_url":"https://api.github.com/users/aldelaro5/followers","following_url":"https://api.github.com/users/aldelaro5/following{/other_user}","gists_url":"https://api.github.com/users/aldelaro5/gists{/gist_id}","starred_url":"https://api.github.com/users/aldelaro5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aldelaro5/subscriptions","organizations_url":"https://api.github.com/users/aldelaro5/orgs","repos_url":"https://api.github.com/users/aldelaro5/repos","events_url":"https://api.github.com/users/aldelaro5/events{/privacy}","received_events_url":"https://api.github.com/users/aldelaro5/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":30,"created_at":"2016-09-16T02:39:17Z","updated_at":"2016-09-29T20:59:34Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/pulls/4218","html_url":"https://github.com/dolphin-emu/dolphin/pull/4218","diff_url":"https://github.com/dolphin-emu/dolphin/pull/4218.diff","patch_url":"https://github.com/dolphin-emu/dolphin/pull/4218.patch"},"body":"Here are the summary of the changes:\r\n\r\n- Single step: Fix an oddity when a breakpoint is hit at the beginning of a block, then after, a single step is performed and finally, hitting play, the breakpoint will be skipped even in the case when it would be hit again.  This was done by using the interpreter version of single step.  Also, remove some redundant update request.\r\n- Step over: fix some GUI lags. due to redundant draw calls.\r\n- Step out: Add consideration for conditional branching by checking the condition as the interpreter does.  Now, every bclr instructions except those that changes the LR (because it would not be the end of the function) will cause the end of the step out and not just blr instructions.  Also now stops if a bp is detected and finally, remove redundant GUI updates calls.\r\n\r\nThis also removes a superfluous draw call on the GUI as the codeView was refreshing twice per event to do so.  This fixes possible flickering, especially noticeable when stepping over branches.\r\n\r\nAnd as for the isBclr, it checks the right opcode and a bit that should be on if it is a bclr.\r\n\r\n<!-- Reviewable:start -->\r\n---\r\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"34\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/dolphin-emu/dolphin/4218)\r\n<!-- Reviewable:end -->\r\n"},"comment":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/comments/250589635","html_url":"https://github.com/dolphin-emu/dolphin/pull/4218#issuecomment-250589635","issue_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/4218","id":250589635,"user":{"login":"sepalani","id":7890055,"avatar_url":"https://avatars.githubusercontent.com/u/7890055?v=3","gravatar_id":"","url":"https://api.github.com/users/sepalani","html_url":"https://github.com/sepalani","followers_url":"https://api.github.com/users/sepalani/followers","following_url":"https://api.github.com/users/sepalani/following{/other_user}","gists_url":"https://api.github.com/users/sepalani/gists{/gist_id}","starred_url":"https://api.github.com/users/sepalani/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sepalani/subscriptions","organizations_url":"https://api.github.com/users/sepalani/orgs","repos_url":"https://api.github.com/users/sepalani/repos","events_url":"https://api.github.com/users/sepalani/events{/privacy}","received_events_url":"https://api.github.com/users/sepalani/received_events","type":"User","site_admin":false},"created_at":"2016-09-29T20:59:34Z","updated_at":"2016-09-29T20:59:34Z","body":"\n\n\n\n\n\n\n\n*[Source/Core/DolphinWX/Debugger/CodeWindow.cpp, line 329 at r6](https://reviewable.io:443/reviews/dolphin-emu/dolphin/4218#-KSrfgf2L_rlANsdnFQ_:-KSrfgf3a4WA1RpWVpgl:bnwmp0t) ([raw file](https://github.com/dolphin-emu/dolphin/blob/20584586fa063e60f7a531eed02bfac9b71766cf/Source/Core/DolphinWX/Debugger/CodeWindow.cpp#L329)):*\n> ```cpp\n> {\n>   bool counter = (inst.BO_2 >> 2 & 1) != 0 || (CTR != 0) != ((inst.BO_2 >> 1 & 1) != 0);\n>   bool condition = (inst.BO_2 >> 4) != 0 || (GetCRBit(inst.BI_2) == ((inst.BO_2 >> 3) & 1));\n> ```\n\nThere are unnecessary parentheses here:\n```C++\nbool condition = inst.BO_2 >> 4 != 0 || GetCRBit(inst.BI_2) == (inst.BO_2 >> 3 & 1);\n```\n\nDitto for ```isBclr```:\n```C++\nbool isBclr = inst.OPCD_7 == 0b010011 && (inst.hex >> 1 & 0b10000) != 0;\n```\n\nOtherwise LGTM. If you want to keep those the sake of readability I don't mind either. \n\n---\n\n\n*Comments from [Reviewable](https://reviewable.io:443/reviews/dolphin-emu/dolphin/4218)*\n<!-- Sent from Reviewable.io -->\n"}}
{"actor":{"display_login":"sepalani"}}