Skip to content

Commit

Permalink
Add hints to vld/vldx for loading fp vectors, see #7
Browse files Browse the repository at this point in the history
  • Loading branch information
jiegec committed Jan 3, 2024
1 parent ac73636 commit 71a3dcc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1636,15 +1636,15 @@ def vld():
return instruction(
intrinsic=f"__m128i __lsx_vld (void * addr, imm_n2048_2047 offset)",
instr=f"vld vr, r, imm",
desc=f"Read whole vector from memory address `addr + offset`, save the data into `dst`.",
desc=f"Read whole vector from memory address `addr + offset`, save the data into `dst`. Note that you can use this intrinsic to load floating point vectors, even though the return type represents integer vectors.",
)

@my_macro(env)
def vldx():
return instruction(
intrinsic=f"__m128i __lsx_vldx (void * addr, long int offset)",
instr=f"vldx vr, r, r",
desc=f"Read whole vector from memory address `addr + offset`, save the data into `dst`.",
desc=f"Read whole vector from memory address `addr + offset`, save the data into `dst`. Note that you can use this intrinsic to load floating point vectors, even though the return type represents integer vectors.",
)

@my_macro(env)
Expand Down

0 comments on commit 71a3dcc

Please sign in to comment.