aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorThomas Schwinge <tschwinge@baylibre.com>2025-03-18 16:18:54 +0100
committerThomas Schwinge <tschwinge@baylibre.com>2025-03-21 15:34:42 +0100
commitf7f6a3dd8251421f873dc99be4acb70ae277d509 (patch)
treeed88ee91fa931b9601a9ad8cb0fb5e02f5421dc5 /gcc
parent6d3a48baac33e9ccd6ea02012078fefd48181af3 (diff)
downloadgcc-f7f6a3dd8251421f873dc99be4acb70ae277d509.zip
gcc-f7f6a3dd8251421f873dc99be4acb70ae277d509.tar.gz
gcc-f7f6a3dd8251421f873dc99be4acb70ae277d509.tar.bz2
Add 'g++.target/nvptx/alias-g++.dg_init_dtor2-2.C'
... next to '-malias' variant: commit a1865fd33897bc6c6e0109df0a12ee73ce386315 "Add 'g++.target/nvptx/alias-g++.dg_init_dtor2-1.C'", to document what we're doing to '-mno-alias'. gcc/testsuite/ * g++.target/nvptx/alias-g++.dg_init_dtor2-2.C: New.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/g++.target/nvptx/alias-g++.dg_init_dtor2-2.C33
1 files changed, 33 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.target/nvptx/alias-g++.dg_init_dtor2-2.C b/gcc/testsuite/g++.target/nvptx/alias-g++.dg_init_dtor2-2.C
new file mode 100644
index 0000000..f00575e
--- /dev/null
+++ b/gcc/testsuite/g++.target/nvptx/alias-g++.dg_init_dtor2-2.C
@@ -0,0 +1,33 @@
+/* Reduced from 'g++.dg/init/dtor2.C'. */
+
+/* { dg-do link } */
+/* { dg-additional-options -mno-alias } */
+/* { dg-additional-options -save-temps } */
+/* Via the magic string "-std=*++" indicate that testing one (the default) C++ standard is sufficient. */
+
+struct B
+{
+ ~B();
+};
+
+B::~B () {
+}
+
+int main()
+{
+ B b;
+ return 0;
+}
+
+/* { dg-final { scan-assembler-times {(?n)^// BEGIN GLOBAL FUNCTION DECL: _ZN1BD2Ev$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^\.visible \.func _ZN1BD2Ev \(\.param\.u64 %in_ar0\);$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^// BEGIN GLOBAL FUNCTION DEF: _ZN1BD2Ev$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^\.visible \.func _ZN1BD2Ev \(\.param\.u64 %in_ar0\)$} 1 } } */
+
+/* { dg-final { scan-assembler-times {(?n)^// BEGIN GLOBAL FUNCTION DECL: _ZN1BD1Ev$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^\.visible \.func _ZN1BD1Ev \(\.param\.u64 %in_ar0\);$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^// BEGIN GLOBAL FUNCTION DEF: _ZN1BD1Ev$} 1 } }
+ { dg-final { scan-assembler-times {(?n)^\.visible \.func _ZN1BD1Ev \(\.param\.u64 %in_ar0\)$} 1 } } */
+
+/* { dg-final { scan-assembler-times {(?n)\tcall _ZN1BD1Ev, \(} 1 } }
+ { dg-final { scan-assembler-times {(?n)\tcall _ZN1BD2Ev, \(} 0 } } */