{"action":"created","comment":{"url":"https://api.github.com/repos/nodejs/node/pulls/comments/46501966","id":46501966,"diff_hunk":"@@ -551,18 +551,15 @@ def cc_macros(cc=None):\n def is_arch_armv7():\n   \"\"\"Check for ARMv7 instructions\"\"\"\n   cc_macros_cache = cc_macros()\n-  return ('__ARM_ARCH_7__' in cc_macros_cache or\n-          '__ARM_ARCH_7A__' in cc_macros_cache or\n-          '__ARM_ARCH_7R__' in cc_macros_cache or\n-          '__ARM_ARCH_7M__' in cc_macros_cache or\n-          '__ARM_ARCH_7S__' in cc_macros_cache)\n+  return ('__ARM_ARCH' in cc_macros_cache and\n+          cc_macros_cache['__ARM_ARCH'] == '7')","path":"configure","position":10,"original_position":10,"commit_id":"ff3b1f0c9858653bf6dda9fc99de8dc72cd9d951","original_commit_id":"ff3b1f0c9858653bf6dda9fc99de8dc72cd9d951","user":{"login":"bnoordhuis","id":275871,"avatar_url":"https://avatars.githubusercontent.com/u/275871?v=3","gravatar_id":"","url":"https://api.github.com/users/bnoordhuis","html_url":"https://github.com/bnoordhuis","followers_url":"https://api.github.com/users/bnoordhuis/followers","following_url":"https://api.github.com/users/bnoordhuis/following{/other_user}","gists_url":"https://api.github.com/users/bnoordhuis/gists{/gist_id}","starred_url":"https://api.github.com/users/bnoordhuis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bnoordhuis/subscriptions","organizations_url":"https://api.github.com/users/bnoordhuis/orgs","repos_url":"https://api.github.com/users/bnoordhuis/repos","events_url":"https://api.github.com/users/bnoordhuis/events{/privacy}","received_events_url":"https://api.github.com/users/bnoordhuis/received_events","type":"User","site_admin":false},"body":"You could simplify this to `return cc_macros_cache.get('__ARM_ARCH') == '7'`.","created_at":"2015-12-03T01:18:59Z","updated_at":"2015-12-03T01:18:59Z","html_url":"https://github.com/nodejs/node/pull/4123#discussion_r46501966","pull_request_url":"https://api.github.com/repos/nodejs/node/pulls/4123","_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments/46501966"},"html":{"href":"https://github.com/nodejs/node/pull/4123#discussion_r46501966"},"pull_request":{"href":"https://api.github.com/repos/nodejs/node/pulls/4123"}}},"pull_request":{"url":"https://api.github.com/repos/nodejs/node/pulls/4123","id":52446857,"html_url":"https://github.com/nodejs/node/pull/4123","diff_url":"https://github.com/nodejs/node/pull/4123.diff","patch_url":"https://github.com/nodejs/node/pull/4123.patch","issue_url":"https://api.github.com/repos/nodejs/node/issues/4123","number":4123,"state":"open","locked":false,"title":"configure: use __ARM_ARCH to determine arm version","user":{"login":"joaocgreis","id":134460,"avatar_url":"https://avatars.githubusercontent.com/u/134460?v=3","gravatar_id":"","url":"https://api.github.com/users/joaocgreis","html_url":"https://github.com/joaocgreis","followers_url":"https://api.github.com/users/joaocgreis/followers","following_url":"https://api.github.com/users/joaocgreis/following{/other_user}","gists_url":"https://api.github.com/users/joaocgreis/gists{/gist_id}","starred_url":"https://api.github.com/users/joaocgreis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joaocgreis/subscriptions","organizations_url":"https://api.github.com/users/joaocgreis/orgs","repos_url":"https://api.github.com/users/joaocgreis/repos","events_url":"https://api.github.com/users/joaocgreis/events{/privacy}","received_events_url":"https://api.github.com/users/joaocgreis/received_events","type":"User","site_admin":false},"body":"Before this change, configure used processor specific macro defines (like `__ARM_ARCH_6M__`) to detect the arm processor version. This changes configure to use `__ARM_ARCH`, that should be defined to the correct version.\r\n\r\nThis is useful because configure may not expect the flag for a specific processor. Currently, if trying to cross compile optimizing to the Raspberry Pi 1 processor with `-mcpu=arm1176jzf-s` the detected `arm_version` will be `default` (because it sets`__ARM_ARCH_6ZK__`), and the generated binaries useless in that processor.\r\n\r\n@nodejs/platform-arm ARM processors currently on CI are ok with this change, but could there be some other processor or compiler that does not set `__ARM_ARCH` or sets it to something that we do not want? @mmalecki you authored the original function, do you know of any problem with this? (Thanks!)\r\n\r\ncc @nodejs/build \r\n\r\nFor reference:\r\n```\r\n$ echo | arm-linux-gnueabihf-gcc -dM -E - | grep ARM_ARCH\r\n#define __ARM_ARCH_ISA_ARM 1\r\n#define __ARM_ARCH_6__ 1\r\n#define __ARM_ARCH_ISA_THUMB 1\r\n#define __ARM_ARCH 6\r\n$ echo | arm-linux-gnueabihf-gcc -mcpu=arm1176jzf-s -dM -E - | grep ARM_ARCH\r\n#define __ARM_ARCH_ISA_ARM 1\r\n#define __ARM_ARCH_ISA_THUMB 1\r\n#define __ARM_ARCH 6\r\n#define __ARM_ARCH_6ZK__ 1\r\n$ echo | arm-linux-gnueabihf-gcc -mcpu=cortex-a7 -dM -E - | grep ARM_ARCH                                                    \r\n#define __ARM_ARCH_ISA_ARM 1\r\n#define __ARM_ARCH_PROFILE 65\r\n#define __ARM_ARCH_ISA_THUMB 2\r\n#define __ARM_ARCH 7\r\n#define __ARM_ARCH_7A__ 1\r\n#define __ARM_ARCH_EXT_IDIV__ 1\r\n```\r\n","created_at":"2015-12-02T20:05:46Z","updated_at":"2015-12-03T01:18:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bdd263eccebcdf9d5a8e4c5928a3df13c1430d3b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/nodejs/node/pulls/4123/commits","review_comments_url":"https://api.github.com/repos/nodejs/node/pulls/4123/comments","review_comment_url":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nodejs/node/issues/4123/comments","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/ff3b1f0c9858653bf6dda9fc99de8dc72cd9d951","head":{"label":"janeasystems:joaocgreis-FC2-__ARM_ARCH","ref":"joaocgreis-FC2-__ARM_ARCH","sha":"ff3b1f0c9858653bf6dda9fc99de8dc72cd9d951","user":{"login":"janeasystems","id":9194778,"avatar_url":"https://avatars.githubusercontent.com/u/9194778?v=3","gravatar_id":"","url":"https://api.github.com/users/janeasystems","html_url":"https://github.com/janeasystems","followers_url":"https://api.github.com/users/janeasystems/followers","following_url":"https://api.github.com/users/janeasystems/following{/other_user}","gists_url":"https://api.github.com/users/janeasystems/gists{/gist_id}","starred_url":"https://api.github.com/users/janeasystems/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janeasystems/subscriptions","organizations_url":"https://api.github.com/users/janeasystems/orgs","repos_url":"https://api.github.com/users/janeasystems/repos","events_url":"https://api.github.com/users/janeasystems/events{/privacy}","received_events_url":"https://api.github.com/users/janeasystems/received_events","type":"Organization","site_admin":false},"repo":{"id":36501512,"name":"node","full_name":"janeasystems/node","owner":{"login":"janeasystems","id":9194778,"avatar_url":"https://avatars.githubusercontent.com/u/9194778?v=3","gravatar_id":"","url":"https://api.github.com/users/janeasystems","html_url":"https://github.com/janeasystems","followers_url":"https://api.github.com/users/janeasystems/followers","following_url":"https://api.github.com/users/janeasystems/following{/other_user}","gists_url":"https://api.github.com/users/janeasystems/gists{/gist_id}","starred_url":"https://api.github.com/users/janeasystems/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janeasystems/subscriptions","organizations_url":"https://api.github.com/users/janeasystems/orgs","repos_url":"https://api.github.com/users/janeasystems/repos","events_url":"https://api.github.com/users/janeasystems/events{/privacy}","received_events_url":"https://api.github.com/users/janeasystems/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/janeasystems/node","description":"Node.js, but with bigger and faster version numbers","fork":true,"url":"https://api.github.com/repos/janeasystems/node","forks_url":"https://api.github.com/repos/janeasystems/node/forks","keys_url":"https://api.github.com/repos/janeasystems/node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/janeasystems/node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/janeasystems/node/teams","hooks_url":"https://api.github.com/repos/janeasystems/node/hooks","issue_events_url":"https://api.github.com/repos/janeasystems/node/issues/events{/number}","events_url":"https://api.github.com/repos/janeasystems/node/events","assignees_url":"https://api.github.com/repos/janeasystems/node/assignees{/user}","branches_url":"https://api.github.com/repos/janeasystems/node/branches{/branch}","tags_url":"https://api.github.com/repos/janeasystems/node/tags","blobs_url":"https://api.github.com/repos/janeasystems/node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/janeasystems/node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/janeasystems/node/git/refs{/sha}","trees_url":"https://api.github.com/repos/janeasystems/node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/janeasystems/node/statuses/{sha}","languages_url":"https://api.github.com/repos/janeasystems/node/languages","stargazers_url":"https://api.github.com/repos/janeasystems/node/stargazers","contributors_url":"https://api.github.com/repos/janeasystems/node/contributors","subscribers_url":"https://api.github.com/repos/janeasystems/node/subscribers","subscription_url":"https://api.github.com/repos/janeasystems/node/subscription","commits_url":"https://api.github.com/repos/janeasystems/node/commits{/sha}","git_commits_url":"https://api.github.com/repos/janeasystems/node/git/commits{/sha}","comments_url":"https://api.github.com/repos/janeasystems/node/comments{/number}","issue_comment_url":"https://api.github.com/repos/janeasystems/node/issues/comments{/number}","contents_url":"https://api.github.com/repos/janeasystems/node/contents/{+path}","compare_url":"https://api.github.com/repos/janeasystems/node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/janeasystems/node/merges","archive_url":"https://api.github.com/repos/janeasystems/node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/janeasystems/node/downloads","issues_url":"https://api.github.com/repos/janeasystems/node/issues{/number}","pulls_url":"https://api.github.com/repos/janeasystems/node/pulls{/number}","milestones_url":"https://api.github.com/repos/janeasystems/node/milestones{/number}","notifications_url":"https://api.github.com/repos/janeasystems/node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/janeasystems/node/labels{/name}","releases_url":"https://api.github.com/repos/janeasystems/node/releases{/id}","created_at":"2015-05-29T11:56:02Z","updated_at":"2015-09-05T00:44:41Z","pushed_at":"2015-12-02T19:40:12Z","git_url":"git://github.com/janeasystems/node.git","ssh_url":"git@github.com:janeasystems/node.git","clone_url":"https://github.com/janeasystems/node.git","svn_url":"https://github.com/janeasystems/node","homepage":"https://iojs.org","size":158799,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"nodejs:master","ref":"master","sha":"b619831381a3a93e64e963b7bd95adc4df2eafe7","user":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"repo":{"id":27193779,"name":"node","full_name":"nodejs/node","owner":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nodejs/node","description":"Node.js JavaScript runtime :sparkles::turtle::rocket::sparkles:","fork":false,"url":"https://api.github.com/repos/nodejs/node","forks_url":"https://api.github.com/repos/nodejs/node/forks","keys_url":"https://api.github.com/repos/nodejs/node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nodejs/node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nodejs/node/teams","hooks_url":"https://api.github.com/repos/nodejs/node/hooks","issue_events_url":"https://api.github.com/repos/nodejs/node/issues/events{/number}","events_url":"https://api.github.com/repos/nodejs/node/events","assignees_url":"https://api.github.com/repos/nodejs/node/assignees{/user}","branches_url":"https://api.github.com/repos/nodejs/node/branches{/branch}","tags_url":"https://api.github.com/repos/nodejs/node/tags","blobs_url":"https://api.github.com/repos/nodejs/node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nodejs/node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nodejs/node/git/refs{/sha}","trees_url":"https://api.github.com/repos/nodejs/node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/{sha}","languages_url":"https://api.github.com/repos/nodejs/node/languages","stargazers_url":"https://api.github.com/repos/nodejs/node/stargazers","contributors_url":"https://api.github.com/repos/nodejs/node/contributors","subscribers_url":"https://api.github.com/repos/nodejs/node/subscribers","subscription_url":"https://api.github.com/repos/nodejs/node/subscription","commits_url":"https://api.github.com/repos/nodejs/node/commits{/sha}","git_commits_url":"https://api.github.com/repos/nodejs/node/git/commits{/sha}","comments_url":"https://api.github.com/repos/nodejs/node/comments{/number}","issue_comment_url":"https://api.github.com/repos/nodejs/node/issues/comments{/number}","contents_url":"https://api.github.com/repos/nodejs/node/contents/{+path}","compare_url":"https://api.github.com/repos/nodejs/node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nodejs/node/merges","archive_url":"https://api.github.com/repos/nodejs/node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nodejs/node/downloads","issues_url":"https://api.github.com/repos/nodejs/node/issues{/number}","pulls_url":"https://api.github.com/repos/nodejs/node/pulls{/number}","milestones_url":"https://api.github.com/repos/nodejs/node/milestones{/number}","notifications_url":"https://api.github.com/repos/nodejs/node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nodejs/node/labels{/name}","releases_url":"https://api.github.com/repos/nodejs/node/releases{/id}","created_at":"2014-11-26T19:57:11Z","updated_at":"2015-12-03T00:09:31Z","pushed_at":"2015-12-03T00:01:34Z","git_url":"git://github.com/nodejs/node.git","ssh_url":"git@github.com:nodejs/node.git","clone_url":"https://github.com/nodejs/node.git","svn_url":"https://github.com/nodejs/node","homepage":"https://nodejs.org","size":175925,"stargazers_count":17855,"watchers_count":17855,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1923,"mirror_url":null,"open_issues_count":607,"forks":1923,"open_issues":607,"watchers":17855,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/4123"},"html":{"href":"https://github.com/nodejs/node/pull/4123"},"issue":{"href":"https://api.github.com/repos/nodejs/node/issues/4123"},"comments":{"href":"https://api.github.com/repos/nodejs/node/issues/4123/comments"},"review_comments":{"href":"https://api.github.com/repos/nodejs/node/pulls/4123/comments"},"review_comment":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nodejs/node/pulls/4123/commits"},"statuses":{"href":"https://api.github.com/repos/nodejs/node/statuses/ff3b1f0c9858653bf6dda9fc99de8dc72cd9d951"}}}}