-
Notifications
You must be signed in to change notification settings - Fork 12k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Clang][AArch64]Fix Name and Mangle name for scalar fp8 (#114983)
The scalar __mfp8 type has the wrong name and mangle name in AArch64SVEACLETypes.def According to the ACLE[1] the name should be __mfp8 This patch fixes this problem by replacing the Name __MFloat8_t by __mfp8 and the Mangle Name __MFloat8_t by u6__mfp8 And we revert the incorrect typedef in NeonEmitter. [1]https://github.com/ARM-software/acle
- Loading branch information
1 parent
fda4a32
commit 91aad9b
Showing
7 changed files
with
70 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,10 @@ | ||
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +neon -target-feature +fp8 \ | ||
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature -fp8 \ | ||
// RUN: -emit-llvm -o - %s -debug-info-kind=limited 2>&1 | FileCheck %s | ||
|
||
// REQUIRES: aarch64-registered-target | ||
|
||
#include<arm_neon.h> | ||
|
||
void test_locals(void) { | ||
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "__MFloat8_t", {{.*}}, baseType: ![[ELTTYU8:[0-9]+]] | ||
// CHECK-DAG: ![[ELTTYU8]] = !DIBasicType(name: "__MFloat8_t", size: 8, encoding: DW_ATE_unsigned_char) | ||
__MFloat8_t mfp8; | ||
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "__mfp8", {{.*}}, baseType: ![[ELTTYU8:[0-9]+]] | ||
// CHECK-DAG: ![[ELTTYU8]] = !DIBasicType(name: "__mfp8", size: 8, encoding: DW_ATE_unsigned_char) | ||
__mfp8 mfp8; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
// RUN: %clang_cc1 -fsyntax-only -verify -triple aarch64-arm-none-eabi -target-feature -fp8 %s | ||
|
||
// REQUIRES: aarch64-registered-target | ||
#include<arm_neon.h> | ||
__mfp8 test_cast_from_float(unsigned in) { | ||
return (__mfp8)in; // expected-error {{used type '__mfp8' (aka '__MFloat8_t') where arithmetic or pointer type is required}} | ||
return (__mfp8)in; // expected-error {{used type '__mfp8' where arithmetic or pointer type is required}} | ||
} | ||
|
||
unsigned test_cast_to_int(__mfp8 in) { | ||
return (unsigned)in; // expected-error {{operand of type '__mfp8' (aka '__MFloat8_t') where arithmetic or pointer type is required}} | ||
return (unsigned)in; // expected-error {{operand of type '__mfp8' where arithmetic or pointer type is required}} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters