diff mbox series

[1/5] include/exec/memop.h: Add MO_TESB

Message ID 20231023153029.269211-3-c@jia.je (mailing list archive)
State New, archived
Headers show
Series Add LoongArch v1.1 instructions | expand

Commit Message

Jiajie Chen Oct. 23, 2023, 3:29 p.m. UTC
Signed-off-by: Jiajie Chen <c@jia.je>
---
 include/exec/memop.h | 1 +
 1 file changed, 1 insertion(+)

Comments

David Hildenbrand Oct. 23, 2023, 3:49 p.m. UTC | #1
Why?

On 23.10.23 17:29, Jiajie Chen wrote:
> Signed-off-by: Jiajie Chen <c@jia.je>
> ---
>   include/exec/memop.h | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/include/exec/memop.h b/include/exec/memop.h
> index a86dc6743a..834327c62d 100644
> --- a/include/exec/memop.h
> +++ b/include/exec/memop.h
> @@ -140,6 +140,7 @@ typedef enum MemOp {
>       MO_TEUL  = MO_TE | MO_UL,
>       MO_TEUQ  = MO_TE | MO_UQ,
>       MO_TEUO  = MO_TE | MO_UO,
> +    MO_TESB  = MO_TE | MO_SB,
>       MO_TESW  = MO_TE | MO_SW,
>       MO_TESL  = MO_TE | MO_SL,
>       MO_TESQ  = MO_TE | MO_SQ,



I recall that the reason for not having this is that the target 
endianess doesn't matter for single bytes.
Jiajie Chen Oct. 23, 2023, 3:52 p.m. UTC | #2
On 2023/10/23 23:49, David Hildenbrand wrote:
>
> Why?
>
> On 23.10.23 17:29, Jiajie Chen wrote:
>> Signed-off-by: Jiajie Chen <c@jia.je>
>> ---
>>   include/exec/memop.h | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/include/exec/memop.h b/include/exec/memop.h
>> index a86dc6743a..834327c62d 100644
>> --- a/include/exec/memop.h
>> +++ b/include/exec/memop.h
>> @@ -140,6 +140,7 @@ typedef enum MemOp {
>>       MO_TEUL  = MO_TE | MO_UL,
>>       MO_TEUQ  = MO_TE | MO_UQ,
>>       MO_TEUO  = MO_TE | MO_UO,
>> +    MO_TESB  = MO_TE | MO_SB,
>>       MO_TESW  = MO_TE | MO_SW,
>>       MO_TESL  = MO_TE | MO_SL,
>>       MO_TESQ  = MO_TE | MO_SQ,
>
>
>
> I recall that the reason for not having this is that the target 
> endianess doesn't matter for single bytes.

Thanks, you are right, I was copying some code using MO_TESW only to 
find that MO_TESB is missing... I should simply use MO_SB then.
diff mbox series

Patch

diff --git a/include/exec/memop.h b/include/exec/memop.h
index a86dc6743a..834327c62d 100644
--- a/include/exec/memop.h
+++ b/include/exec/memop.h
@@ -140,6 +140,7 @@  typedef enum MemOp {
     MO_TEUL  = MO_TE | MO_UL,
     MO_TEUQ  = MO_TE | MO_UQ,
     MO_TEUO  = MO_TE | MO_UO,
+    MO_TESB  = MO_TE | MO_SB,
     MO_TESW  = MO_TE | MO_SW,
     MO_TESL  = MO_TE | MO_SL,
     MO_TESQ  = MO_TE | MO_SQ,