[LTP] [PATCH v2 1/2] cve-2015-3290: Disable AVX for x86_64

Siddhesh Poyarekar siddhesh@gotplt.org
Mon Apr 7 12:09:29 CEST 2025


On 2025-04-07 05:18, Petr Vorel wrote:
>>> diff --git a/testcases/cve/Makefile b/testcases/cve/Makefile
>>> index 01b9b9ccb..d545a7f93 100644
>>> --- a/testcases/cve/Makefile
>>> +++ b/testcases/cve/Makefile
>>> @@ -22,6 +22,12 @@ ifneq (,$(filter $(HOST_CPU),x86 x86_64))
>>>    meltdown: CFLAGS += -msse2
>>>    endif
>>> +# The test needs to clobber %rbp, which requires frame pointer omission.  Also
>>> +# for x86_64, disable AVX since that could sometimes require a stack
>>> +# realignment, which gets in the way of frame pointer omission.
>>>    cve-2015-3290:	CFLAGS += -pthread -fomit-frame-pointer
>>> +ifneq (,$(filter $(HOST_CPU),x86_64))
> 
>> If you don't want to add the command line option for 32bit x86 builds, then
>> this condition would be cleaner:
>> ifeq ($(HOST_CPU),x86_64)
> 
> +1. IMHO this works as expected. I suppose Siddhesh got inspiration for filter
> due the above meltdown, where it is needed because it compares 2 archs. But
> I will also appreciate an explicit confirmation.

Oops, yes.  I tested both first just like meltdown and then just removed 
x86.  I'll send a v3 in a moment.

Thanks,
Sid


More information about the ltp mailing list