{"action":"created","issue":{"url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/1707","labels_url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/1707/labels{/name}","comments_url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/1707/comments","events_url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/1707/events","html_url":"https://github.com/DynamoRIO/dynamorio/issues/1707","id":88798225,"number":1707,"title":"dr_insert_clean_call creates non-encodable instruction","user":{"login":"algr","id":7426743,"avatar_url":"https://avatars.githubusercontent.com/u/7426743?v=3","gravatar_id":"","url":"https://api.github.com/users/algr","html_url":"https://github.com/algr","followers_url":"https://api.github.com/users/algr/followers","following_url":"https://api.github.com/users/algr/following{/other_user}","gists_url":"https://api.github.com/users/algr/gists{/gist_id}","starred_url":"https://api.github.com/users/algr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/algr/subscriptions","organizations_url":"https://api.github.com/users/algr/orgs","repos_url":"https://api.github.com/users/algr/repos","events_url":"https://api.github.com/users/algr/events{/privacy}","received_events_url":"https://api.github.com/users/algr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-06-16T18:05:07Z","updated_at":"2015-06-18T21:55:52Z","closed_at":null,"body":"In 64-bit mode\r\n```\r\n    dr_insert_clean_call(drcontext, ilist, where, (void *)clean_call_mem,\r\n        false, 3,\r\n        OPND_CREATE_INT32(write),\r\n        opnd_create_pc(instr_get_app_pc(where)),\r\n        opnd_create_reg(reg1));\r\n```\r\nthe second operand creates\r\n```\r\nmov    $0x00007ff7a71a3213 -> %rsi\r\n```\r\nwhich doesn't encode.  The call to dr_insert_clean_call succeeds (i.e. doesn't assert) in debug mode.  Subsequent attempts to encode or disassemble the instrumented block fail.\r\n\r\nI guess it's expected that dr_insert_clean_call will insert only encodable instructions?\r\n\r\nAnd surely this should encode in 64-bit mode, to 'movabs' (aka 'movabsq'), 0x48 0xbe ..."},"comment":{"url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/comments/113299983","html_url":"https://github.com/DynamoRIO/dynamorio/issues/1707#issuecomment-113299983","issue_url":"https://api.github.com/repos/DynamoRIO/dynamorio/issues/1707","id":113299983,"user":{"login":"zhaoqin","id":1645580,"avatar_url":"https://avatars.githubusercontent.com/u/1645580?v=3","gravatar_id":"","url":"https://api.github.com/users/zhaoqin","html_url":"https://github.com/zhaoqin","followers_url":"https://api.github.com/users/zhaoqin/followers","following_url":"https://api.github.com/users/zhaoqin/following{/other_user}","gists_url":"https://api.github.com/users/zhaoqin/gists{/gist_id}","starred_url":"https://api.github.com/users/zhaoqin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhaoqin/subscriptions","organizations_url":"https://api.github.com/users/zhaoqin/orgs","repos_url":"https://api.github.com/users/zhaoqin/repos","events_url":"https://api.github.com/users/zhaoqin/events{/privacy}","received_events_url":"https://api.github.com/users/zhaoqin/received_events","type":"User","site_admin":false},"created_at":"2015-06-18T21:55:52Z","updated_at":"2015-06-18T21:55:52Z","body":"From asm code, the PC and int does look the same.\r\nTo distinguish the two, I guess we can\r\n- either print type info for each opnd\r\n- or using hex for pc and decimal for int."}}