{"action":"created","issue":{"url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/29","repository_url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain","labels_url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/29/labels{/name}","comments_url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/29/comments","events_url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/29/events","html_url":"https://github.com/cahirwpz/amigaos-cross-toolchain/issues/29","id":142295826,"number":29,"title":"gcc-2.95.3: Internal compiler error in `instantiate_virtual_regs_1', at function.c:3885","user":{"login":"jens-maus","id":5887769,"avatar_url":"https://avatars.githubusercontent.com/u/5887769?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-maus","html_url":"https://github.com/jens-maus","followers_url":"https://api.github.com/users/jens-maus/followers","following_url":"https://api.github.com/users/jens-maus/following{/other_user}","gists_url":"https://api.github.com/users/jens-maus/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-maus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-maus/subscriptions","organizations_url":"https://api.github.com/users/jens-maus/orgs","repos_url":"https://api.github.com/users/jens-maus/repos","events_url":"https://api.github.com/users/jens-maus/events{/privacy}","received_events_url":"https://api.github.com/users/jens-maus/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/labels/bug","name":"bug","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-03-21T09:33:10Z","updated_at":"2016-10-16T11:15:51Z","closed_at":null,"body":"Why trying to compile the latest amisslv4 sources (https://github.com/jens-maus/amissl/tree/master) using yours (and other existing) gcc-2.95.3 based cross compilers I run into the following issue:\r\n\r\n```\r\n[...]\r\nm68k-amigaos-gcc -DOPENSSL_NO_DYNAMIC_ENGINE -DOPENSSLDIR=\"\\\"AmiSSL:\\\"\" -DENGINESDIR=\"\\\"AmiSSL:engines\\\"\" -m68020-60 -msoft-float -DNO_INLINE_VARARGS -D__NO_NET_API -DB_ENDIAN -DOPENSSL_SYS_AMIGA -D__amigaos3__ -DOPENSSL_NO_STDIO -I../../include -I../../include/netinclude -W -Wall -O0 -g -gstabs -DBN_DEBUG -DCONF_DEBUG -DDEBUG  -resident32 -DAMISSL_COMPILE -I../../libcmt/include  -Iinclude -I../../openssl -I../../openssl/crypto/include -I../../openssl/include -Icrypto/include -c -o crypto/bn/bn_nist.o ../../openssl/crypto/bn/bn_nist.c\r\n../../openssl/crypto/bn/bn_nist.c: In function `BN_nist_mod_192':\r\n../../openssl/crypto/bn/bn_nist.c:491: Internal compiler error in `instantiate_virtual_regs_1', at function.c:3885\r\nPlease submit a full bug report.\r\nSee <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.\r\n```\r\n\r\nCompiling with anything higher than -O0 (e.g. -O1) already worksaround this problem.\r\n\r\nAfter investigation I found the following gcc bugzilla entry reporting on a similar issue with GCC 2.95.3 and m68k builds:\r\n\r\nhttps://gcc.gnu.org/bugzilla/show_bug.cgi?id=8343\r\n\r\nThis resource suggests the following patch to be applied:\r\n\r\n```\r\n--- gcc-2.95.3/gcc/config/m68k/m68k.md\r\n+++ gcc-2.95.3/gcc/config/m68k/m68k.md\r\n@@ -3062,7 +3062,7 @@\r\n   [(parallel\r\n     [(set (subreg:SI (match_operand:DI 0 \"register_operand\" \"\") 1)\r\n    (mult:SI (match_operand:SI 1 \"register_operand\" \"\")\r\n-      (match_operand:SI 2 \"nonimmediate_operand\" \"\")))\r\n+      (match_operand:SI 2 \"register_operand\" \"\")))\r\n      (set (subreg:SI (match_dup 0) 0)\r\n    (truncate:SI (lshiftrt:DI (mult:DI (zero_extend:DI (match_dup 1))\r\n               (zero_extend:DI (match_dup 2)))\r\n@@ -3101,7 +3101,7 @@\r\n   [(parallel\r\n     [(set (subreg:SI (match_operand:DI 0 \"register_operand\" \"\") 1)\r\n    (mult:SI (match_operand:SI 1 \"register_operand\" \"\")\r\n-      (match_operand:SI 2 \"nonimmediate_operand\" \"\")))\r\n+      (match_operand:SI 2 \"register_operand\" \"\")))\r\n      (set (subreg:SI (match_dup 0) 0)\r\n    (truncate:SI (lshiftrt:DI (mult:DI (sign_extend:DI (match_dup 1))\r\n               (sign_extend:DI (match_dup 2)))\r\n```\r\n\r\nAfter having added that match to the `patches/gcc-2.95.3/gcc/config/m68k/m68k.md.diff` file in your repository the problem still exists and prevents from building a nice debug build of the latest AmiSSL developer build.\r\n\r\nI might be missing something here as I can't see that the gcc binary actually changed at all with the patch applied?!? Any help appreciated."},"comment":{"url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/comments/254040825","html_url":"https://github.com/cahirwpz/amigaos-cross-toolchain/issues/29#issuecomment-254040825","issue_url":"https://api.github.com/repos/cahirwpz/amigaos-cross-toolchain/issues/29","id":254040825,"user":{"login":"cahirwpz","id":265236,"avatar_url":"https://avatars.githubusercontent.com/u/265236?v=3","gravatar_id":"","url":"https://api.github.com/users/cahirwpz","html_url":"https://github.com/cahirwpz","followers_url":"https://api.github.com/users/cahirwpz/followers","following_url":"https://api.github.com/users/cahirwpz/following{/other_user}","gists_url":"https://api.github.com/users/cahirwpz/gists{/gist_id}","starred_url":"https://api.github.com/users/cahirwpz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cahirwpz/subscriptions","organizations_url":"https://api.github.com/users/cahirwpz/orgs","repos_url":"https://api.github.com/users/cahirwpz/repos","events_url":"https://api.github.com/users/cahirwpz/events{/privacy}","received_events_url":"https://api.github.com/users/cahirwpz/received_events","type":"User","site_admin":false},"created_at":"2016-10-16T11:15:51Z","updated_at":"2016-10-16T11:15:51Z","body":"Apparently, there's an issue with *shift right* operation on `long long` type. I think I now how to fix it."}}
{"actor":{"display_login":"cahirwpz"}}