Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 918928 - Firefox 120.0 failed to build under VirtualBox: error: always_inline function '_mm256_fmadd_ps' requires target feature 'fma', but would be inlined into function 'mad' that is compiled without support for 'fma'
Summary: Firefox 120.0 failed to build under VirtualBox: error: always_inline function...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-12-01 01:18 UTC by Sevilla, Larry
Modified: 2023-12-04 00:19 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (firefox.120.0.build.log.txt.gz,446.77 KB, application/gzip)
2023-12-01 01:18 UTC, Sevilla, Larry
Details
environment (firefox.120.0.environment.txt,239.49 KB, text/plain)
2023-12-01 01:19 UTC, Sevilla, Larry
Details
emerge --info (firefox.120.0.info.txt,6.22 KB, text/plain)
2023-12-01 01:19 UTC, Sevilla, Larry
Details
emerge -pqv (firefox.120.0.pqv.txt,945 bytes, text/plain)
2023-12-01 01:20 UTC, Sevilla, Larry
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sevilla, Larry 2023-12-01 01:18:00 UTC
Host: Windows 10 VirtualBox 7.0
Guest: Gentoo x64 with virtualbox-guest-additions-7.0.12

Firefox 120.0 FAILED to build if Gentoo is a guest within VirtualBox 7.0

Note: Firefox 120.0 Successfully build on a regular PC


Reproducible: Always

Steps to Reproduce:
1. emerge -j firefox
2.
3.
Actual Results:  
Failed to build

Expected Results:  
Should build

Failed to build under VirtualBox

Successful build on regular PC


attachments to follow
Comment 1 Sevilla, Larry 2023-12-01 01:18:36 UTC
Created attachment 876034 [details]
build log
Comment 2 Sevilla, Larry 2023-12-01 01:19:12 UTC
Created attachment 876035 [details]
environment
Comment 3 Sevilla, Larry 2023-12-01 01:19:45 UTC
Created attachment 876036 [details]
emerge --info
Comment 4 Sevilla, Larry 2023-12-01 01:20:19 UTC
Created attachment 876037 [details]
emerge -pqv
Comment 5 Alfred Wingate 2023-12-01 11:16:34 UTC
26:58.88 /usr/lib/llvm/17/bin/x86_64-pc-linux-gnu-clang++-17 -o ShaderStorageBlockFunctionHLSL.o -c  -I/var/tmp/portage/www-client/firefox-120.0/work/firefox_build/dist/stl_wrappers -I/var/tmp/portage/www-client/firefox-120.0/work/f
irefox_build/dist/system_wrappers -include /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/config/gcc_hidden.h -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector-strong -fstack-clash-protection -DNDEBUG=1 -DTRIMMED
=1 -DANGLE_PLATFORM_EXPORT= -D__NDK_FPABI__= -DANGLE_SKIP_DXGI_1_2_CHECK -DANGLE_ENABLE_KEYEDMUTEX -DANGLE_TRANSLATOR_ESSL_ONLY -DANGLE_DISABLE_POOL_ALLOC -DANGLE_ENABLE_APPLE_WORKAROUNDS -DANGLE_ENABLE_ESSL -DANGLE_ENABLE_GLSL -DAN
GLE_ENABLE_HLSL -DANGLE_ENABLE_SHARE_CONTEXT_LOCK=1 -DANGLE_VMA_VERSION=2003000 '-DCR_CLANG_REVISION="llvmorg-16-init-6578-g0d30e92f-2"' -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DNOMINMAX -DUNICODE -DWINVER=0x0A00 -D_ATL_NO_OPENGL -D_CRT_NO
NSTDC_NO_WARNINGS -D_CRT_RAND_S -D_CRT_SECURE_NO_DEPRECATE -D_HAS_EXCEPTIONS=0 -D_SCL_SECURE_NO_DEPRECATE -D_SECURE_ATL -D_UNICODE -D_WINSOCK_DEPRECATED_NO_WARNINGS -I/var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/
angle/targets/translator -I/var/tmp/portage/www-client/firefox-120.0/work/firefox_build/gfx/angle/targets/translator -I/var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/angle/checkout/include -I/var/tmp/portage/www-cl
ient/firefox-120.0/work/firefox-120.0/gfx/angle/checkout/src -I/var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/angle/checkout/src/common/third_party/base -I/var/tmp/portage/www-client/firefox-120.0/work/firefox_buil
d/dist/include -I/usr/include/nspr -I/usr/include/nss -I/usr/include/nspr -I/var/tmp/portage/www-client/firefox-120.0/work/firefox_build/dist/include/nss -I/usr/include/pixman-1 -DMOZILLA_CLIENT -include /var/tmp/portage/www-client/
firefox-120.0/work/firefox_build/mozilla-config.h -fno-sized-deallocation -fno-aligned-new -march=native -pipe -fno-exceptions -fPIC -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -pipe -O2 -f
omit-frame-pointer -funwind-tables -Wall -Wbitfield-enum-conversion -Wdeprecated-this-capture -Wempty-body -Wformat-type-confusion -Wignored-qualifiers -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtautolog
ical-constant-in-range-compare -Wtype-limits -Wno-error=tautological-type-limit-compare -Wunreachable-code -Wunreachable-code-return -Wunused-but-set-parameter -Wno-invalid-offsetof -Wclass-varargs -Wempty-init-stmt -Wfloat-overflow
-conversion -Wfloat-zero-conversion -Wloop-analysis -Wno-range-loop-analysis -Wc++2a-compat -Wenum-compare-conditional -Wenum-float-conversion -Wno-error=deprecated -Wno-error=deprecated-anon-enum-enum-conversion -Wno-error=deprecat
ed-enum-enum-conversion -Wno-error=deprecated-pragma -Wno-error=deprecated-this-capture -Wcomma -Wimplicit-fallthrough -Wstring-conversion -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=
free-nonheap-object -Wno-error=atomic-alignment -Wno-error=deprecated-builtins -Wformat -Wformat-security -Wno-psabi -Wthread-safety -Wno-error=builtin-macro-redefined -Wno-unknown-warning-option -Wno-final-dtor-non-final-class -Wno
-implicit-const-int-float-conversion -Wno-range-loop-construct -msse2 -fno-strict-aliasing -ffp-contract=off  -MD -MP -MF .deps/ShaderStorageBlockFunctionHLSL.o.pp  -fcolor-diagnostics  /var/tmp/portage/www-client/firefox-120.0/work
/firefox-120.0/gfx/angle/checkout/src/compiler/translator/ShaderStorageBlockFunctionHLSL.cpp
27:00.65 In file included from /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/skia/skia/src/core/SkOpts.cpp:46:
27:00.65 /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/skia/skia/src/opts/SkRasterPipeline_opts.h:406:40: error: always_inline function '_mm256_fmadd_ps' requires target feature 'fma', but would be inlined into fu
nction 'mad' that is compiled without support for 'fma'
27:00.65   406 |     SI F   mad(F f, F m, F a) { return _mm256_fmadd_ps(f, m, a); }
27:00.65       |                                        ^
27:00.66 /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/skia/skia/src/opts/SkRasterPipeline_opts.h:424:30: error: always_inline function '_mm256_fnmadd_ps' requires target feature 'fma', but would be inlined into f
unction 'rcp_precise' that is compiled without support for 'fma'
27:00.66   424 |         return _mm256_mul_ps(_mm256_fnmadd_ps(v, e, _mm256_set1_ps(2.0f)), e);
27:00.66       |                              ^
27:00.71 /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/skia/skia/src/opts/SkRasterPipeline_opts.h:1115:12: error: always_inline function '_mm256_cvtph_ps' requires target feature 'f16c', but would be inlined into 
function 'from_half' that is compiled without support for 'f16c'
27:00.71  1115 |     return _mm256_cvtph_ps(h);
27:00.71       |            ^
27:00.71 /var/tmp/portage/www-client/firefox-120.0/work/firefox-120.0/gfx/skia/skia/src/opts/SkRasterPipeline_opts.h:1136:12: error: '__builtin_ia32_vcvtps2ph256' needs target feature f16c
27:00.71  1136 |     return _mm256_cvtps_ph(f, _MM_FROUND_CUR_DIRECTION);
27:00.71       |            ^
27:00.71 /usr/lib/llvm/17/bin/../../../../lib/clang/17/include/f16cintrin.h:139:12: note: expanded from macro '_mm256_cvtps_ph'
27:00.71   139 |  ((__m128i)__builtin_ia32_vcvtps2ph256((__v8sf)(__m256)(a), (imm)))
27:00.72       |            ^
27:00.74 gfx/layers/WebRenderTextureHost.o
Comment 6 Joonas Niilola gentoo-dev 2023-12-01 12:13:38 UTC
To repeat myself: 
it's got something to do with clang, your cpu and skia, and clang/skia enabling some parameters not supported by your CPU. Use specific -march (not native) or compile firefox with gcc (-clang use flag).

Sure VirtualBox can mess it up, I don't know exactly how. But try with GCC (-clang use flag).
Comment 7 Sevilla, Larry 2023-12-04 00:18:15 UTC
(In reply to Joonas Niilola from comment #6)
> To repeat myself: 
> it's got something to do with clang, your cpu and skia, and clang/skia
> enabling some parameters not supported by your CPU. Use specific -march (not
> native) or compile firefox with gcc (-clang use flag).
> 
> Sure VirtualBox can mess it up, I don't know exactly how. But try with GCC
> (-clang use flag).


(Host CPU is i7-9700)

changing /etc/portage/make.conf
COMMON_FLAGS="-O2 -march=skylake -pipe"

problem SOLVED
Comment 8 Sevilla, Larry 2023-12-04 00:19:18 UTC
(In reply to Joonas Niilola from comment #6)
> To repeat myself: 
> it's got something to do with clang, your cpu and skia, and clang/skia
> enabling some parameters not supported by your CPU. Use specific -march (not
> native) or compile firefox with gcc (-clang use flag).
> 
> Sure VirtualBox can mess it up, I don't know exactly how. But try with GCC
> (-clang use flag).

thx...