public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r12-6544] Host and offload targets have no common meaning of address spaces
@ 2022-01-13 10:17 Thomas Schwinge
0 siblings, 0 replies; only message in thread
From: Thomas Schwinge @ 2022-01-13 10:17 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:9fcc3a1dd2372deea8856c55d25337b06e201203
commit r12-6544-g9fcc3a1dd2372deea8856c55d25337b06e201203
Author: Thomas Schwinge <thomas@codesourcery.com>
Date: Tue Aug 24 11:14:10 2021 +0200
Host and offload targets have no common meaning of address spaces
gcc/
* tree-streamer-out.c (pack_ts_base_value_fields): Don't pack
'TYPE_ADDR_SPACE' for offloading.
* tree-streamer-in.c (unpack_ts_base_value_fields): Don't unpack
'TYPE_ADDR_SPACE' for offloading.
libgomp/
* testsuite/libgomp.c/address-space-1.c: Remove 'dg-xfail-run-if'
for 'offload_device_intel_mic'.
Diff:
---
gcc/tree-streamer-in.c | 2 ++
gcc/tree-streamer-out.c | 7 ++++++-
libgomp/testsuite/libgomp.c/address-space-1.c | 4 ----
3 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/gcc/tree-streamer-in.c b/gcc/tree-streamer-in.c
index adaf624bda7..0d5108e36a0 100644
--- a/gcc/tree-streamer-in.c
+++ b/gcc/tree-streamer-in.c
@@ -146,7 +146,9 @@ unpack_ts_base_value_fields (struct bitpack_d *bp, tree expr)
TYPE_REVERSE_STORAGE_ORDER (expr) = (unsigned) bp_unpack_value (bp, 1);
else
TYPE_SATURATING (expr) = (unsigned) bp_unpack_value (bp, 1);
+#ifndef ACCEL_COMPILER
TYPE_ADDR_SPACE (expr) = (unsigned) bp_unpack_value (bp, 8);
+#endif
}
else if (TREE_CODE (expr) == BIT_FIELD_REF || TREE_CODE (expr) == MEM_REF)
{
diff --git a/gcc/tree-streamer-out.c b/gcc/tree-streamer-out.c
index 8742bf09c6a..23d15a50670 100644
--- a/gcc/tree-streamer-out.c
+++ b/gcc/tree-streamer-out.c
@@ -119,7 +119,12 @@ pack_ts_base_value_fields (struct bitpack_d *bp, tree expr)
bp_pack_value (bp, TYPE_REVERSE_STORAGE_ORDER (expr), 1);
else
bp_pack_value (bp, TYPE_SATURATING (expr), 1);
- bp_pack_value (bp, TYPE_ADDR_SPACE (expr), 8);
+ if (lto_stream_offload_p)
+ /* Host and offload targets have no common meaning of address
+ spaces. */
+ ;
+ else
+ bp_pack_value (bp, TYPE_ADDR_SPACE (expr), 8);
}
else if (TREE_CODE (expr) == BIT_FIELD_REF || TREE_CODE (expr) == MEM_REF)
{
diff --git a/libgomp/testsuite/libgomp.c/address-space-1.c b/libgomp/testsuite/libgomp.c/address-space-1.c
index 6ad57deec42..39ff82c1429 100644
--- a/libgomp/testsuite/libgomp.c/address-space-1.c
+++ b/libgomp/testsuite/libgomp.c/address-space-1.c
@@ -3,10 +3,6 @@
/* { dg-do run { target i?86-*-* x86_64-*-* } } */
/* { dg-require-effective-target offload_device_nonshared_as } */
-/* With Intel MIC (emulated) offloading:
- offload error: process on the device 0 unexpectedly exited with code 0
- { dg-xfail-run-if TODO { offload_device_intel_mic } } */
-
#include <assert.h>
int __seg_fs a;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-01-13 10:17 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-13 10:17 [gcc r12-6544] Host and offload targets have no common meaning of address spaces Thomas Schwinge
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).