From patchwork Wed Jul 8 15:51:20 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Schwinge X-Patchwork-Id: 493050 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id A5ED91402B7 for ; Thu, 9 Jul 2015 01:52:59 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=yHjUS9Td; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; q=dns; s=default; b=lk3yLqCmpJwNQ+3w cIzZ0r6MxQEby99jgFLrHCainqLoie/pvf95SsmcjYD5dEwHIgmx44Y082q2/nbR vsMSuQEUEy7LSDAd3hsPZf1q6a0HUDBXZii8zEbZw11m+mLm4HtB+SQsAHtvXMgW h0hbK7UUWRF+fWZEGazEupYRNuU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; s=default; bh=rtUkFe5UC2nA7GLxmlDduM EqIQQ=; b=yHjUS9Td+MZwsMpWre/nf4st8SNtiNlWe0tHCC7p+25J3ts1EVmEHc mUd/PMFnZUmOJKNgpG3ziXSgzdkh6ReXviWspEHt25ArTVCj6MMTlio23wlxPwC0 2AGwT2MxN2yM1e+wZgR4t8AQicujjdQot1ciXgcCSxKdVSLhkObe4= Received: (qmail 107961 invoked by alias); 8 Jul 2015 15:52:52 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 107923 invoked by uid 89); 8 Jul 2015 15:52:48 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 08 Jul 2015 15:52:48 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=SVR-IES-FEM-01.mgc.mentorg.com) by relay1.mentorg.com with esmtp id 1ZCreO-0007lu-9y from Thomas_Schwinge@mentor.com ; Wed, 08 Jul 2015 08:52:44 -0700 Received: from feldtkeller.schwinge.homeip.net (137.202.0.76) by SVR-IES-FEM-01.mgc.mentorg.com (137.202.0.104) with Microsoft SMTP Server id 14.3.224.2; Wed, 8 Jul 2015 16:51:30 +0100 From: Thomas Schwinge To: Ilya Verbin CC: Jakub Jelinek , "" , Kirill Yukhin , "Andrey Turetskiy" Subject: Re: [PATCH 3/4] Add libgomp plugin for Intel MIC In-Reply-To: <52A22903-5BAB-482A-AE3F-18419DBE520D@gmail.com> References: <20141021171323.GA47586@msticlxl57.ims.intel.com> <20141021172413.GD47586@msticlxl57.ims.intel.com> <878uaq68fn.fsf@kepler.schwinge.homeip.net> <52A22903-5BAB-482A-AE3F-18419DBE520D@gmail.com> User-Agent: Notmuch/0.9-101-g81dad07 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-pc-linux-gnu) Date: Wed, 8 Jul 2015 17:51:20 +0200 Message-ID: <87egki641z.fsf@schwinge.name> MIME-Version: 1.0 Hi! On Wed, 8 Jul 2015 18:13:56 +0300, Ilya Verbin wrote: > > > On 8 июля 2015 г., at 17:16, Thomas Schwinge wrote: > > With recent GCC trunk sources, builds of the Intel MIC Offload Plugin > > fail as follows: [...] > > [...] -- OK to commit the following? > Ok to me, thanks. Committed in r225562: commit cacef506e4205bac13a0dd1de238d1a8cc78af28 Author: tschwinge Date: Wed Jul 8 15:47:59 2015 +0000 liboffloadmic plugin: Address -Wnarrowing diagnostics libtool: compile: [...]/build-gcc/./gcc/xg++ [...] -c [...]/source-gcc/liboffloadmic/plugin/libgomp-plugin-intelmic.cpp [...] In file included from [...]/source-gcc/liboffloadmic/plugin/libgomp-plugin-intelmic.cpp:40:0: [...]/install/offload-x86_64-intelmicemul-linux-gnu/lib/gcc/x86_64-intelmicemul-linux-gnu/6.0.0/include/main_target_image.h:8628:1: error: narrowing conversion of '192' from 'int' to 'char' inside { } [-Wnarrowing] }; ^ [...]/install/offload-x86_64-intelmicemul-linux-gnu/lib/gcc/x86_64-intelmicemul-linux-gnu/6.0.0/include/main_target_image.h:8628:1: error: narrowing conversion of '192' from 'int' to 'char' inside { } [-Wnarrowing] [...]/install/offload-x86_64-intelmicemul-linux-gnu/lib/gcc/x86_64-intelmicemul-linux-gnu/6.0.0/include/main_target_image.h:8628:1: error: narrowing conversion of '164' from 'int' to 'char' inside { } [-Wnarrowing] [many more] liboffloadmic/ * plugin/Makefile.am (main_target_image.h): Change type of data member in struct MainTargetImage to uint8_t. * plugin/Makefile.in: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@225562 138bc75d-0d04-0410-961f-82ee72b054a4 --- liboffloadmic/ChangeLog | 6 ++++++ liboffloadmic/plugin/Makefile.am | 2 +- liboffloadmic/plugin/Makefile.in | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) Thanks for the explanation: > The plugin consists of 2 parts: offload_target_main is a target part, which is embedded into the host part (libgomp plugin itself). Target part is linked with liboffloadmic_target.so and host part is linked with liboffloadmic_host.so. Both offload_target_main and liboffloadmic_target.so are compiled by the target compiler during its build. > > As for xxd, I've found its usage in some Makefile inside gcc tree, so I thought it's ok to use it. Grüße, Thomas diff --git liboffloadmic/ChangeLog liboffloadmic/ChangeLog index 01fb9f4..b0f9e90 100644 --- liboffloadmic/ChangeLog +++ liboffloadmic/ChangeLog @@ -1,3 +1,9 @@ +2015-07-08 Thomas Schwinge + + * plugin/Makefile.am (main_target_image.h): Change type of data + member of struct MainTargetImage to uint8_t. + * plugin/Makefile.in: Regenerate. + 2015-05-13 Michael Haubenwallner * Makefile.in: Regenerated with automake-1.11.6. diff --git liboffloadmic/plugin/Makefile.am liboffloadmic/plugin/Makefile.am index a814f0c..19d69ab 100644 --- liboffloadmic/plugin/Makefile.am +++ liboffloadmic/plugin/Makefile.am @@ -69,7 +69,7 @@ main_target_image.h: offload_target_main @echo "struct MainTargetImage {" >> $@ @echo " int64_t size;" >> $@ @echo " char name[sizeof \"offload_target_main\"];" >> $@ - @echo " char data[image_size];" >> $@ + @echo " uint8_t data[image_size];" >> $@ @echo "};" >> $@ @echo "extern \"C\" const MainTargetImage main_target_image = {" >> $@ @echo " image_size, \"offload_target_main\"," >> $@ diff --git liboffloadmic/plugin/Makefile.in liboffloadmic/plugin/Makefile.in index 6f7eec9..19a1a96 100644 --- liboffloadmic/plugin/Makefile.in +++ liboffloadmic/plugin/Makefile.in @@ -715,7 +715,7 @@ main_target_image.h: offload_target_main @echo "struct MainTargetImage {" >> $@ @echo " int64_t size;" >> $@ @echo " char name[sizeof \"offload_target_main\"];" >> $@ - @echo " char data[image_size];" >> $@ + @echo " uint8_t data[image_size];" >> $@ @echo "};" >> $@ @echo "extern \"C\" const MainTargetImage main_target_image = {" >> $@ @echo " image_size, \"offload_target_main\"," >> $@