Commit Graph

61 Commits

Author SHA1 Message Date
Steve Lhomme 4c387460c9 vlc_cpu: include vlc_threads.h when using vlc_once_t 2023-04-27 19:44:35 +00:00
Johannes Kauffmann e09bec51c0 cpu: properly indent x86 defines
To match the other architecture subsections.
2023-02-26 20:15:02 +00:00
Rémi Denis-Courmont cb303e77f4 cpu: define VLC_ALTIVEC attribute macro
Like on x86 (e.g. VLC_SSE), this macro enables the use of AltiVec for
just a given function. Thus the other functions in the same C module
can be compiled without AltiVec and run on non-AltiVec processors.
2022-05-19 07:11:58 +00:00
Rémi Denis-Courmont fe1083cdf5 cpu: remove unused SSE4a flag
Detection only worked on Linux, but more importantly, this flag fell out of
use with 8512cab6af.
2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont 9d2d171f3a cpu: remove unused SSE 4.2 flag
This flag fell out of use with 8512cab6af.
2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont c240b18e48 cpu: remove unused XOP flag
Detection only worked on Linux, but more importantly, this flag fell out of
use with 8512cab6af.
2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont cecad7a516 cpu: remove unused FMA4 flag
Detection only worked on Linux, but more importantly, this flag fell out of
use with 8512cab6af.
2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont c8128f95f0 cpu: remove unused SSE1 flag 2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont 7d37a70341 cpu: remove unused MMX flag 2022-02-27 18:11:02 +00:00
Rémi Denis-Courmont 56e43fabb5 cpu: drop unused MMXEXT flag 2022-02-25 12:12:07 +00:00
Rémi Denis-Courmont b13555433e cpu: semi-generic helper for hooking SIMD functions 2022-02-24 17:43:59 +00:00
Rémi Denis-Courmont 2188dd740f cpu: compile-time RISC-V "V" V.E. detection
This detects compiler support for the RISC-V "V" Vector Extension if it
enabled in the compiler flags (or compiler machine definition).
2022-02-01 14:52:06 +00:00
Rémi Denis-Courmont 96ae63596e cpu: compile-time RISC-V FPU detection 2022-02-01 14:52:06 +00:00
Lyndon Brown 75bca60374 purge all remaining 3dNow artefacts 2021-07-14 08:49:42 +00:00
Lyndon Brown 07df2fc8c3 add missing VLC_AVX define 2021-04-27 16:16:25 +00:00
Rémi Denis-Courmont 31f895d084 cpu: deduplicate one-time initialization 2020-03-30 16:50:17 +03:00
Rémi Denis-Courmont b4c52cccf2 cpu: move Doxygen to header file 2020-03-29 17:24:22 +03:00
Rémi Denis-Courmont 813f70062c linux/cpu: run-time detect AdvSIMD on AArch64
This only assumes NEON is available on AArch64 if it is actually
enabled in the compiler settings (or rather, not explicitly disabled).
Otherwise, perform regular run-time detection.
2018-12-17 19:55:43 +02:00
Rémi Denis-Courmont edf6ff7544 cpu: generic support for ARM SVE
This adds generic support for the AArch64 Scalable Vector Extension.
2018-12-11 22:54:28 +02:00
Rémi Denis-Courmont 97d669a8c7 Remove ifdefs for GCC version below 4.4
According to INSTALL, we require GCC 4.8 already.
2017-02-25 15:37:38 +02:00
Janne Grunau 8df6a21f8a deinterlace: arm64 NEON merge asm
Approximately factor 2 faster.

Also adds build system support / cpu "detection" for arm64 neon.
Advanced SIMD (neon) is mandatory for general purpose ARMv8-a CPU so the
CPU feature detection is a constant 1.

Signed-off-by: Felix Paul Kühne <fkuehne@videolan.org>
2016-08-14 00:02:38 +02:00
Rémi Denis-Courmont e41027f592 Enable FPU on 64-bits ARM 2013-02-27 20:17:28 +02:00
Brad Smith b7c3e67da9 Fix building with Clang/LLVM
The following diff provides some fixes for VLC to allow building
with LLVM.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-01-07 11:32:39 +01:00
Konstantin Pavlov 657885538a MIPS: enable HAVE_FPU on hard-float builds. 2012-12-27 11:54:44 +04:00
Rémi Denis-Courmont a125b0adbb VLC_CPU_*: use hexadecimal
Hexadecimal bitmasks are easier to read.
2012-10-13 20:22:56 +03:00
Rémi Denis-Courmont 1d2a483eea Add ARMv6 CPU capability 2012-08-04 18:35:52 +03:00
Rémi Denis-Courmont 3bc25406ef Define CPU capabilities for AVX, AVX2, XOP and FMA4 2012-08-04 17:28:59 +03:00
Rémi Denis-Courmont b1a0789432 Check for 3D Now! at build time 2012-08-04 17:02:00 +03:00
Rémi Denis-Courmont 0ed12fd66f Check for SSE4 at build time where possible 2012-08-04 17:02:00 +03:00
Rémi Denis-Courmont 58dd22531f Check for SSSE3 at build time if possible 2012-08-04 16:37:42 +03:00
Rémi Denis-Courmont 6f7ffd3165 Check for SSE3 at build-time if possible 2012-08-04 16:37:42 +03:00
Rémi Denis-Courmont edfb6e4ad2 Check for SSE2 at build-time if possible 2012-08-04 16:37:42 +03:00
Rémi Denis-Courmont 615a016b4c Check for MMXEXT and SSE at build-time if possible 2012-08-04 16:37:41 +03:00
Rémi Denis-Courmont 5288c3823c Check for MMX at build-time if possible 2012-08-04 16:37:41 +03:00
Rémi Denis-Courmont 7bdcbe8ac8 Check for AltiVec at build-time if possible (untested) 2012-08-02 00:34:25 +03:00
Rémi Denis-Courmont b830aae4f0 Check for ARM NEON at build-time if possible 2012-08-02 00:20:11 +03:00
Rémi Denis-Courmont a257811bb6 cpu: do not define capabilities on platforms that do not have them
Also update avcodec encoder and switcher x86 checks.
2012-08-01 18:37:19 +03:00
Rafaël Carré 1207a36982 Remove vlc_memcpy
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2012-07-03 18:06:46 +03:00
Rémi Denis-Courmont cf5a82224a ARM: detect VFP floating point unit
This sets HAVE_FPU correctly on ARM targets if VFP instructions are
enabled. Note that __VFP_FP__ implies the use of the VFP floating point
format, not the availability of the VFP instructions. Thus software
floating emulation __SOFTFP__ (i.e. gcc -mfloat-abi=soft) is excluded
explicitly.
2012-01-26 20:27:55 +02:00
Jean-Baptiste Kempf 36ab287e77 LGPL
Re-license almost all of libVLC and libVLCcore to LGPLv2.1+

This move was authorized by the developers, either:
 - by e-mail,
 - by vote at the VideoLAN Dev Days 2011,
 - on the license website,
 - in a contract, oral or written.
No objection was raised, so far.

The developers agreeing are:
  Justus Piater
  Alexis Ballier
  Alexander Bethke
  Mohammed Adnène Trojette
  Alex Converse
  Alexey Sokolov
  Alexis de Lattre
  Andre Pang
  Anthony Loiseau
  Cyril Deguet
  André Weber
  Boris Dorès
  Brieuc Jeunhomme
  Benjamin Drung
  Hugo Beauzée-Luyssen
  Benoit Steiner
  Benjamin Pracht
  Bernie Purcell
  Przemyslaw Fiala
  Arnaud de Bossoreille de Ribou
  Brad Smith
  Nick Briggs
  Christopher Rath
  Christophe Courtaut
  Christopher Mueller
  Clement Chesnin
  Andres Krapf
  Damien Fouilleul
  David Flynn
  Sebastien Zwickert
  Antoine Cellerier
  Jérôme Decoodt
  Jérome Decoodt
  Dylan Yudaken
  Eduard Babayan
  Eugenio Jarosiewicz
  Elliot Murphy
  Eric Petit
  Erwan Tulou
  Etienne Membrives
  Ludovic Fauvet
  Fabio Ritrovato
  Tobias Güntner
  Jakub Wieczorek
  Frédéric Crozat
  Francois Cartegnie
  Laurent Aimar
  Florian G. Pflug
  Felix Paul Kühne
  Frank Enderle
  Rafaël Carré
  Simon Latapie
  Gildas Bazin
  Geoffroy Couprie
  Julien / Gellule
  Gildas Bazin
  Arnaud Schauly
  Toralf Niebuhr
  Vicente Jimenez Aguilar
  Derk-Jan Hartman
  Henri Fallon
  Ilkka Ollakka
  Olivier Teulière
  Rémi Duraffort
  Jakob Leben
  Jean-Baptiste Kempf
  Jean-Paul Saman
  Jean-Philippe Grimaldi
  Jean-François Massol
  Gaël Hendryckx
  Jakob Leben
  Jean-Marc Dressler
  Jai Menon
  Johan Bilien
  Johann Ransay
  Joris van Rooij
  JP Dinger
  Jean-Philippe André
  Adrien Grand
  Juha Jeronen
  Juho Vähä-Herttua
  Kaarlo Raiha
  Kaarlo Raiha
  Kamil Baldyga
  Keary Griffin
  Ken Self
  KO Myung-Hun
  Pierre Ynard
  Filippo Carone
  Loïc Minier
  Luca Barbato
  Lucas C. Villa Real
  Lukas Durfina
  Adrien Maglo
  Marc Ariberti
  Mark Lee
  Mark Moriarty
  Martin Storsjö
  Christophe Massiot
  Michel Kaempf
  Marian Ďurkovič
  Mirsal Ennaime
  Carlo Calabrò
  Damien Lucas
  Naohiro Koriyama
  Basos G
  Pierre Baillet
  Vincent Penquerc'h
  Olivier Aubert
  Pankaj Yadav
  Paul Corke
  Pierre d'Herbemont
  Philippe Morin
  Antoine Lejeune
  Michael Ploujnikov
  Jean-Marc Dressler
  Michael Hanselmann
  Rafaël Carré
  Ramiro Polla
  Rémi Denis-Courmont
  Renaud Dartus
  Richard Shepherd
  Faustino Osuna
  Arnaud Vallat
  Rob Jonson
  Robert Jedrzejczyk
  Steve Lhomme
  Rocky Bernstein
  Romain Goyet
  Rov Juvano
  Sam Hocevar
  Martin T. H. Sandsmark
  Sebastian Birk
  Sébastien Escudier
  Vincent Seguin
  Fabio Ritrovato
  Sigmund Augdal Helberg
  Casian Andrei
  Srikanth Raju
  Hannes Domani
  Stéphane Borel
  Stephan Krempel
  Stephan Assmus
  Tony Castley
  Pavlov Konstantin
  Eric Petit
  Tanguy Krotoff
  Dennis van Amerongen
  Michel Lespinasse
  Can Wu
  Xavier Marchesini
  Sébastien Toque
  Christophe Mutricy
  Yoann Peronneau
  Yohann Martineau
  Yuval Tze
  Scott Caudle
  Clément Stenac

It is possible, that some minor piece of code was badly tracked, for
some reasons (SVN, mainly) or that some small developers did not answer.
However, as an "œuvre collective", defined as in "CPI 113-2 alinéa 3",
and seeing "Cour. Cass. 17 Mai 1978", and seeing that the editor and
the very vast majority of developers have agreed (> 99.99% of the code,
> 99% of developers), we are fine here.
2011-11-27 22:54:33 +01:00
Rémi Denis-Courmont 209f1ae07f Define VLC_MMX and VLC_SSE function attribute macros 2011-11-24 22:41:12 +02:00
Rémi Denis-Courmont 497f9affad vlc_GetCPUCount(): move to thread subsystem (cosmetic) 2011-06-29 21:00:34 +03:00
Rémi Denis-Courmont 6a45dac72f Alias vlc_memset() to memset()
This saves two function calls per memset() since there are no optimized
implementations of memset() at all.
2011-05-10 18:10:27 +03:00
Rémi Denis-Courmont 6f258887aa Replace VLC_EXPORT macro with a simple prefix, VLC_API
This should help Doxygen parse VLC headers, and generally makes headers
easier to read. LibVLC already uses a similar approach.
2011-05-07 18:43:51 +03:00
Pierre d'Herbemont c0b7521d7b vlc_cpu: Fix a typo about ppc64. 2010-10-27 20:22:28 +02:00
Laurent Aimar 933d6755d4 Added vlc_GetCPUCount() to retreive the number of available CPU.
It is implemented for win32 and when sched_getaffinity() is available.
2010-05-03 22:53:19 +02:00
Laurent Aimar 2f1ac5a829 Splitted SSE4 into SSE4.1, SSE4.2 and SSE4A. 2009-11-24 19:50:27 +01:00
Rémi Denis-Courmont 145903d05b HAVE_FPU: make constant
Currently, we do not have any architecture where this would not be
a build-time constant. Constancy helps fixing a few issues in the audio
path.
2009-10-19 22:15:30 +03:00
Laurent Aimar 56ed95e8d4 Always defined CPU_CAPABILITY_*
In case they are known to be unsupported at compilation time, they are now
defined to be zero to be nice with the compiler.
2009-09-22 23:12:34 +02:00
Rémi Denis-Courmont 1f133a02a4 vlc_cpu.h: dedicated header for CPU features
Also segregate flags per architecture from now on.
2009-09-22 18:21:36 +03:00