On 04.04.2024 18:17, Oleksii wrote:
> On Thu, 2024-04-04 at 17:43 +0200, Jan Beulich wrote:
>> On 04.04.2024 17:18, Oleksii wrote:
>>> On Thu, 2024-04-04 at 12:07 +0200, Jan Beulich wrote:
>>>> On 03.04.2024 12:19, Oleksii Kurochko wrote:
>>>>> --- a/xen/arch/riscv/arch.mk
>>>>> +++ b/xen/arch/riscv/arch.mk
>>>>> @@ -3,16 +3,27 @@
>>>>>  
>>>>>  $(call cc-options-add,CFLAGS,CC,$(EMBEDDED_EXTRA_CFLAGS))
>>>>>  
>>>>> -CFLAGS-$(CONFIG_RISCV_64) += -mabi=lp64
>>>>> +riscv-abi-$(CONFIG_RISCV_32) := -mabi=ilp32
>>>>> +riscv-abi-$(CONFIG_RISCV_64) := -mabi=lp64
>>>>>  
>>>>>  riscv-march-$(CONFIG_RISCV_ISA_RV64G) := rv64g
>>>>>  riscv-march-$(CONFIG_RISCV_ISA_C)       := $(riscv-march-y)c
>>>>>  
>>>>> +riscv-generic-flags := $(riscv-abi-y) -march=$(riscv-march-y)
>>>>> +
>>>>> +zbb := $(call as-insn,$(CC) $(riscv-generic-
>>>>> flags)_zbb,"",_zbb)
>>>>
>>>> While committing another question popped up: Why "" (i.e. no
>>>> insn)
>>>> here, ...
>>>>
>>>>> +zihintpause := $(call as-insn,\
>>>>> +               $(CC) $(riscv-generic-
>>>>> flags)_zihintpause,"pause",_zihintpause)
>>>>
>>>> ... but "pause" here?
>>>
>>> In the case of the Zbb extension, we don't check for a specific
>>> instruction, but with the Zihintpause, the idea was to verify if
>>> the
>>> pause instruction is supported or not.
>>
>> And why's this verification relevant here, but not for Zbb?
> It is not relevant and can be dropped.

Is it really not? Aren't you checking two things for Zihintpause (compiler
and assembler support), while checking only one (compiler) for Zbb?

Jan

Reply via email to