aboutsummaryrefslogtreecommitdiff
path: root/platform/linux-generic/arch/default/odp/api
AgeCommit message (Collapse)Author
2021-10-21linux-gen: fix braced-groups within expressions build errorsMatias Elo
Fix "ISO C forbids braced-groups within expressions" errors when building with 'pedantic' option. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-10-12linux-gen: atomic: explicitly use staddl for 64-bit add/sub release opsMatias Elo
GCC generates LDADDL instructions when using __atomic_fetch_add() on aarch64. Explicitly use STADDL to implement odp_atomic_add_rel_u64() and odp_atomic_sub_rel_u64() functions for better performance. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Govindarajan Mohandoss <govindarajan.mohandoss@arm.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-10-12linux-gen: atomic: explicitly use staddl for 32-bit add/sub release opsMatias Elo
GCC generates LDADDL instructions when using __atomic_fetch_add() on aarch64. Explicitly use STADDL to implement odp_atomic_add_rel_u32() and odp_atomic_sub_rel_u32() functions for better performance. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Govindarajan Mohandoss <govindarajan.mohandoss@arm.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-10-04linux-gen: atomic: use STADD explicitly for aarch64 atomic add operationsMalvika Gupta
By default, GCC generates the LDADD/LDADDL instruction for atomic add/sub/inc/dec functions. These functions could also be implemented on ARMv8.1 ISA (and above) with the store version, STADD/STADDL instruction which result in better performance for fastpath applications. Signed-off-by: Malvika Gupta <Malvika.Gupta@arm.com> Reviewed-by: Govindarajan Mohandoss <govindarajan.mohandoss@arm.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2021-09-30linux-gen: cpu: refactor inlining codeMatias Elo
Refactor CPU ABI and implementation files to follow common project inlining style. odp_cpu_pause() function is now defined only once per architecture. After this clean-up it's simpler for an implementation to add inlined versions of CPU module functions. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
2021-05-31linux-gen: time: implement strict time stamp read functionsPetri Savolainen
Implemented strict versions of local and global time stamp read functions. Moved time register read code into inline functions on ARMv8. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
2021-03-19linux-gen: atomic: clean generic 128-bit implementationMatias Elo
Use single common function for lock-based atomic CAS operations. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-03-19linux-gen: atomics: implement 128-bit operations using gcc builtinsMatias Elo
Add new implementation for the 128-bit atomic operations using GCC builtin atomics. This improves performance considerably compared to the basic lock-based implementation. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-03-19linux-gen: atomic: reorganize architecture specific implementationsMatias Elo
Move architecture specific atomic function implementations to separate header files. Enables 128-bit atomic function inlining. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-01-26linux-gen: hash: prepare for arch specific implementationsMatias Elo
Refactor build system to enable adding architecture specific hash function implementations. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2018-05-31linux-gen: time: inline arch cpu time on x86Petri Savolainen
Inline cpu HW time counter read function on x86. Time global data structure is visible to applications, but Posix types (timespec) or header files are not. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-05-28linux-gen: cpu: inline cpu cycle functions on x86Petri Savolainen
Moved cpu cycle and pause functions into arch/x86/odp_arch_cpu_inlines.h. Uncommented pause function in spec file and removed it from ABI file. It's safer for ABI compat mode to not have code included into ABI spec files. Other architectures use the default odp_arch_cpu_inlines.h, which does not change the current implementation. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-02-26update Linaro Copyrights to 2018 year part2Maxim Uvarov
update Copyrights with the same script in rebased branch. Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-02-19build: support building for generic archDmitry Eremin-Solenikov
Support building ODP for generic architecture, using default ARCH code. Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-01-18linux-gen, include: switch cpu.h to api+abiDmitry Eremin-Solenikov
Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2016-07-27linux-generic: internal cache line sizeBrian Brooks
Define the ODP API for cache line size to the cache line size defined in the internal architecture directories. Prefix internal cache line size identifier with '_odp'. Signed-off-by: Brian Brooks <brian.brooks@linaro.org> Reviewed-by: Christophe Milard <christophe.milard@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2016-05-10linux-generic: correctly set arch as undefinedMike Holmes
arch is defined as an architecture flag so that optimisations or necessary differences can be accommodated. When we are unable to determine the architecture it is incorrect to assign it the value of an operating system. Instead lets label it correctly as a default and add an error to the user when an unknown arch is encountered. Signed-off-by: Mike Holmes <mike.holmes@linaro.org> Reviewed-and-tested-by: Bill Fischofer <bill.fischofer@linaro.org>