{"action":"created","issue":{"url":"https://api.github.com/repos/eth-cscs/arbor/issues/473","repository_url":"https://api.github.com/repos/eth-cscs/arbor","labels_url":"https://api.github.com/repos/eth-cscs/arbor/issues/473/labels{/name}","comments_url":"https://api.github.com/repos/eth-cscs/arbor/issues/473/comments","events_url":"https://api.github.com/repos/eth-cscs/arbor/issues/473/events","html_url":"https://github.com/eth-cscs/arbor/pull/473","id":312935494,"number":473,"title":"SIMD printing with modcc.","user":{"login":"halfflat","id":556816,"avatar_url":"https://avatars1.githubusercontent.com/u/556816?v=4","gravatar_id":"","url":"https://api.github.com/users/halfflat","html_url":"https://github.com/halfflat","followers_url":"https://api.github.com/users/halfflat/followers","following_url":"https://api.github.com/users/halfflat/following{/other_user}","gists_url":"https://api.github.com/users/halfflat/gists{/gist_id}","starred_url":"https://api.github.com/users/halfflat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/halfflat/subscriptions","organizations_url":"https://api.github.com/users/halfflat/orgs","repos_url":"https://api.github.com/users/halfflat/repos","events_url":"https://api.github.com/users/halfflat/events{/privacy}","received_events_url":"https://api.github.com/users/halfflat/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-04-10T13:59:28Z","updated_at":"2018-04-11T16:00:26Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/eth-cscs/arbor/pulls/473","html_url":"https://github.com/eth-cscs/arbor/pull/473","diff_url":"https://github.com/eth-cscs/arbor/pull/473.diff","patch_url":"https://github.com/eth-cscs/arbor/pull/473.patch"},"body":"Merges master branch.\r\n\r\nConfig/build changes:\r\n* Split arbor modcc vectorization option (now `ARB_VECTORIZE`) and target-architecture optimization (now `ARB_ARCH`).\r\n* For `arbor` and `arbormech` targets, and in particular not the `modcc` target, use `ARB_ARCH` to generate corresponding target-appropriate binaries, including, for example, appropriate SIMD support.\r\n* Extend `CompilerOptions.cmake` to map as best as able between the various target architecture names (we use the gcc names) and the correct option to pass to the compiler based on the compiler and platform.\r\n* Add work-around for misidentification by CMake of XL C as Clang.\r\n* As a temporary work-around, include `arbormech` library twice on link line to resolve circular arbor–arbormech dependencies.\r\n\r\nSIMD class changes:\r\n* Incorporate SIMD module printing into modcc cprinter.\r\n* Add `simd_cast` operation between SIMD value types of the same width, and with `std::array`. (Note: this was tested and used in an early development version of the code, but not in this version. It was still a lacuna in the original SIMD wrappers, so it has been left in.)\r\n* Restructure SIMD gather/scatter API to use a `simd::indirect` expression, which encapsulates a pointer and SIMD offset.\r\n* Add `simd::index_constraint` scoped enum to describe knowledge of contention in indirect indices, so that we can branch on this to the appropriate implementation.\r\n* Add SIMD concrete implementation routines `reduce_add` for horizontal reduction and `element0` for access to first lane scalar value.\r\n* Add SIMD value method `sum()` that exposes implementation `reduce_add`.\r\n* Add SIMD concrete implementation routine `compound_indexed_add` that provides the implementation for `indirect(p, simd_indices) += simd_value` construction.\r\n* Fix SIMD `implbase` bug where some static methods were using the `implbase` fall-back functions instead of the derived class specialized implementations.\r\n* Move SIMD mathematical functions into friend routines of `simd_impl` in order to resolve implicit conversions from scalars in mixed SIMD-scalar operations.\r\n* Use a templated `tag` class to dispatch on SIMD concrete implementation types, to avoid problems with incomplete types in method signatures.\r\n* Remove old SIMD intrinsics.\r\n\r\nFVM class changes:\r\n* Add signed `fvm_index_type` (alias for `int`) for the representation of indices (such as CV index, ion instance index etc.) in fvm layouts and mechanisms. This was chosen as an alternative to making `unsigned` versions of all our SIMD implementation classes.\r\n* Make mechanism `width_` a pointer into `data_` for uniform access in generated modules.\r\n\r\nModcc/module changes:\r\n* Modify SIMD printing options for `modcc`: `-s <simd-abi>` specifies the vectorization target: none, avx, avx2, avx512, default, or native. `-S <N>` allows a specific data width to be prescribed.\r\n* Fix problem in `test_ca.mod` with uninitialized ion current.\r\n* Extend cprinter to incorporate SIMD-specific output.\r\n* Add infrastructure support to allow future pre-computation of SIMD index conflict cases for (hopefully) faster scatters and updates.\r\n* Remove old SIMD printing code.\r\n\r\nUnit test changes:\r\n* Extend repertoire of generic sequence equality/near equality testing support in `common.hpp`.\r\n* Add warning suppression for icc for the malloc instrumentation code.\r\n* SIMD unit tests for indirect expressions, compound indirect add, reduction.\r\n* Make some exact tests into floating point 'near' tests when comparing computed areas and lengths in swc and fvm layout tests, to account for compiler (e.g. icc) performing semantically inequivalent floating point operation reordering or fusion at -O3.\r\n\r\nTODO:\r\n1. SIMD documentation needs to be updated to describe new API and functionality.\r\n2. Unit tests need to be supplied for new modcc cprinter.\r\n3. Padded index implementation for density channels needs to be re-examined, as currently we cannot take advantage of a faster index constraint than `none`. (I'll detail this in a new ticket.)"},"comment":{"url":"https://api.github.com/repos/eth-cscs/arbor/issues/comments/380505407","html_url":"https://github.com/eth-cscs/arbor/pull/473#issuecomment-380505407","issue_url":"https://api.github.com/repos/eth-cscs/arbor/issues/473","id":380505407,"user":{"login":"bcumming","id":384605,"avatar_url":"https://avatars0.githubusercontent.com/u/384605?v=4","gravatar_id":"","url":"https://api.github.com/users/bcumming","html_url":"https://github.com/bcumming","followers_url":"https://api.github.com/users/bcumming/followers","following_url":"https://api.github.com/users/bcumming/following{/other_user}","gists_url":"https://api.github.com/users/bcumming/gists{/gist_id}","starred_url":"https://api.github.com/users/bcumming/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcumming/subscriptions","organizations_url":"https://api.github.com/users/bcumming/orgs","repos_url":"https://api.github.com/users/bcumming/repos","events_url":"https://api.github.com/users/bcumming/events{/privacy}","received_events_url":"https://api.github.com/users/bcumming/received_events","type":"User","site_admin":false},"created_at":"2018-04-11T16:00:26Z","updated_at":"2018-04-11T16:00:26Z","author_association":"OWNER","body":"`ARB_ARCH` should be inherited by the unit tests so that they test the architecure for which the library was compiled."}}
{"actor":{"display_login":"bcumming"}}