Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

[linux] mesa 13.0.3 #7805

Merged
merged 1 commit into from
Jan 23, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ addons:
- &common_packages [ 'libllvm3.8v4', 'cmake', 'cmake-data' ]
- &clang38_packages [ 'clang-3.8', 'libstdc++-5-dev', 'libstdc++6' ]
- &gcc5_packages [ 'gcc-5', 'g++-5' ]
- &egl_packages [ 'libgles2-mesa-dev', 'libgbm-dev' ]
- &glfw_packages [ 'libxrandr-dev', 'libxcursor-dev', 'libxinerama-dev' ]

addons_shortcuts:
Expand All @@ -20,15 +19,13 @@ addons_shortcuts:
packages:
- *common_packages
- *clang38_packages
- *egl_packages
- *glfw_packages
addons_gcc5: &gcc5
apt:
sources: *common_sources
packages:
- *common_packages
- *gcc5_packages
- *egl_packages
- *glfw_packages
addons_qt4: &qt4
apt:
Expand Down Expand Up @@ -94,6 +91,7 @@ matrix:
addons: *clang38
before_script:
- mapbox_start_xvfb
- mapbox_export_mesa_library_path
script:
- nvm install 4
- nvm use 4
Expand All @@ -112,9 +110,12 @@ matrix:
env: BUILDTYPE=Release _CXX=clang++-3.8 _CC=clang-3.8 WITH_EGL=1
addons: *clang38
before_script:
# fglrx causes the GLX extension to be unavailable
- sudo apt-get purge -qq fglrx
- export PACKAGE_JSON_VERSION=$(node -e "console.log(require('./package.json').version)")
- export PUBLISH=$([[ "${TRAVIS_TAG:-}" == "node-v${PACKAGE_JSON_VERSION}" ]] && echo true)
- mapbox_start_xvfb
- mapbox_export_mesa_library_path
script:
- nvm install 4
- nvm use 4
Expand All @@ -136,6 +137,7 @@ matrix:
addons: *gcc5
before_script:
- mapbox_start_xvfb
- mapbox_export_mesa_library_path
after_script:
- ccache --show-stats
- ./platform/linux/scripts/coveralls.sh
Expand All @@ -150,6 +152,7 @@ matrix:
addons: *gcc5
before_script:
- mapbox_start_xvfb
- mapbox_export_mesa_library_path

# EGL - Clang 3.8 - Debug
- os: linux
Expand All @@ -161,6 +164,7 @@ matrix:
addons: *clang38
before_script:
- mapbox_start_xvfb
- mapbox_export_mesa_library_path

# EGL - Clang 3.8 - Release
- os: linux
Expand All @@ -172,6 +176,7 @@ matrix:
addons: *clang38
before_script:
- mapbox_start_xvfb
- mapbox_export_mesa_library_path

# Qt 4 - GCC 5 - Release
- os: linux
Expand Down
8 changes: 1 addition & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,8 @@ if(WITH_OSMESA AND WITH_EGL)
message(FATAL_ERROR "WITH_OSMESA and WITH_EGL are mutually exclusive.")
endif()

if(WITH_OSMESA)
# Default mesa mason binary is OSMesa.
set(MASON_MESA_SUFFIX "")
elseif(WITH_EGL)
if(WITH_EGL)
add_definitions(-DMBGL_USE_GLES2=1)
set(MASON_MESA_SUFFIX "-egl")
else()
set(MASON_MESA_SUFFIX "-glx")
endif()

if(IS_CI_BUILD)
Expand Down
25 changes: 10 additions & 15 deletions platform/linux/config.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
mason_use(glfw VERSION 3.2.1)
if(IS_CI_BUILD AND NOT WITH_EGL)
mason_use(mesa VERSION 13.0.0${MASON_MESA_SUFFIX})
endif()
mason_use(mesa VERSION 13.0.3)
mason_use(boost_libprogram_options VERSION 1.62.0${MASON_CXXABI_SUFFIX})
mason_use(sqlite VERSION 3.14.2)
mason_use(libuv VERSION 1.9.1)
Expand All @@ -16,19 +14,21 @@ mason_use(icu VERSION 58.1)
include(cmake/loop-uv.cmake)

macro(mbgl_platform_core)
target_add_mason_package(mbgl-core PUBLIC mesa)

if(WITH_OSMESA)
target_sources(mbgl-core
PRIVATE platform/default/headless_backend_osmesa.cpp
PRIVATE platform/default/mbgl/gl/headless_display.cpp
)
target_add_mason_package(mbgl-core PUBLIC mesa)
target_link_libraries(mbgl-core
PUBLIC -lOSMesa
)
elseif(WITH_EGL)
target_sources(mbgl-core
PRIVATE platform/linux/src/headless_backend_egl.cpp
PRIVATE platform/linux/src/headless_display_egl.cpp
)
# TODO: Provide surface-less EGL mesa for CI builds.
# https://github.com/mapbox/mapbox-gl-native/issues/7020
target_link_libraries(mbgl-core
PUBLIC -lGLESv2
PUBLIC -lEGL
Expand All @@ -39,15 +39,10 @@ macro(mbgl_platform_core)
PRIVATE platform/linux/src/headless_backend_glx.cpp
PRIVATE platform/linux/src/headless_display_glx.cpp
)
if (IS_CI_BUILD)
target_add_mason_package(mbgl-core PUBLIC mesa)
target_link_libraries(mbgl-core PUBLIC -lX11)
else()
target_link_libraries(mbgl-core
PUBLIC -lGL
PUBLIC -lX11
)
endif()
target_link_libraries(mbgl-core
PUBLIC -lGL
PUBLIC -lX11
)
endif()

target_sources(mbgl-core
Expand Down
5 changes: 3 additions & 2 deletions scripts/travis_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,9 @@ export -f mapbox_start_xvfb
function mapbox_export_mesa_library_path {
# Install and set up to load a more recent version of mesa
mapbox_time "install_mesa" \
mason install mesa 13.0.0-glx
export LD_LIBRARY_PATH="`mason prefix mesa 13.0.0-glx`/lib:${LD_LIBRARY_PATH:-}"
mason install mesa 13.0.3
export LD_LIBRARY_PATH="`mason prefix mesa 13.0.3`/lib:${LD_LIBRARY_PATH:-}"
export LIBGL_DRIVERS_PATH="`mason prefix mesa 13.0.3`/lib/dri"
}

export -f mapbox_export_mesa_library_path
Expand Down
71 changes: 71 additions & 0 deletions scripts/valgrind.sup
Original file line number Diff line number Diff line change
Expand Up @@ -266,3 +266,74 @@
fun:_ZN4mbgl4util10write_fileERKSsS2_
...
}
{
Ubuntu 14.04 - Travis + mesa 13.0.3
Memcheck:Cond
fun:_ZN12_GLOBAL__N_117PeepholeOptimizer20runOnMachineFunctionERN4llvm15MachineFunctionE
fun:_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE
fun:_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE
fun:_ZN4llvm5MCJIT10emitObjectEPNS_6ModuleE
fun:_ZN4llvm5MCJIT21generateCodeForModuleEPNS_6ModuleE
fun:_ZN4llvm5MCJIT14finalizeObjectEv
fun:LLVMGetPointerToGlobal
fun:gallivm_jit_function
fun:generate_variant
fun:llvmpipe_update_fs
}
{
Ubuntu 14.04 - Travis + mesa 13.0.3
Memcheck:Cond
fun:_ZNK4llvm12X86InstrInfo13reMaterializeERNS_17MachineBasicBlockENS1_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS4_EEEEjjPKS4_RKNS_18TargetRegisterInfoE
fun:_ZN12_GLOBAL__N_117RegisterCoalescer23reMaterializeTrivialDefERKN4llvm13CoalescerPairEPNS1_12MachineInstrERb
fun:_ZN12_GLOBAL__N_117RegisterCoalescer8joinCopyEPN4llvm12MachineInstrERb
fun:_ZN12_GLOBAL__N_117RegisterCoalescer20runOnMachineFunctionERN4llvm15MachineFunctionE
fun:_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE
fun:_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE
fun:_ZN4llvm5MCJIT10emitObjectEPNS_6ModuleE
fun:_ZN4llvm5MCJIT21generateCodeForModuleEPNS_6ModuleE
fun:_ZN4llvm5MCJIT14finalizeObjectEv
fun:LLVMGetPointerToGlobal
}
{
Ubuntu 14.04 - Travis + mesa 13.0.3
Memcheck:Cond
fun:_ZNK4llvm12X86InstrInfo13reMaterializeERNS_17MachineBasicBlockENS1_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS4_EEEEjjPKS4_RKNS_18TargetRegisterInfoE
fun:_ZN4llvm13LiveRangeEdit15rematerializeAtERNS_17MachineBasicBlockENS1_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS4_EEEEjRKNS0_5RematERKNS_18TargetRegisterInfoEb
fun:_ZN12_GLOBAL__N_113InlineSpiller5spillERN4llvm13LiveRangeEditE
fun:_ZN12_GLOBAL__N_18RAGreedy17selectOrSplitImplERN4llvm12LiveIntervalERNS1_15SmallVectorImplIjEERNS1_8SmallSetIjLj16ESt4lessIjEEEj
fun:_ZN12_GLOBAL__N_18RAGreedy13selectOrSplitERN4llvm12LiveIntervalERNS1_15SmallVectorImplIjEE
fun:_ZN4llvm12RegAllocBase16allocatePhysRegsEv
fun:_ZN12_GLOBAL__N_18RAGreedy20runOnMachineFunctionERN4llvm15MachineFunctionE
fun:_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE
fun:_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE
fun:_ZN4llvm5MCJIT10emitObjectEPNS_6ModuleE
}
{
Ubuntu 14.04 - Travis + mesa 13.0.3
Memcheck:Cond
fun:_ZNK4llvm12X86InstrInfo13reMaterializeERNS_17MachineBasicBlockENS1_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS4_EEEEjjPKS4_RKNS_18TargetRegisterInfoE
fun:_ZN4llvm13LiveRangeEdit15rematerializeAtERNS_17MachineBasicBlockENS1_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS4_EEEEjRKNS0_5RematERKNS_18TargetRegisterInfoEb
fun:_ZN4llvm11SplitEditor13defFromParentEjPNS_6VNInfoENS_9SlotIndexERNS_17MachineBasicBlockENS4_15bundle_iteratorINS_12MachineInstrENS_14ilist_iteratorIS7_EEEE
fun:_ZN4llvm11SplitEditor16splitRegOutBlockERKNS_13SplitAnalysis9BlockInfoEjNS_9SlotIndexE
fun:_ZN12_GLOBAL__N_18RAGreedy13doRegionSplitERN4llvm12LiveIntervalEjbRNS1_15SmallVectorImplIjEE
fun:_ZN12_GLOBAL__N_18RAGreedy17selectOrSplitImplERN4llvm12LiveIntervalERNS1_15SmallVectorImplIjEERNS1_8SmallSetIjLj16ESt4lessIjEEEj
fun:_ZN12_GLOBAL__N_18RAGreedy13selectOrSplitERN4llvm12LiveIntervalERNS1_15SmallVectorImplIjEE
fun:_ZN4llvm12RegAllocBase16allocatePhysRegsEv
fun:_ZN12_GLOBAL__N_18RAGreedy20runOnMachineFunctionERN4llvm15MachineFunctionE
fun:_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE
fun:_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE
}
{
Ubuntu 14.04 - Travis + mesa 13.0.3
Memcheck:Leak
match-leak-kinds: definite
fun:_Znwm
...
}