https://github.com/FreddyLeaf closed
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
FreddyLeaf wrote:
Thank you both for all of the review!
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/KanRobert approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
FreddyLeaf wrote:
ping
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -265,6 +265,7 @@ X86_MICROARCH_LEVEL(X86_64_BASELINE,"x86-64",
95)
X86_MICROARCH_LEVEL(X86_64_V2, "x86-64-v2",96)
X86_MICROARCH_LEVEL(X86_64_V3, "x86-64-v3",97)
X86_MICROARCH_LEVEL(X86_64_V4, "x86-64-v4",98)
https://github.com/FreddyLeaf edited
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/FreddyLeaf updated
https://github.com/llvm/llvm-project/pull/80636
>From b131b0971d5c38a29c954b37c0da8fb3177e5c92 Mon Sep 17 00:00:00 2001
From: Freddy Ye
Date: Mon, 5 Feb 2024 14:07:29 +0800
Subject: [PATCH 1/6] [X86] Support APXF to enable __builtin_cpu_supports.
---
@@ -265,6 +265,7 @@ X86_MICROARCH_LEVEL(X86_64_BASELINE,"x86-64",
95)
X86_MICROARCH_LEVEL(X86_64_V2, "x86-64-v2",96)
X86_MICROARCH_LEVEL(X86_64_V3, "x86-64-v3",97)
X86_MICROARCH_LEVEL(X86_64_V4, "x86-64-v4",98)
@@ -983,6 +983,8 @@ static void getAvailableFeatures(unsigned ECX, unsigned
EDX, unsigned MaxLeaf,
setFeature(FEATURE_USERMSR);
if (HasLeaf7Subleaf1 && ((EDX >> 19) & 1))
setFeature(FEATURE_AVX10_1_256);
+ if (HasLeaf7Subleaf1 && ((EDX >> 21) & 1))
@@ -219,6 +219,7 @@
#define bit_PREFETCHI 0x4000
#define bit_USERMSR 0x8000
#define bit_AVX10 0x0008
+#define bit_APXF 0x0020
FreddyLeaf wrote:
Done.
https://github.com/llvm/llvm-project/pull/80636
https://github.com/FreddyLeaf edited
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/FreddyLeaf edited
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -265,6 +265,7 @@ X86_MICROARCH_LEVEL(X86_64_BASELINE,"x86-64",
95)
X86_MICROARCH_LEVEL(X86_64_V2, "x86-64-v2",96)
X86_MICROARCH_LEVEL(X86_64_V3, "x86-64-v3",97)
X86_MICROARCH_LEVEL(X86_64_V4, "x86-64-v4",98)
@@ -219,6 +219,7 @@
#define bit_PREFETCHI 0x4000
#define bit_USERMSR 0x8000
#define bit_AVX10 0x0008
+#define bit_APXF 0x0020
KanRobert wrote:
Where is the number from? Add the link in your description of the PR.
@@ -265,6 +265,7 @@ X86_MICROARCH_LEVEL(X86_64_BASELINE,"x86-64",
95)
X86_MICROARCH_LEVEL(X86_64_V2, "x86-64-v2",96)
X86_MICROARCH_LEVEL(X86_64_V3, "x86-64-v3",97)
X86_MICROARCH_LEVEL(X86_64_V4, "x86-64-v4",98)
@@ -983,6 +983,8 @@ static void getAvailableFeatures(unsigned ECX, unsigned
EDX, unsigned MaxLeaf,
setFeature(FEATURE_USERMSR);
if (HasLeaf7Subleaf1 && ((EDX >> 19) & 1))
setFeature(FEATURE_AVX10_1_256);
+ if (HasLeaf7Subleaf1 && ((EDX >> 21) & 1))
@@ -1845,6 +1845,12 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
https://github.com/FreddyLeaf updated
https://github.com/llvm/llvm-project/pull/80636
>From b131b0971d5c38a29c954b37c0da8fb3177e5c92 Mon Sep 17 00:00:00 2001
From: Freddy Ye
Date: Mon, 5 Feb 2024 14:07:29 +0800
Subject: [PATCH 1/5] [X86] Support APXF to enable __builtin_cpu_supports.
---
FreddyLeaf wrote:
> You may also need to transfer "apxf" feature into subfeatures here
> https://github.com/llvm/llvm-project/blob/main/clang/lib/Basic/Targets/X86.cpp#L106
Thanks for pointing out! This looks like the change required by supporting
attribute((target("apxf"))). While that
phoebewang wrote:
You may also need to transfer "apxf" feature into subfeatures here
https://github.com/llvm/llvm-project/blob/main/clang/lib/Basic/Targets/X86.cpp#L106
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
@@ -1845,6 +1845,12 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
FreddyLeaf wrote:
After
[fa42b33](https://github.com/llvm/llvm-project/pull/80636/commits/fa42b33d62227bd88cc5d63431244d0caac1e286)
1. An error will be thrown out if compiling `__builtin_cpu_supports("egpr")`
2. __attribute__((__target__("apxf"))) is not supported in this patch, no
matter
https://github.com/FreddyLeaf updated
https://github.com/llvm/llvm-project/pull/80636
>From b131b0971d5c38a29c954b37c0da8fb3177e5c92 Mon Sep 17 00:00:00 2001
From: Freddy Ye
Date: Mon, 5 Feb 2024 14:07:29 +0800
Subject: [PATCH 1/4] [X86] Support APXF to enable __builtin_cpu_supports.
---
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
https://github.com/FreddyLeaf updated
https://github.com/llvm/llvm-project/pull/80636
>From b131b0971d5c38a29c954b37c0da8fb3177e5c92 Mon Sep 17 00:00:00 2001
From: Freddy Ye
Date: Mon, 5 Feb 2024 14:07:29 +0800
Subject: [PATCH 1/3] [X86] Support APXF to enable __builtin_cpu_supports.
---
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
@@ -1845,6 +1845,7 @@ bool sys::getHostCPUFeatures(StringMap ) {
Features["prefetchi"] = HasLeaf7Subleaf1 && ((EDX >> 14) & 1);
Features["usermsr"] = HasLeaf7Subleaf1 && ((EDX >> 15) & 1);
Features["avx10.1-256"] = HasLeaf7Subleaf1 && ((EDX >> 19) & 1);
+
FreddyLeaf wrote:
ping for review
https://github.com/llvm/llvm-project/pull/80636
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
33 matches
Mail list logo