{"action":"created","issue":{"url":"https://api.github.com/repos/JuliaLang/julia/issues/10602","labels_url":"https://api.github.com/repos/JuliaLang/julia/issues/10602/labels{/name}","comments_url":"https://api.github.com/repos/JuliaLang/julia/issues/10602/comments","events_url":"https://api.github.com/repos/JuliaLang/julia/issues/10602/events","html_url":"https://github.com/JuliaLang/julia/issues/10602","id":63520111,"number":10602,"title":"Bootstrap failure on ARMv7","user":{"login":"nalimilan","id":1120448,"avatar_url":"https://avatars.githubusercontent.com/u/1120448?v=3","gravatar_id":"","url":"https://api.github.com/users/nalimilan","html_url":"https://github.com/nalimilan","followers_url":"https://api.github.com/users/nalimilan/followers","following_url":"https://api.github.com/users/nalimilan/following{/other_user}","gists_url":"https://api.github.com/users/nalimilan/gists{/gist_id}","starred_url":"https://api.github.com/users/nalimilan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nalimilan/subscriptions","organizations_url":"https://api.github.com/users/nalimilan/orgs","repos_url":"https://api.github.com/users/nalimilan/repos","events_url":"https://api.github.com/users/nalimilan/events{/privacy}","received_events_url":"https://api.github.com/users/nalimilan/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/JuliaLang/julia/labels/arm","name":"arm","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":26,"created_at":"2015-03-22T10:36:55Z","updated_at":"2015-10-19T07:31:26Z","closed_at":null,"body":"When trying to build a nightly RPM on Fedora 22 armv7hl, I get failures during the bootstrap step. Depending on the value of `JULIA_TARGET_CPU` I use, the error is different:\r\n- With `native` (`JULIA_TARGET_CPU` not passed):\r\n```\r\nosutils.jl\r\nerror during bootstrap:\r\nLoadError(at \"sysimg.jl\" line 82: LoadError(at \"osutils.jl\" line 38: BoundsError(a=Array{Any, 1}[(), ()], i=(0,))))\r\nMakefile:168: recipe for target '/builddir/build/BUILD/julia/build/usr/lib/julia/sys0.o' failed\r\n```\r\nhttps://kojipkgs.fedoraproject.org//work/tasks/26/9290026/build.log\r\n\r\n- With `cortex-a8`:\r\n```\r\nosutils.jl\r\nerror during bootstrap:\r\nLoadError(at \"sysimg.jl\" line 82: LoadError(at \"osutils.jl\" line 38: Base.TypeError(func=:getfield, context=\"\", expected=DataType, got=<?::false>)))\r\nsignal (11): Segmentation fault\r\n/bin/sh: line 1:  7563 Segmentation fault      (core dumped) /builddir/build/BUILD/julia/build/usr/bin/julia -C cortex-a8 --build /builddir/build/BUILD/julia/build/usr/lib/julia/sys0 sysimg.jl\r\nMakefile:168: recipe for target '/builddir/build/BUILD/julia/build/usr/lib/julia/sys0.o' failed\r\n```\r\nhttps://kojipkgs.fedoraproject.org//work/tasks/1460/9291460/build.log\r\n\r\nI'm not familiar with ARM at all, so I'm not sure which one is the more reasonable (maybe none). Note that I'm using `USE_SYSTEM_LLVM=1`, which is LLVM 3.5. A difficulty is that gcc, which is used in the build, uses `-march=armv7-a` on Fedora armv7hl, but LLVM does not accept this as a target. This is why I tried `JULIA_CPU_TARGET=cortex-a8`. Fedora's LLVM is built using these settings:\r\n```\r\n  --with-cpu=cortex-a8 \\\r\n  --with-tune=cortex-a8 \\\r\n  --with-arch=armv7-a \\\r\n  --with-float=hard \\\r\n  --with-fpu=vfpv3-d16 \\\r\n  --with-abi=aapcs-vfp\r\n```\r\nhttp://pkgs.fedoraproject.org/cgit/llvm.git/tree/llvm.spec?h=f22&id=5aea06bdf020fd2fc750286d397e51e01a94a765#n404\r\n\r\nI see that ARM.inc advises `--with-cpu=cortex-a9 --with-fpu=neon` instead. Do you think that can be an issue?\r\n\r\nBTW, note `JCFLAGS` includes `-fsigned-char`."},"comment":{"url":"https://api.github.com/repos/JuliaLang/julia/issues/comments/149126988","html_url":"https://github.com/JuliaLang/julia/issues/10602#issuecomment-149126988","issue_url":"https://api.github.com/repos/JuliaLang/julia/issues/10602","id":149126988,"user":{"login":"nalimilan","id":1120448,"avatar_url":"https://avatars.githubusercontent.com/u/1120448?v=3","gravatar_id":"","url":"https://api.github.com/users/nalimilan","html_url":"https://github.com/nalimilan","followers_url":"https://api.github.com/users/nalimilan/followers","following_url":"https://api.github.com/users/nalimilan/following{/other_user}","gists_url":"https://api.github.com/users/nalimilan/gists{/gist_id}","starred_url":"https://api.github.com/users/nalimilan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nalimilan/subscriptions","organizations_url":"https://api.github.com/users/nalimilan/orgs","repos_url":"https://api.github.com/users/nalimilan/repos","events_url":"https://api.github.com/users/nalimilan/events{/privacy}","received_events_url":"https://api.github.com/users/nalimilan/received_events","type":"User","site_admin":false},"created_at":"2015-10-19T07:31:26Z","updated_at":"2015-10-19T07:31:26Z","body":"Interesting. If I add `x = floor(Int, 2^16 / log(2^16))` to primes.jl and simplify to call to `prime` to `const PRIMES = primes(7)`, then the `InexactError` occurs later at dSFMT.jl:12 in `const N    = floor(Int, ((MEXP - 128) / 104 + 1))`.\r\n\r\nBut that second failure doesn't happen if I do not add  `x = floor(Int, 2^16 / log(2^16))` to primes.jl. In that case, I get a segfault in random.jl, with the following assertion when calling `make julia-debug`:\r\n```\r\njulia-debug: /home/fedora/nalimilan/julia/src/gc.c :420 : find_region:  assertion \"maybe && \"find_region failed\"\" failed.\r\n```"}}