This is an archive of the discontinued LLVM Phabricator instance.

[Clang][RISCV] Change TARGET_BUILTIN to require zve32x for vector instruction
ClosedPublic

Authored by eopXD on Oct 27 2021, 4:47 AM.

Details

Summary

According to v-spec v1.0, zve-32x is the new minimum extension to include
to have vector instructions.

Diff Detail

Event Timeline

eopXD created this revision.Oct 27 2021, 4:47 AM
eopXD requested review of this revision.Oct 27 2021, 4:47 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptOct 27 2021, 4:47 AM
eopXD retitled this revision from [RISCV][RVV] Change TARGET_BUILTIN require to zve32x to [WIP][RISCV] Change TARGET_BUILTIN require to zve32x for vector instruction.
eopXD edited the summary of this revision. (Show Details)Oct 27 2021, 4:55 AM
eopXD updated this revision to Diff 382615.Oct 27 2021, 5:06 AM

Update code.

eopXD updated this revision to Diff 383977.Nov 1 2021, 11:07 PM

Rebase.

eopXD updated this revision to Diff 383983.Nov 1 2021, 11:52 PM

Follow clang-format.

eopXD retitled this revision from [WIP][RISCV] Change TARGET_BUILTIN require to zve32x for vector instruction to [RISCV] Change TARGET_BUILTIN require to zve32x for vector instruction.Nov 2 2021, 12:09 AM
eopXD edited the summary of this revision. (Show Details)

The title of this patch isn't descriptive of the changes in this patch. Based on the title I would only expect changes to RISCVEmitter.cpp. Can you clarify the title?

craig.topper added inline comments.Nov 5 2021, 1:17 PM
clang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vaadd.c
3

Why do we need to add zve32x and zve64x to the command line? Doesn't zve64x imply zve32x?

eopXD added inline comments.Nov 6 2021, 2:14 AM
clang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vaadd.c
3

Just added D113336 to resolve this. I will rebase this patch and change test cases.

eopXD updated this revision to Diff 385276.Nov 6 2021, 7:47 AM

Rebase.

eopXD updated this revision to Diff 385278.Nov 6 2021, 7:55 AM

Update code.

eopXD marked an inline comment as done.Nov 6 2021, 7:56 AM
eopXD added inline comments.
clang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vaadd.c
3

Rebased.

eopXD edited the summary of this revision. (Show Details)Jan 20 2022, 1:36 AM
eopXD updated this revision to Diff 401549.Jan 20 2022, 1:37 AM

Rebase.

eopXD updated this revision to Diff 401554.Jan 20 2022, 1:56 AM

Rebase.

LGTM but I don't have full scope on the builtins side of things. I'd also add a missing word to the title: "Change TARGET_BUILTIN to require ..."

eopXD retitled this revision from [RISCV] Change TARGET_BUILTIN require to zve32x for vector instruction to [RISCV] Change TARGET_BUILTIN to require zve32x for vector instruction.Jan 20 2022, 4:04 AM

Apply @frasercrmck 's suggested title, thanks!

eopXD retitled this revision from [RISCV] Change TARGET_BUILTIN to require zve32x for vector instruction to [Clang][RISCV] Change TARGET_BUILTIN to require zve32x for vector instruction.Jan 20 2022, 4:09 AM
This revision is now accepted and ready to land.Jan 20 2022, 6:35 AM