{"action":"closed","issue":{"url":"https://api.github.com/repos/basic-gongfu/cixl/issues/14","repository_url":"https://api.github.com/repos/basic-gongfu/cixl","labels_url":"https://api.github.com/repos/basic-gongfu/cixl/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/basic-gongfu/cixl/issues/14/comments","events_url":"https://api.github.com/repos/basic-gongfu/cixl/issues/14/events","html_url":"https://github.com/basic-gongfu/cixl/issues/14","id":332087419,"node_id":"MDU6SXNzdWUzMzIwODc0MTk=","number":14,"title":"Build fails with \"error: trampoline generated for nested function\"","user":{"login":"muflax","id":69918,"node_id":"MDQ6VXNlcjY5OTE4","avatar_url":"https://avatars0.githubusercontent.com/u/69918?v=4","gravatar_id":"","url":"https://api.github.com/users/muflax","html_url":"https://github.com/muflax","followers_url":"https://api.github.com/users/muflax/followers","following_url":"https://api.github.com/users/muflax/following{/other_user}","gists_url":"https://api.github.com/users/muflax/gists{/gist_id}","starred_url":"https://api.github.com/users/muflax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muflax/subscriptions","organizations_url":"https://api.github.com/users/muflax/orgs","repos_url":"https://api.github.com/users/muflax/repos","events_url":"https://api.github.com/users/muflax/events{/privacy}","received_events_url":"https://api.github.com/users/muflax/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-06-13T17:16:00Z","updated_at":"2018-07-24T23:37:13Z","closed_at":"2018-07-24T23:37:13Z","author_association":"NONE","body":"Build fails on gcc 6.4.0 on Gentoo/Linux (specifically, with `gcc --version`: `Gentoo 6.4.0-r1 p1.3`):\r\n\r\n    $ make\r\n    \r\n    Scanning dependencies of target libcixl\r\n    [  0%] Building C object CMakeFiles/libcixl.dir/src/cixl/arg.c.o\r\n    [...]/cixl/src/cixl/arg.c: In function ‘cx_resolve_arg_refs’:\r\n    [...]/cixl/src/cixl/arg.c:160:18: error: trampoline generated for nested function ‘get_tt_arg’ [-Werror=trampolines]\r\n      struct cx_type *get_tt_arg(int i) {\r\n                      ^~~~~~~~~~\r\n    cc1: all warnings being treated as errors\r\n    make[2]: *** [CMakeFiles/libcixl.dir/build.make:63: CMakeFiles/libcixl.dir/src/cixl/arg.c.o] Error 1\r\n    make[1]: *** [CMakeFiles/Makefile2:68: CMakeFiles/libcixl.dir/all] Error 2\r\n    make: *** [Makefile:130: all] Error 2\r\n\r\nThere's a few more trampoline warnings, that's just the first one. Skimming the code, they mostly seem to result from closures in various argument parsing functions?\r\n\r\nGentoo enables `-Wtrampolines` in gcc by default. Adding `-Wno-error=trampolines` allows cixl to build, tests pass, everything seems fine. \r\n\r\nThe warning was added around gcc 4.x because trampolines can force the stack to be executable. They're also less portable in general."}}
{"actor":{"display_login":"basic-gongfu"}}