MaskRay wrote:
The clang/test/Driver codegen tests might have been removed. Note:
clang/test/Driver is to test how clangDriver passes options to cc1, not for
sema/codegen/etc.
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing
@@ -0,0 +1,7 @@
+// RUN: %clang --target=riscv64 -menable-experimental-extensions -c -o
/dev/null %s
yetingk wrote:
Yes. I am sorry that I didn't find out the obvious mistake. I am going to
review my development process.
https://github.com/yetingk edited
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,7 @@
+// RUN: %clang --target=riscv64 -menable-experimental-extensions -c -o
/dev/null %s
+// RUN: ! %clang --target=riscv64 -c -o /dev/null %s 2>&1 | FileCheck
-check-prefixes=CHECK-ERR %s
yetingk wrote:
Thank you. I will fix this if
@@ -0,0 +1,7 @@
+// RUN: %clang --target=riscv64 -menable-experimental-extensions -c -o
/dev/null %s
jrtc27 wrote:
Why are these clang tests? This is entirely testing llvm/ code. Never mind the
weirdness of putting them in Driver/, nor the fact that they’re
@@ -0,0 +1,7 @@
+// RUN: %clang --target=riscv64 -menable-experimental-extensions -c -o
/dev/null %s
+// RUN: ! %clang --target=riscv64 -c -o /dev/null %s 2>&1 | FileCheck
-check-prefixes=CHECK-ERR %s
jrtc27 wrote:
Use not rather than !
yetingk wrote:
@pogo59 Thank you for the advise. I will update the test cases.
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yetingk wrote:
@zmodem very thank you for the help.
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
pogo59 wrote:
Driver tests are supposed to verify Driver behavior. That is, use `-###` and
make sure the correct option is being passed down to the compiler. They should
not be compiling anything.
https://github.com/llvm/llvm-project/pull/89727
___
zmodem wrote:
6217abc should fix the test failures.
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
dyung wrote:
@yetingk, the two tests you added are failing on a couple of build bots:
- https://lab.llvm.org/buildbot/#/builders/164/builds/51995
- https://lab.llvm.org/buildbot/#/builders/258/builds/17867
- https://lab.llvm.org/buildbot/#/builders/91/builds/25943
-
https://github.com/yetingk closed
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yetingk wrote:
@topperc Sorry, there was a quick fix after the approve.
`getTargetFeatureForExtension` could approve the extension with version. It may
be better to allow them, but I am not sure the error message could be enough
readable if we use wrong version number and is the format of
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/6] [RISCV] Teach .option arch to support experimental
extensions.
https://github.com/topperc approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -51,7 +51,6 @@ STATISTIC(RISCVNumInstrsCompressed,
static cl::opt AddBuildAttributes("riscv-add-build-attributes",
cl::init(false));
-
yetingk wrote:
Done.
https://github.com/llvm/llvm-project/pull/89727
@@ -2824,8 +2826,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string Feature =
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/5] [RISCV] Teach .option arch to support experimental
extensions.
@@ -51,7 +51,6 @@ STATISTIC(RISCVNumInstrsCompressed,
static cl::opt AddBuildAttributes("riscv-add-build-attributes",
cl::init(false));
-
topperc wrote:
Unrelated change?
@@ -2824,8 +2826,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string Feature =
@@ -169,6 +169,9 @@ void riscv::getRISCVTargetFeatures(const Driver , const
llvm::Triple ,
Features.push_back("-relax");
}
+ if (!Args.hasArg(options::OPT_menable_experimental_extensions))
+Features.push_back("+no-experimental-ext");
yetingk
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/4] [RISCV] Teach .option arch to support experimental
extensions.
https://github.com/topperc edited
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -169,6 +169,9 @@ void riscv::getRISCVTargetFeatures(const Driver , const
llvm::Triple ,
Features.push_back("-relax");
}
+ if (!Args.hasArg(options::OPT_menable_experimental_extensions))
+Features.push_back("+no-experimental-ext");
topperc
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/4] [RISCV] Teach .option arch to support experimental
extensions.
yetingk wrote:
I fix the issue by using feature to control the permission of experimental
extension.
> Does this disable use of experimental extensions for a `.option arch` in an
> inline assembly block without -menable-experimental-extensions.
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/4] [RISCV] Teach .option arch to support experimental
extensions.
yetingk wrote:
> Does this disable use of experimental extensions for a `.option arch` in an
> inline assembly block without -menable-experimental-extensions.
No. my patch could not block the case. I will try to think this problem after
my sleep.
topperc wrote:
Does this disable use of experimental extensions for a `.option arch` in an
inline assembly block?
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -2824,8 +2827,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string & =
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/3] [RISCV] Teach .option arch to support experimental
extensions.
@@ -2824,8 +2827,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string & =
https://github.com/yetingk edited
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/yetingk edited
https://github.com/llvm/llvm-project/pull/89727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2824,8 +2827,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string & =
@@ -51,6 +51,9 @@ STATISTIC(RISCVNumInstrsCompressed,
static cl::opt AddBuildAttributes("riscv-add-build-attributes",
cl::init(false));
+static cl::opt
+DisableExperimentalExtension("riscv-disable-experimental-ext",
@@ -2824,8 +2827,12 @@ bool RISCVAsmParser::parseDirectiveOption() {
break;
}
- auto Ext = llvm::lower_bound(RISCVFeatureKV, Arch);
- if (Ext == std::end(RISCVFeatureKV) || StringRef(Ext->Key) != Arch ||
+ std::string & =
@@ -51,6 +51,9 @@ STATISTIC(RISCVNumInstrsCompressed,
static cl::opt AddBuildAttributes("riscv-add-build-attributes",
cl::init(false));
+static cl::opt
+DisableExperimentalExtension("riscv-disable-experimental-ext",
https://github.com/yetingk updated
https://github.com/llvm/llvm-project/pull/89727
>From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001
From: Yeting Kuo
Date: Tue, 23 Apr 2024 02:16:04 -0700
Subject: [PATCH 1/2] [RISCV] Teach .option arch to support experimental
extensions.
39 matches
Mail list logo