#include "llvm/TargetParser/RISCVISAInfo.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/Testing/Support/Error.h"
#include "gtest/gtest.h"
ElementsAre;
usingnamespacellvm;
bool operator==(const RISCVISAUtils::ExtensionVersion &A,
const RISCVISAUtils::ExtensionVersion &B) { … }
TEST(ParseNormalizedArchString, RejectsInvalidChars) { … }
TEST(ParseNormalizedArchString, RejectsInvalidBaseISA) { … }
TEST(ParseNormalizedArchString, RejectsMalformedInputs) { … }
TEST(ParseNormalizedArchString, RejectsOnlyVersion) { … }
TEST(ParseNormalizedArchString, RejectsBadZ) { … }
TEST(ParseNormalizedArchString, RejectsBadS) { … }
TEST(ParseNormalizedArchString, RejectsBadX) { … }
TEST(ParseNormalizedArchString, DuplicateExtension) { … }
TEST(ParseNormalizedArchString, AcceptsValidBaseISAsAndSetsXLen) { … }
TEST(ParseNormalizedArchString, AcceptsArbitraryExtensionsAndVersions) { … }
TEST(ParseNormalizedArchString, UpdatesFLenMinVLenMaxELen) { … }
TEST(ParseNormalizedArchString, AcceptsUnknownMultiletter) { … }
TEST(ParseArchString, RejectsInvalidChars) { … }
TEST(ParseArchString, RejectsInvalidBaseISA) { … }
TEST(ParseArchString, RejectsUnsupportedBaseISA) { … }
TEST(ParseArchString, AcceptsSupportedBaseISAsAndSetsXLenAndFLen) { … }
TEST(ParseArchString, RejectsUnrecognizedExtensionNamesByDefault) { … }
TEST(ParseArchString, AcceptsVersionInLongOrShortForm) { … }
TEST(ParseArchString, RejectsUnrecognizedExtensionVersionsByDefault) { … }
TEST(ParseArchString, AcceptsUnderscoreSplittingExtensions) { … }
TEST(ParseArchString, AcceptsRelaxSingleLetterExtensions) { … }
TEST(ParseArchString, AcceptsRelaxMixedLetterExtensions) { … }
TEST(ParseArchString, AcceptsAmbiguousFromRelaxExtensions) { … }
TEST(ParseArchString, RejectsRelaxExtensionsNotStartWithEorIorG) { … }
TEST(ParseArchString,
RejectsMultiLetterExtensionFollowBySingleLetterExtensions) { … }
TEST(ParseArchString, RejectsDoubleOrTrailingUnderscore) { … }
TEST(ParseArchString, RejectsDuplicateExtensionNames) { … }
TEST(ParseArchString,
RejectsExperimentalExtensionsIfNotEnableExperimentalExtension) { … }
TEST(ParseArchString,
AcceptsExperimentalExtensionsIfEnableExperimentalExtension) { … }
TEST(ParseArchString,
RequiresExplicitVersionNumberForExperimentalExtensionByDefault) { … }
TEST(ParseArchString,
AcceptsUnrecognizedVersionIfNotExperimentalExtensionVersionCheck) { … }
TEST(ParseArchString, RejectsUnrecognizedVersionForExperimentalExtension) { … }
TEST(ParseArchString, RejectsExtensionVersionForG) { … }
TEST(ParseArchString, AddsImpliedExtensions) { … }
TEST(ParseArchString, RejectsConflictingExtensions) { … }
TEST(ParseArchString, MissingDepency) { … }
TEST(ParseArchString, RejectsUnrecognizedProfileNames) { … }
TEST(ParseArchString, RejectsProfilesWithUnseparatedExtraExtensions) { … }
TEST(ParseArchString, AcceptsBareProfileNames) { … }
TEST(ParseArchSTring, AcceptsProfileNamesWithSeparatedAdditionalExtensions) { … }
TEST(ParseArchString,
RejectsProfilesWithAdditionalExtensionsGivenAlreadyInProfile) { … }
TEST(ParseArchString,
RejectsExperimentalProfilesIfEnableExperimentalExtensionsNotSet) { … }
TEST(ToFeatures, IIsDroppedAndExperimentalExtensionsArePrefixed) { … }
TEST(ToFeatures, UnsupportedExtensionsAreDropped) { … }
TEST(ToFeatures, UnsupportedExtensionsAreKeptIfIgnoreUnknownIsFalse) { … }
TEST(ToFeatures, AddAllExtensionsAddsNegativeExtensions) { … }
TEST(OrderedExtensionMap, ExtensionsAreCorrectlyOrdered) { … }
TEST(ParseArchString, ZceImplication) { … }
TEST(isSupportedExtensionWithVersion, AcceptsSingleExtensionWithVersion) { … }
TEST(getTargetFeatureForExtension, RetrieveTargetFeatureFromOneExt) { … }
TEST(RiscvExtensionsHelp, CheckExtensions) { … }
TEST(TargetParserTest, RISCVPrintEnabledExtensions) { … }