Commit Graph

116 Commits

Author SHA1 Message Date
jsg
d3580fdc06 crank glapi minor for new symbol 2020-08-26 06:54:57 +00:00
jsg
9f3ce83c68 adjust for files which are symlinks in distfile 2020-08-26 06:36:08 +00:00
jsg
6cd42bcb24 Merge Mesa 20.1.6 2020-08-26 06:02:31 +00:00
jsg
241b1c1308 Import Mesa 20.1.6 2020-08-26 05:26:37 +00:00
visa
587f130e27 Fix Mesa build with clang 10 on mips64.
On mips64, the compiler does not allow use of non-zero argument with
__builtin_frame_address(). However, the returned frame address is only
used when PIPE_ARCH_X86 is defined. The compile error can be avoided
by making #ifdef PIPE_ARCH_X86 cover the getting of frame address too.

The argument checking of __builtin_frame_address() has been present
as a debug assert in clang 8. In clang 10, there is a proper runtime
check for the argument. This is why the build has not failed before.

OK jsg@
2020-08-01 03:51:31 +00:00
jsg
cb3c6b9276 llvmpipe: use LLVM version string instead of re-computing it
From Eric Engestrom
7f5ef97a07d4054efb96f0d644344644023af82c in Mesa git

fixes llvmpipe renderer string showing "LLVM 16.0" with LLVM 10
2020-06-18 11:45:13 +00:00
jsg
7b35d83e06 ac: fix build with recent LLVM
from Samuel Pitoiset
ee9811a0bb86d3d75fafeece368f6182048807d0 in mainline Mesa
2020-06-16 10:44:59 +00:00
kettenis
b8fd44900b Remove #ifdef that doesn't make sense anymore; extend clang workaround to
conver __sync_val_compare_and_swap.

ok jsg@
2020-04-03 10:06:14 +00:00
kettenis
cd2d30e6df Make this build on clang architectures that don't have 64-bit atomic
instructions.  Clang doesn't allow redeclaration (and therefore
redefinition) of the __sync_* builtins.  Use #pragma redefine_extname
to work around that restriction.  Clang also turns __sync_add_and_fetch
into __sync_fetch_and_add (and __sync_sub_and_fetch into
__sync_fetch_and_sub) in certain cases, so provide these functions as
well.

ok jsg@
2020-04-03 07:26:18 +00:00
jsg
d1d3f7dcb4 test for 32 bit atomic builtins was incorrectly testing for 64 bit atomics
noticed when going over a macppc clang build error reported by deraadt@
2020-04-03 01:58:40 +00:00
jsg
4706129d11 add mips64, mips64el and powerpc to the list of archs with -O0 in CFLAGS
builds were running out of memory

requested by deraadt@
2020-02-21 07:23:09 +00:00
jsg
12feee4512 regen 2020-02-20 02:59:02 +00:00
jsg
e374dad6a5 use futexes in Mesa on archs with atomics
tested by matthieu@ naddy@ and myself
2020-02-20 02:55:46 +00:00
matthieu
8e89b73ce9 Add sanity checks to futex_wait()
- handle the NULL timeout pointer case
- avoid negative cases.

Suggested by cheloha@ ok cheloha@, jsg@
2020-02-05 07:26:15 +00:00
matthieu
514c5b7b09 Fix absolute to relative timeout computation. ok jsg@, mpi@ 2020-02-04 18:40:21 +00:00
jca
5c4fe3d884 Zap stray #warning introduced in last commit
Grrr, sorry about that.
2020-01-30 13:52:30 +00:00
jca
704a56b63d Better checks for static_assert availability
When not in c++ or c11 mode:
- check for _Static_assert support in clang with __has_extension
- gcc implements _Static_assert starting with 4.6.0
- as a fallback, use a forward decl instead of ((void)0) so that
  static_assert can be used at file scope (scope issue pointed out by
  guenther@)

ok jsg@
2020-01-30 13:21:13 +00:00
jca
8344f41b9b Avoid _Static_assert in Mesa/libEGL on non-clang archs
Temporary workaround while we find a better solution.
Linking errors in ports reported by cwen@, "Please commit" jsg@
2020-01-28 14:25:30 +00:00
jsg
d37d5f3d84 fix some things which got broken in merge 2020-01-22 03:34:13 +00:00
jsg
c0a649c02f add files generated by python scripts which stopped being shipped with
distfiles when upstream removed autotools
2020-01-22 03:07:41 +00:00
jsg
75490c6cdf add back autotools files removed upstream 2020-01-22 03:02:59 +00:00
jsg
2796e1e6a2 Merge Mesa 19.2.8 2020-01-22 02:49:17 +00:00
jsg
18af3bcac6 Import Mesa 19.2.8 2020-01-22 02:07:15 +00:00
jsg
529ec772d8 regen 2019-12-07 03:10:09 +00:00
jsg
d3074235e2 build Mesa with _ISOC11_SOURCE for c11 visibility
autoconf function tests run without --std and have c11 visibility
timespec_get(3), a c11 function is found this way.

With gcc < 4.6 Mesa will build with --std=gnu99 with clang it will
build with --std=c99 and timespec_get() will no longer be visibile.
Further complicating things gcc 4.2 does not recognise --std=c11.

This was not noticed on linux as they build with _GNU_SOURCE which
among other things gives c11 visibility even with --std=c99.

discussed with millert@
2019-12-07 03:09:41 +00:00
deraadt
5886ab525a Constrain honouring of path-related environment variables based upon
issetugid(), not just the sloppy uid != euid test. gid != egid cases
can occur also.
Part of 6.6/009_mesaxlock.patch.sig and 6.5/020_mesaxlock.patch.sig
From Qualys, ok
2019-12-04 02:26:36 +00:00
jsg
76ee08e832 Call shmget() with permission 0600 instead of 0777
From Brian Paul
02c3dad0f3b4d26e0faa5cc51d06bc50d693dcdc in mainline Mesa

"A security advisory (TALOS-2019-0857/CVE-2019-5068) found that
creating shared memory regions with permission mode 0777 could allow
any user to access that memory.  Several Mesa drivers use shared-
memory XImages to implement back buffers for improved performance.

This path changes the shmget() calls to use 0600 (user r/w).

Tested with legacy Xlib driver and llvmpipe."
2019-11-20 03:13:04 +00:00
jsg
86f7c2fd52 enable radeonsi and llvm on arm64
ok kettenis@ patrick@
2019-08-28 08:01:48 +00:00
jsg
cddeeb9fb6 intel: Add support for Comet Lake
From Anuj Phogat
82f6a746e8b47fb6e3f96d7f5f69973f50eec9ca in mesa master
2019-08-24 02:12:17 +00:00
jsg
ff40cb71bf Merge Mesa 19.0.8 2019-07-01 08:36:47 +00:00
jsg
b1b22c2ae6 Import Mesa 19.0.8 2019-07-01 07:44:02 +00:00
jsg
bf1979f816 Build Mesa intel and radeon vulkan drivers and amd64 and i386
The intel driver can be used with inteldrm on ivy bridge or newer.
The radeon driver only works with amdgpu not radeondrm.

As we can't use python in xenocara add phony targets to create the
same output as python scripts which create json files for the loader.

This is just the ICDs, to use vulkan the loader and additional ports
are required.

ok mpi@ on an earlier version.  Changed to call shm_unlink()
directly after shm_mkstemp() as suggested by kettenis@
2019-05-27 07:20:30 +00:00
jsg
6cb8ade4e6 Call shm_unlink() directly after shm_mkstemp() rather than just before
close().  Closer to memfd_create() behaviour.
2019-05-27 04:19:00 +00:00
jsg
1c9ad5794c Merge Mesa 19.0.5 2019-05-23 05:33:19 +00:00
jsg
1dab445d3b Import Mesa 19.0.5 2019-05-23 04:22:53 +00:00
jsg
702ae9a55e Merge Mesa 18.3.5 2019-03-19 10:59:02 +00:00
jsg
34c49fbb2f Import Mesa 18.3.5 2019-03-19 09:37:42 +00:00
deraadt
2987dd6f92 hppa feels happier with this at low optimization also 2019-03-13 01:20:50 +00:00
jsg
c1c03dc65d Build Mesa with LLVM support on amd64 and i386 now that libelf and
shared libLLVM are in base.  And now we can finally build the radeonsi
Mesa driver adding accelerated support for radeon parts based on the
Graphics Core Next (GCN) architecture which is everything since
GFX6 / Southern Islands.

This can later be expanded to other architectures which build libLLVM
and have clang as the default compiler (to handle LLVM's c++11 headers).
2019-03-06 10:39:52 +00:00
jsg
fa5b0e3e48 remove -fno-tree-pre from CFLAGS on sparc64
This was an attempt to limit the memory usage at build time which is
no longer required after the datasize values in login.conf were raised.
2019-02-19 05:57:17 +00:00
jsg
b9f320ec11 Merge Mesa 18.3.4 2019-02-19 04:24:00 +00:00
jsg
ae7ee1376e Import Mesa 18.3.4 2019-02-19 03:25:14 +00:00
deraadt
e4decd20d6 landisk requires -O0 'cause mesa is a pig. 2019-02-07 18:34:52 +00:00
jsg
338bc0a2b5 Merge Mesa 18.3.2 2019-01-29 11:52:04 +00:00
jsg
fecc0d4060 Import Mesa 18.3.2 2019-01-29 10:45:31 +00:00
jsg
65cc648a0e Make similiar changes to the i386 tsd dispatch assembly as libglvnd to
avoid a text relocation fixing the build with lld.

This time store the address of the GOT in ebx as required before calling
the PLT stub and change .balign value to match X86_ENTRY_SIZE as suggested
by naddy.

ok naddy@
2018-11-11 04:15:19 +00:00
jsg
f88a7e92a2 Backout i386 tsd dispatch changes. While they worked for
glxinfo/glxgears it broke SDL2 GL which dlopens libGL.
2018-11-10 08:11:16 +00:00
jsg
f19a6c0440 Make similiar changes to the i386 tsd dispatch assembly as libglvnd to
avoid a text relocation fixing the build with lld.

ok kettenis@ naddy@
2018-10-31 23:26:16 +00:00
jsg
af38fe66ed regen 2018-10-29 11:38:31 +00:00
jsg
5f17afeed5 Don't attempt to rebuild spirv_info.c if timestamp on source files
changed as python won't be in path.

someone in this situation mentioned it to landry@
2018-10-29 11:35:23 +00:00