History log of /llvm-project/llvm/unittests/TargetParser/RISCVISAInfoTest.cpp (Results 51 – 67 of 67)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-18.1.6
# 891d6871 15-May-2024 Alex Bradbury <asb@igalia.com>

[RISCV] Gate unratified profiles behind -menable-experimental-extensions (#92167)

As discussed in the last sync-up call, because these profiles are not
yet finalised they shouldn't be exposed to us

[RISCV] Gate unratified profiles behind -menable-experimental-extensions (#92167)

As discussed in the last sync-up call, because these profiles are not
yet finalised they shouldn't be exposed to users unless they opt-in to
them (much like experimental extensions). We may later want to add a
more specific flag, but reusing `-menable-experimental-extensions`
solves the immediate problem.

This is implemented using the new support for marking profiles s
experimental added in #91993 to move the unratified profiles to
RISCVExperimentalProfile and making the necessary changes to logic in
RISCVISAInfo to handle this.

show more ...


# 24c39261 15-May-2024 Alex Bradbury <asb@igalia.com>

[RISCV][test] Add tests for parsing profiles using RISCVISAInfo::parseArchString


# d8f8ac8f 10-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Don't pre-split before the loop in parseNormalizedArchString. (#91684)

We can extract each extension as we process them without much
complexity.

I changed the error message for cases whe

[RISCV] Don't pre-split before the loop in parseNormalizedArchString. (#91684)

We can extract each extension as we process them without much
complexity.

I changed the error message for cases where there are double underscores
or a trailing underscore. I think this is an improvement over the
previous error.

show more ...


# 0d93b01c 08-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Don't crash if parseNormalizedArchString encounters a multi-letter extension with an unknown prefix. (#91398)

The sorting code previously asserted if a prefix was multiple letters,
but didn

[RISCV] Don't crash if parseNormalizedArchString encounters a multi-letter extension with an unknown prefix. (#91398)

The sorting code previously asserted if a prefix was multiple letters,
but didn't start with s, x, or z.

Replace the assert with an explicit check and sort the multi-letter
extension after the known multi-letter prefixes.

show more ...


# 2c209957 08-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Detect duplicate extensions in parseNormalizedArchString. (#91416)

This detects the same extension name being added twice. Mostly I'm
worried about the case that the same string appears wit

[RISCV] Detect duplicate extensions in parseNormalizedArchString. (#91416)

This detects the same extension name being added twice. Mostly I'm
worried about the case that the same string appears with two different
versions. We will only preserve one of the versions.

We could allow the same version to be repeated, but that doesn't seem
useful at the moment.

I've updated addExtension to use map::emplace instead of
map::operator[]. This means we only keep the first version if there are
duplicates. Previously we kept the last version, but that shouldn't matter
now that we don't allow duplicates. parseArchString already doesn't allow
duplicates.

show more ...


# 117bda52 07-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Add unittests for MinVLen/MaxELen/MaxElenFp for ParseArchString. NFC

We had tests for ParseNormalizedArchString, but not ParseArchString.
The ParseNormalizedArchString test was not checking

[RISCV] Add unittests for MinVLen/MaxELen/MaxElenFp for ParseArchString. NFC

We had tests for ParseNormalizedArchString, but not ParseArchString.
The ParseNormalizedArchString test was not checking MaxElenFp.

show more ...


# 6cba93f2 07-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Add partial validation of S and X extension names to RISCVISAInfo::parseNormalizedArchString.

Extensions starting with 's' or 'x' should always be followed by an
alphabetical character. I d

[RISCV] Add partial validation of S and X extension names to RISCVISAInfo::parseNormalizedArchString.

Extensions starting with 's' or 'x' should always be followed by an
alphabetical character. I don't know of any crashes from this currently,
but it seemed better to be defensive.

show more ...


# 0faf4942 03-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Make parseArchString only accept [a-z0-9_]. (#90879)

Similar change was recently made to parseNormalizedArchString.


# 7a6847e0 03-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Add partial validation of Z extension name to RISCVISAInfo::parseNormalizedArchString (#90895)

If 'z' is given as the complete extension name or with a digit after it,
it will crash in the

[RISCV] Add partial validation of Z extension name to RISCVISAInfo::parseNormalizedArchString (#90895)

If 'z' is given as the complete extension name or with a digit after it,
it will crash in the extension map compare function. Check for these
cases and give an error.

show more ...


# 5445a35d 02-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Detect empty extension name after parsing MajorVersion in parseNormalizedArchString. (#90790)

If the string is just a version, we will end up adding an empty string
as an extension which cr

[RISCV] Detect empty extension name after parsing MajorVersion in parseNormalizedArchString. (#90790)

If the string is just a version, we will end up adding an empty string
as an extension which crashes in the compare function for the std::map.

show more ...


# 941eab10 02-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Make parseNormalizedArchString only accept [a-z0-9_]. (#90815)

Previously we only rejected upper case characters. We should instead
reject anything except lower case, numbers, and underscor

[RISCV] Make parseNormalizedArchString only accept [a-z0-9_]. (#90815)

Previously we only rejected upper case characters. We should instead
reject anything except lower case, numbers, and underscore. Other
characters will likely confuse the extension sorting.

show more ...


# 44645996 02-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Add smstateen extension (#90818)


# ab8ac36f 02-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Add list of supported profiles to -print-supported-extensions (#90757)

I tried also printing the -march they correspond to, but it seemed
overly verbose and caused line wraps. It might be b

[RISCV] Add list of supported profiles to -print-supported-extensions (#90757)

I tried also printing the -march they correspond to, but it seemed
overly verbose and caused line wraps. It might be better if we remove
the versions numbers from the string or did a more intelligent line
wrap.

show more ...


Revision tags: llvmorg-18.1.5
# 09f4b06d 01-May-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Refactor profile selection in RISCVISAInfo::parseArchString. (#90700)

Instead of hardcoding the 4 current profile prefixes, treat profile
selection as a fallback if we don't find "rv32" or

[RISCV] Refactor profile selection in RISCVISAInfo::parseArchString. (#90700)

Instead of hardcoding the 4 current profile prefixes, treat profile
selection as a fallback if we don't find "rv32" or "rv64".

Update the error message accordingly.

show more ...


# 6f02120a 29-Apr-2024 David Spickett <david.spickett@linaro.org>

[llvm][RISCV] Improve error message for invalid extension letters (#90468)

Previously you got:
clang: error: invalid arch name 'rv64v', first letter should be 'e', 'i'
or 'g'

Which to me, unfam

[llvm][RISCV] Improve error message for invalid extension letters (#90468)

Previously you got:
clang: error: invalid arch name 'rv64v', first letter should be 'e', 'i'
or 'g'

Which to me, unfamiliar with riscv, reads as if I should have used
"[eig]rv64v". Which is not what clang means.

Include the first bit in the error message to make this clearer:
clang: error: invalid arch name 'rv64v', first letter after 'rv64'
should be 'e', 'i' or 'g'

show more ...


# de375fbc 27-Apr-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Move OrderedExtensionMap typedef to RISCVISAUtils.h. NFC


# 733a8778 23-Apr-2024 Craig Topper <craig.topper@sifive.com>

[RISCV] Split code that tablegen needs out of RISCVISAInfo. (#89684)

This introduces a new file, RISCVISAUtils.cpp and moves the rest of
RISCVISAInfo to the TargetParser library.

This will allow

[RISCV] Split code that tablegen needs out of RISCVISAInfo. (#89684)

This introduces a new file, RISCVISAUtils.cpp and moves the rest of
RISCVISAInfo to the TargetParser library.

This will allow us to generate part of RISCVISAInfo.cpp using tablegen.

show more ...


123