[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 03/32] s390x/tcg: Utilities for vector instru
From: |
David Hildenbrand |
Subject: |
Re: [Qemu-devel] [PATCH v2 03/32] s390x/tcg: Utilities for vector instruction helpers |
Date: |
Fri, 1 Mar 2019 17:13:05 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 |
On 01.03.19 17:09, Richard Henderson wrote:
> On 3/1/19 3:53 AM, David Hildenbrand wrote:
>> +#ifndef S390X_VEC_H
>> +#define S390X_VEC_H
>> +
>> +typedef union S390Vector {
>> + uint64_t doubleword[2];
>> + uint32_t word[4];
>> + uint16_t halfword[8];
>> + uint8_t byte[16];
>> +} S390Vector;
>> +
>> +uint8_t s390_vec_read_element8(const S390Vector *v, uint8_t enr);
>> +uint16_t s390_vec_read_element16(const S390Vector *v, uint8_t enr);
>> +uint32_t s390_vec_read_element32(const S390Vector *v, uint8_t enr);
>> +uint64_t s390_vec_read_element64(const S390Vector *v, uint8_t enr);
>> +void s390_vec_write_element8(S390Vector *v, uint8_t enr, uint8_t data);
>> +void s390_vec_write_element16(S390Vector *v, uint8_t enr, uint16_t data);
>> +void s390_vec_write_element32(S390Vector *v, uint8_t enr, uint32_t data);
>> +void s390_vec_write_element64(S390Vector *v, uint8_t enr, uint64_t data);
>> +
>
> These, I think, should be static inline. Certainly I think they're too small
> to warrant a real call across modules, as you appear to be preparing for...
I'm wondering, won't link-time optimization properly handle this? (so
far the theory I know of)
But I can move these completely into the head.
>
> I'm not sure why else they're being declared outside vec_helper.c?
>
We'll have vec_int_helper.c, vec_fpu_helper.c vec_string_helper.c ....
Thanks!
--
Thanks,
David / dhildenb
[Qemu-devel] [PATCH v2 05/32] s390x/tcg: Implement VECTOR GENERATE BYTE MASK, David Hildenbrand, 2019/03/01
[Qemu-devel] [PATCH v2 04/32] s390x/tcg: Implement VECTOR GATHER ELEMENT, David Hildenbrand, 2019/03/01
[Qemu-devel] [PATCH v2 07/32] s390x/tcg: Implement VECTOR LOAD, David Hildenbrand, 2019/03/01
[Qemu-devel] [PATCH v2 06/32] s390x/tcg: Implement VECTOR GENERATE MASK, David Hildenbrand, 2019/03/01
[Qemu-devel] [PATCH v2 08/32] s390x/tcg: Implement VECTOR LOAD AND REPLICATE, David Hildenbrand, 2019/03/01